geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gianny.dam...@optusnet.com.au
Subject Re: WADI Session invalidate causes an error
Date Tue, 09 Sep 2008 22:48:33 GMT
Hi Adam,

This is the correct way to invalidate a session. You have just found an integration problem
with Tomcat which was not tested by the session invalidation unit test.

I have improved the unit test and updated the relevant class, namely ClusteredManager (will
commit when I get better connectivity).

You will need to upgrade the geronimo-tomcat6-clustering-wadi-2.1.2.jar artifact in order
to use the updated class. I attached a new jar  geronimo-tomcat6-clustering-wadi-2.1.2.1.jar
packaging the new ClusteredManager (this is not a released jar and I made up the version number).
Put it in your repository, folder:
repository/org/apache/geronimo/modules/geronimo-tomcat6-clustering-wadi/2.1.2.1/

Add the following artifact alias to var/config/artifact_aliases.properties so that 2.1.2.1
is used instead of 2.1.2:
org.apache.geronimo.modules/geronimo-tomcat6-clustering-wadi/2.1.2/jar=org.apache.geronimo.modules/geronimo-tomcat6-clustering-wadi/2.1.2.1/jar

Sessions are now successfully invalidated.

I will work on the proper release of new geronimo-tomcat6-clustering-wadi artifact and ping
you as soon as it is released.

Thanks,
Gianny

> Adam Ruggles <a.ruggles@gmail.com> wrote:
> 
> 
> I'm using a WADI Clustering with Geronimo 2.1.2/tomcat.
> 
> After I call Session.invalidate(); when a user logs out I receive the
> following exception:
> 
> java.lang.IllegalStateException: Cannot release session
> org.codehaus.wadi.core.session.AtomicallyReplicableSession@c6e143
>      at
> org.apache.geronimo.clustering.wadi.WADISessionAdaptor.release(WADISessio
> nAdaptor.java:42)
>      at
> org.apache.geronimo.tomcat.cluster.ClusteredManager$ClusteredSession.inva
> lidate(ClusteredManager.java:118)
>      at
> org.apache.catalina.session.StandardSessionFacade.invalidate(StandardSess
> ionFacade.java:150)
>      at
> com.pearson.powerschool.am.authentication.action.SSOLogoutAction.execute(
> SSOLogoutAction.java:74)
>      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>      at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java
> :39)
>      at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorI
> mpl.java:25)
>      at java.lang.reflect.Method.invoke(Method.java:585)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActio
> nInvocation.java:404)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultA
> ctionInvocation.java:267)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:229)
>      at
> com.pearson.powerschool.am.persistence.interceptor.LoggingInterceptor.int
> ercept(LoggingInterceptor.java:76)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercep
> t(DefaultWorkflowInterceptor.java:221)
>      at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Met
> hodFilterInterceptor.java:86)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(Valid
> ationInterceptor.java:150)
>      at
> org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor
> .doIntercept(AnnotationValidationInterceptor.java:48)
>      at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Met
> hodFilterInterceptor.java:86)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(
> ConversionErrorInterceptor.java:123)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.ParametersInterceptor.doIntercept(Par
> ametersInterceptor.java:167)
>      at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Met
> hodFilterInterceptor.java:86)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept
> (StaticParametersInterceptor.java:105)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInte
> rceptor.java:83)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUpload
> Interceptor.java:207)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(Chainin
> gInterceptor.java:115)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterce
> ptor.java:143)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.PrepareInterceptor.doIntercept(Prepar
> eInterceptor.java:121)
>      at
> com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(Met
> hodFilterInterceptor.java:86)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(Servlet
> ConfigInterceptor.java:170)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.AliasInterceptor.intercept(AliasInter
> ceptor.java:123)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> com.opensymphony.xwork2.interceptor.ExceptionMappingInterceptor.intercept
> (ExceptionMappingInterceptor.java:176)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:224)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation$2.doProfiling(DefaultActi
> onInvocation.java:223)
>      at
> com.opensymphony.xwork2.util.profiling.UtilTimerStack.profile(UtilTimerSt
> ack.java:455)
>      at
> com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvoc
> ation.java:221)
>      at
> org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:
> 50)
>      at
> org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:50
> 4)
>      at
> org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.
> java:419)
>      at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applicat
> ionFilterChain.java:235)
>      at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilte
> rChain.java:206)
>      at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve
> .java:233)
>      at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve
> .java:175)
>      at
> org.apache.geronimo.tomcat.valve.DefaultSubjectValve.invoke(DefaultSubjec
> tValve.java:56)
>      at
> org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invo
> ke(GeronimoStandardContext.java:406)
>      at
> org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(Geronimo
> BeforeAfterValve.java:47)
>      at
> org.apache.geronimo.tomcat.cluster.AbstractClusteredValve$WebClusteredInv
> ocation.invokeLocally(AbstractClusteredValve.java:68)
>      at
> org.apache.geronimo.tomcat.cluster.wadi.WADIClusteredValve$WADIWebCluster
> edInvocation.access$000(WADIClusteredValve.java:65)
>      at
> org.apache.geronimo.tomcat.cluster.wadi.WADIClusteredValve$WADIWebCluster
> edInvocation$1.doFilter(WADIClusteredValve.java:76)
>      at
> org.codehaus.wadi.web.impl.WebInvocation.invoke(WebInvocation.java:115)
>      at
> org.codehaus.wadi.core.contextualiser.MemoryContextualiser.handleLocally(
> MemoryContextualiser.java:67)
>      at
> org.codehaus.wadi.core.contextualiser.AbstractExclusiveContextualiser.han
> dle(AbstractExclusiveContextualiser.java:108)
>      at
> org.codehaus.wadi.core.contextualiser.AbstractMotingContextualiser.contex
> tualise(AbstractMotingContextualiser.java:37)
>      at
> org.codehaus.wadi.core.manager.StandardManager.processStateful(StandardMa
> nager.java:150)
>      at
> org.codehaus.wadi.core.manager.StandardManager.contextualise(StandardMana
> ger.java:142)
>      at
> org.codehaus.wadi.core.manager.ClusteredManager.contextualise(ClusteredMa
> nager.java:81)
>      at
> org.apache.geronimo.tomcat.cluster.wadi.WADIClusteredValve$WADIWebCluster
> edInvocation.invoke(WADIClusteredValve.java:84)
>      at
> org.apache.geronimo.tomcat.cluster.AbstractClusteredValve.invoke(Abstract
> ClusteredValve.java:42)
>      at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:
> 128)
>      at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:
> 102)
>      at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.j
> ava:109)
>      at
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
> 
>      at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:28
> 6)
>      at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844
> )
>      at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(H
> ttp11Protocol.java:583)
>      at
> org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
>      at java.lang.Thread.run(Thread.java:613)
>     Caused by: java.lang.NullPointerException
>      at 
> org.apache.catalina.session.ManagerBase.remove(ManagerBase.java:885)
>      at
> org.apache.geronimo.tomcat.cluster.ClusteredManager$MigrationListener.not
> ifySessionDestruction(ClusteredManager.java:77)
>      at
> org.apache.geronimo.clustering.wadi.BasicWADISessionManager.notifySession
> Destruction(BasicWADISessionManager.java:183)
>      at
> org.apache.geronimo.clustering.wadi.BasicWADISessionManager.access$100(Ba
> sicWADISessionManager.java:51)
>      at
> org.apache.geronimo.clustering.wadi.BasicWADISessionManager$SessionListen
> erAdapter.onSessionDestruction(BasicWADISessionManager.java:193)
>      at
> org.codehaus.wadi.core.manager.BasicSessionMonitor.notifySessionDestructi
> on(BasicSessionMonitor.java:67)
>      at
> org.codehaus.wadi.core.manager.StandardManager.destroy(StandardManager.ja
> va:116)
>      at
> org.codehaus.wadi.core.session.StandardSession.destroy(StandardSession.ja
> va:66)
>      at
> org.codehaus.wadi.core.session.AbstractReplicableSession.destroy(Abstract
> ReplicableSession.java:55)
>      at
> org.apache.geronimo.clustering.wadi.WADISessionAdaptor.release(WADISessio
> nAdaptor.java:40)
>      ... 116 more 
> 
> 
> Is that an invalid call for a WADI session?  If so what would be the
> recommended method for ending a session?
> -- 
> View this message in context: 
> http://www.nabble.com/WADI-Session-invalidate-causes-an-error-tp19384273s
> 134p19384273.html
> Sent from the Apache Geronimo - Users mailing list archive at 
> Nabble.com.


Mime
View raw message