"Unregisters" the current span stack from this thread, removes span-related info from the logging MDC, and returns the span stack that was unregistered so it
can be stored and re-registered later (if desired). This is used in asynchronous projects/frameworks where multiple in-progress requests might be handled by the same thread
before any of the requests can finish (e.g. Netty, where the worker I/O threads might process a portion of request A, flip over to request B to do some work, then go back
to request A, etc). This method lets you unregister the tracing info from the current thread when it is about to switch to processing a different request so the tracing
info can be stored in some kind of request context state that follows the request, and won't pollute the thread's span stack and MDC info when the new request starts being
When processing switches back to the original request, you can call
#registerWithThread(java.util.Deque) to set the thread's span stack and MDC info back to the
way it was when you first called this unregister method for the original request.
WARNING: This method should NOT be called if you're in an environment where a single thread is guaranteed to process a request from start to finish without jumping
to a different request in the middle. In that case just use the normal start and complete span methods and ignore this method.