-
Notifications
You must be signed in to change notification settings - Fork 435
Support RequestAwareGRpcMetricsTagsContributor on Multiary Calls #245
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
Conversation
/** | ||
* Prefer overriding {@link #getTags(Object, MethodDescriptor, Attributes, Tags)}. | ||
*/ | ||
@Deprecated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The idea behind marking this @Deprecated
is that it’s easier if clients all use the same method. This method could then be removed in the next major release.
On the other hand, it’s also not much effort to keep supporting this method, so we can also remove @Deprecated
.
beb19b9
to
4729c30
Compare
4729c30
to
3963d9f
Compare
...main/java/org/lognet/springboot/grpc/autoconfigure/metrics/GRpcMetricsAutoConfiguration.java
Show resolved
Hide resolved
...main/java/org/lognet/springboot/grpc/autoconfigure/metrics/GRpcMetricsAutoConfiguration.java
Show resolved
Hide resolved
private final Collection<GRpcMetricsTagsContributor> tagsContributors; | ||
@Getter | ||
private Tags additionalTags = Tags.empty(); | ||
private volatile boolean closed = false; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
volatile
is sufficient here, since there will be no parallel access.
...main/java/org/lognet/springboot/grpc/autoconfigure/metrics/GRpcMetricsAutoConfiguration.java
Show resolved
Hide resolved
Codecov Report
@@ Coverage Diff @@
## master #245 +/- ##
============================================
- Coverage 90.64% 90.49% -0.16%
- Complexity 214 219 +5
============================================
Files 38 38
Lines 930 957 +27
Branches 40 44 +4
============================================
+ Hits 843 866 +23
- Misses 68 69 +1
- Partials 19 22 +3
Continue to review full report at Codecov.
|
closes #244
… and also refactor the metric code a bit.