WSO2(AS v5.3.0)Http会话复​​制不起作用

时间:2016-05-23 09:22:33

标签: wso2 tomcat7 wso2as

我尝试基于WSO2 AS集群(v5.3.0)设置Http会话复​​制。 但它不起作用。 (指南:https://docs.wso2.com/display/AS520/Clustering+and+Http+Session+Replication

任何人都可以提供帮助吗?

以下是错误的堆栈跟踪:

ERROR {org.wso2.carbon.tomcat.ext.valves.CompositeValve} -  Could not handle request: /ServletSessionURLRewriting/LoginSuccess.jsp
java.lang.ClassCastException: org.wso2.carbon.webapp.mgt.session.CarbonTomcatClusterableSessionManager cannot be cast to org.wso2.carbon.core.session.CarbonTomcatClusterableSessionManager
        at org.wso2.carbon.tomcat.ext.valves.CarbonTomcatSessionReplicationValve.sendSessionReplicationMessage(CarbonTomcatSessionReplicationValve.java:59)
        at org.wso2.carbon.tomcat.ext.valves.CarbonTomcatSessionReplicationValve.invoke(CarbonTomcatSessionReplicationValve.java:49)
        at org.wso2.carbon.statistics.webapp.RequestIntercepterValve.invoke(RequestIntercepterValve.java:47)
        at org.wso2.carbon.bam.webapp.stat.publisher.WebAppStatisticPublisherValve.invoke(WebAppStatisticPublisherValve.java:104)
        at org.wso2.carbon.tomcat.ext.valves.CompositeValve.continueInvocation(CompositeValve.java:99)
        at org.wso2.carbon.tomcat.ext.valves.CarbonTomcatValve$1.invoke(CarbonTomcatValve.java:47)
        at org.wso2.carbon.webapp.mgt.TenantLazyLoaderValve.invoke(TenantLazyLoaderValve.java:57)
        at org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer.invokeValves(TomcatValveContainer.java:47)
        at org.wso2.carbon.tomcat.ext.valves.CompositeValve.invoke(CompositeValve.java:62)
        at org.wso2.carbon.tomcat.ext.valves.CarbonStuckThreadDetectionValve.invoke(CarbonStuckThreadDetectionValve.java:159)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
        at org.wso2.carbon.tomcat.ext.valves.CarbonContextCreatorValve.invoke(CarbonContextCreatorValve.java:57)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
        at org.apache.catalina.ha.tcp.ReplicationValve.invoke(ReplicationValve.java:333)
        at org.apache.catalina.ha.session.JvmRouteBinderValve.invoke(JvmRouteBinderValve.java:218)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1739)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1698)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:745)

这是catalina-server.xml配置

<Cluster className="org.wso2.carbon.core.session.CarbonTomcatSimpleTcpCluster"/>
<Valve className="org.wso2.carbon.tomcat.ext.valves.CarbonTomcatSessionReplicationValve"/>

并在我的web.xml文件中添加了<distributable/>

1 个答案:

答案 0 :(得分:1)

您必须使用以下阀门

perl

而不是

<Valve className="org.wso2.carbon.webapp.mgt.session.CarbonTomcatSessionReplicationValve"/>

记录在案Enabling HTTP Session Replication