Closed meiao closed 4 months ago
Attention: Patch coverage is 4.34783%
with 22 lines
in your changes missing coverage. Please review.
Project coverage is 70.58%. Comparing base (
be49741
) to head (e3e5d1b
).
Files | Patch % | Lines |
---|---|---|
...elic/agent/service/analytics/SpanEventFactory.java | 4.34% | 20 Missing and 2 partials :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Overview
Adds the following attributes to SQS external spans so they can be linked to the respective SQS entity.
messaging.system
cloud.region
cloud.account.id
messaging.destination.name
Related Github Issue
1835
Testing
Testing for this feature is a hampered due to a dependency. When that dependency is updated, then the tests in the SQS instrumentation modules can be run.
API changes
There are a few changes to the external API. New attributes and methods were added to
MessageProduceParameters
andMessageConsumeParameters
and their respective builders.For the parameters the added methods are getters.
For the builders, new methods were added to the Build interface and all return a Build, so they can be concatenated. The new methods being on the Build interface, essentially make them optional (which they are), thus this addition will not break existing use of the API.
Another method that was added was an overload of the existing
MessageConsumeParameters#library
andMessageProduceParameters#library
methods. This new method receives 2 Strings, the first one is the library name used by the agent, this matches the parameter for the existing method. A second String was added to record the name of the library used by OTEL, which in many cases is slightly different from the agent's. Since this is the first method called in the builder process, this also won't break existing use of the API.Checks