@AroundInvoke public Object intercept(InvocationContext ctx) throws Exception { try { return ctx.proceed(); } catch (Exception e) { // now log context informations TraceeContextLogger.createDefault().logJsonWithPrefixedMessage("TRACEE EJB INTERCEPTOR CONTEXT LOGGING LISTENER : ", ImplicitContext.COMMON, ImplicitContext.TRACEE, ctx, e); throw e; } }
private void handleHttpServletRequest( HttpServletRequest servletRequest, HttpServletResponse servletResponse, Exception e) { TraceeContextLogger.createDefault().logJsonWithPrefixedMessage("TRACEE SERVLET ERROR CONTEXT LOGGING LISTENER : ", ImplicitContext.COMMON, ImplicitContext.TRACEE, servletRequest, servletResponse, e); }