class SecHubServerMDCAsyncHandlerInterceptor extends HandlerInterceptorAdapter {

    @Override
    public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception {
        LOG.trace("Initial clearing MDC for asynchronous request");
        // we clear MDC for every call
        MDC.clear();
        try {
            handleRoutingInformation(request);
        } catch (Exception e) {
            LOG.error("Handle routing information failed - so continue without new MDC settings", e);
        }
        return super.preHandle(request, response, handler);
    }

}