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

Refactor query generation logic into its own crate #85

Open
emschwartz opened this issue May 8, 2023 · 2 comments
Open

Refactor query generation logic into its own crate #85

emschwartz opened this issue May 8, 2023 · 2 comments
Labels
good first issue Good for newcomers

Comments

@emschwartz
Copy link
Contributor

@hatchan suggested refactoring out the logic for building the Prometheus queries into a separate crate so it can potentially be used outside of the macro.

Maybe we call it something like autometrics-query or autometrics-queries?

@emschwartz emschwartz added the good first issue Good for newcomers label May 8, 2023
@flenter
Copy link
Member

flenter commented May 8, 2023

Could the library use templates that are perhaps stored in the autometrics-shared repo? That way many more libraries can re-use the logic

@emschwartz
Copy link
Contributor Author

Good idea @flenter!

I think the best way to do this would be to write the queries as mustache templates and then use something like git subtree to include them in the other repos where we need them.

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

No branches or pull requests

2 participants