I am developing an application in Vertx. I am attaching uniqueRequestId to each request and adds it to the requestContext
object, so that while printing any logs I will associate uniqueRequestId to each log message and I will be able to better trace the request logs.
Now the one approach to this is, I can pass requestContext
object to each function.
So my question is that, Is there any way to access requestContext
object without passing it to each and every function?