Skip to content

Provide invocation arguments for RepositoryMethodInvocation #2677

Open
@roookeee

Description

@roookeee

RepositoryTagsProvider of spring-boot-actuator is based on RepositoryMethodInvocation which is defined here.
We would like to tag our repository metrics based on the passed arguments to provide more granular metrics. For example: We have a query that takes a List<String> and we want to track metrics for each size of the given parameter, as the query has / may have difference performance characteristics when being passed 1 vs. 100 ids. This would skew the gathered metrics and overall make the metrics unusable as they can't be interpreted correctly (1 size calls skews min, 100 skews max, average is a hot mess).

From reading the code RepositoryMethodInvocation could be passed the arguments of the actual invocation which would then be available to the RepositoryTagsProvider. Is there any downside to this? Are the arguments only the repository method call arguments or are there some framework related arguments present?

Thank you for your time. I would be willing to do a PR for this if you agree that this should be done.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions