public static void endRequest() { log.debug("After request, destroying contexts"); try { Contexts.flushAndDestroyContexts(); } finally { clearThreadlocals(); log.debug( "<<< End web request" ); } }
public static void endRequest(HttpServletRequest request) { log.debug("After request, destroying contexts"); try { Session session = Session.getInstance(); boolean sessionInvalid = session!=null && session.isInvalid(); Contexts.flushAndDestroyContexts(); if (sessionInvalid) { Lifecycle.clearThreadlocals(); request.getSession().invalidate(); //actual session context will be destroyed from the listener } } finally { Lifecycle.clearThreadlocals(); log.debug( "<<< End web request" ); } } @Deprecated
public static void endCall() { try { Contexts.destroy( Contexts.getSessionContext() ); Contexts.flushAndDestroyContexts(); if ( Manager.instance().isLongRunningConversation() ) { throw new IllegalStateException("Do not start long-running conversations in direct calls to EJBs"); } } finally { clearThreadlocals(); log.debug( "<<< End call" ); } }
public static void endRequest(ExternalContext externalContext) { log.debug("After render response, destroying contexts"); try { Session session = Session.getInstance(); boolean sessionInvalid = session!=null && session.isInvalid(); Contexts.flushAndDestroyContexts(); if (sessionInvalid) { Lifecycle.clearThreadlocals(); clearPhaseId(); invalidateSession(externalContext); //actual session context will be destroyed from the listener } } finally { Lifecycle.clearThreadlocals(); log.debug( "<<< End JSF request for " + getRequestPath(externalContext) ); } }