-
Make sure you have the brave tracing dependency configured, e.g. via Spring Sleuth. See their documentation on how to do this.
-
Add the brave-extension-spring-boot module
<dependency> <groupId>com.jashmore</groupId> <artifactId>brave-extension-spring-boot</artifactId> <version>${library.version}</version> </dependency>
-
Now any processing message should have tracing information
See the spring-sleuth-example for a Spring application that has this setup.
If you want to include the Trace information into your SQS message so that the message listener continues the trace, you can use the sqs-brave-tracing utility module to add the tracing information to the SQS Message Attributes.
An example of this being done is in the spring-sleuth-example.