Dashboard > WebWork > ... > Interceptors > Token Session Interceptor
  WebWork Log In View a printable version of the current page.  
  Token Session Interceptor
Added by Onyeje Bose, last edited by Onyeje Bose on Oct 18, 2005  (view change)
Labels: 
(None)

This interceptor builds off of the TokenInterceptor, providing advanced logic for handling invalid tokens. Unlike the normal token interceptor, this interceptor will attempt to provide intelligent fail-over in the event of multiple requests using the same session. That is, it will block subsequent requests until the first request is complete, and then instead of returning the invalid.token code, it will attempt to display the same response that the original, valid action invocation would have displayed if no multiple requests were submitted in the first place.

NOTE: As this method extends off MethodFilterInterceptor, it is capable of deciding if it is applicable only to selective methods in the action class. See MethodFilterInterceptor for more info.

Parameters

  • None

Extending the Interceptor

There are no known extension points for this interceptor.

Examples

<action name="someAction" class="com.examples.SomeAction">
    <interceptor-ref name="token-session/>
    <interceptor-ref name="basicStack"/>
    <result name="success">good_result.ftl</result>
</action>

<-- In this case, myMethod of the action class will not 
       get checked for invalidity of token -->
<action name="someAction" class="com.examples.SomeAction">
    <interceptor-ref name="token-session>
        <param name="excludeMethods">myMethod</param>
    </interceptor-ref name="token-session>
    <interceptor-ref name="basicStack"/>
    <result name="success">good_result.ftl</result>
</action>

Site powered by a free Open Source Project / Non-profit License (more) of Confluence - the Enterprise wiki.
Learn more or evaluate Confluence for your organisation.
Powered by Atlassian Confluence, the Enterprise Wiki. (Version: 2.2.9 Build:#527 Sep 07, 2006) - Bug/feature request - Contact Administrators