Uploaded image for project: 'Weld'
  1. Weld
  2. WELD-1178

ConversationAwareViewHandler throws ContextNotActiveException

XMLWordPrintable

    • Hide

      Do whatever possible to trigger the exception before rendreResponse phase.

      Show
      Do whatever possible to trigger the exception before rendreResponse phase.

      If exception is thrown during render response (JSF app) then ExceptionHandler (seam3) is notified after conversation context has been deactivated. If such exception handler wants to redirect to error page using following code:

      NavigationHandler navHandler = context.getApplication().getNavigationHandler();
      navHandler.handleNavigation(context, "", viewId+"?faces-redirect=true");

      then ConversationAwareViewHandler will get called on getActionURL(FacesContext facesContext, String viewId)
      which doesn't check if conversation context is active and calls conversation.isTransient, which in turn throws exception (context inactive).

      I'd say there should be no call to conversation if context is inactive.

            marko.luksa@gmail.com Marko Luksa (Inactive)
            blabno Bernard Labno (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: