Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert to using external middleware reporter package #288

Merged
merged 1 commit into from
Aug 9, 2021

Conversation

scalvert
Copy link
Contributor

@scalvert scalvert commented Aug 6, 2021

The middleware reporter functionality contained in this repository had the potential for broader usage than in this repository. Being able to gather data as the result of tests runs and generically store that data can be used for

  • ember-cli-deprecation-workflow: where we gather all deprecations and write them to a file. This file can then be consumed by external systems to track deprecations.
  • validation utilities, where the validations are performed at runtime, during tests, and the results of those validations are needing to be published to metrics systems

In order to support the above use cases, I've extracted this functionality out into a new package: ember-setup-middleware-reporter. This package contains a collection of utilities that make adding server middleware easier.

This PR updates the custom implementation with the new one from that package.

⚠️ Note: systems that rely on the file name pattern defined here should update any dependent logic to support the new format here.

Depends on #289.

@drewlee
Copy link
Contributor

drewlee commented Aug 6, 2021

⚠️ Note: systems that rely on the file name pattern defined here should update any dependent logic to support the new format here.

@scalvert would this constitute a breaking change in terms of publishing a new release version?

@scalvert
Copy link
Contributor Author

scalvert commented Aug 6, 2021

⚠️ Note: systems that rely on the file name pattern defined here should update any dependent logic to support the new format here.

@scalvert would this constitute a breaking change in terms of publishing a new release version?

@rwjblue and I discussed this, and felt that it's not. You should likely be reading the contents of the specified report directory rather than relying on specific file names.

@scalvert scalvert merged commit 107ace2 into master Aug 9, 2021
@rwjblue rwjblue deleted the use-middleware-utils branch August 9, 2021 16:16
@rwjblue
Copy link
Member

rwjblue commented Aug 9, 2021

You should likely be reading the contents of the specified report directory rather than relying on specific file names.

Ya, just to add a bit more color: due to the way we write the files, you can't really know ahead of time the precise file name anyways (ember-exam splits, somewhat randomized times from when the file is written, etc). I think in practice, no consumers of these files will have to do updates (because they already had to effectively list the directory and process each file already).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants