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

Feature Request: Micrometer Metrics for templates #294

Open
checketts opened this issue May 12, 2022 · 1 comment
Open

Feature Request: Micrometer Metrics for templates #294

checketts opened this issue May 12, 2022 · 1 comment

Comments

@checketts
Copy link

checketts commented May 12, 2022

I would like to investigate adding some metrics to Thymeleaf. The Spring library already uses Micrometer so this won't introduce a new dependency.

I'm primarily interested in recording which templates are being used. Would a PR for that be welcome? Another metric would be to record when there are template errors.

Proposed metric names would be:

Counter: thymeleaf.template.used (tags: templateName), I'm hoping to record usage via views, fragments, and layout, perhaps include that as a tag.
Counter: thymeleaf.template.errors (tags: templateName, is possible)

@checketts
Copy link
Author

Any concerns around this idea? Perhaps I should just do a spike in my own codebase to see how I might do it without requiring a Thymeleaf change... (Though I would be happy to contribute the idea upstream)

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

No branches or pull requests

1 participant