|
[enhydra] Servlet container and session IDs: msg#00007java.enhydra.general
Hi all, I'm trying to setup two Enhydra (6.4-1) servers with an Apache (2.0.54) / mod_jk (1.2.14) server load-balancing traffic. I've had problems getting this to work because the webapp I was interested in serving was configured to use 'com.lutris.appserver.server.sessionEnhydra.StandardSessionManager'. The problem is that this session manager ignores the jvmRoute attribute of the Engine element (in server.xml). So mod_jk didn't have a chance to keep session affinity when performing the load-balancing. As suggested by Slobodan, I changed the web.xml for the webapp so that 'com.lutris.appserver.server.sessionContainerAdapter.JmxContainerAdapterSessionManager' would be used instead of 'com.lutris.appserver.server.sessionEnhydra.StandardSessionManager'. After this change the session IDs were generated by the servlet container, so they had the jvmRoute appended to them, which allowed mod_jk to do its work. However, I found out that 'com.lutris.appserver.server.sessionContainerAdapter.JmxContainerAdapterSessionManager' will not use custom SessionHome's. i.e., the following entries don't have any effect: <env-entry> <env-entry-name>SessionManager/SessionHome/Mode</env-entry-name> <env-entry-value>CUSTOM</env-entry-value> <env-entry-type>java.lang.String</env-entry-type> </env-entry> <env-entry> <env-entry-name>SessionManager/SessionHome/Class</env-entry-name> <env-entry-value>com.whatever.CustomSessionHome</env-entry-value> <env-entry-type>java.lang.String</env-entry-type> </env-entry> After looking through the documentation I've noticed 'com.lutris.appserver.server.sessionEnhydra.SimpleServletSessionManager'. I've changed the configuration to use this class as session manager and everything seems to be running smoothly (our custom SessionHome is being used and the session IDs used are the ones generated by the servlet container). Does 'com.lutris.appserver.server.sessionEnhydra.SimpleServletSessionManager' behave like 'com.lutris.appserver.server.sessionEnhydra.StandardSessionManager' except in session ID handling? I'm guessing that that's the only difference between the two: the former uses the session ID generated by the servlet container (thus having the jvmRoute info that mod_jk needs), the latter generates the sessions IDs itself (and is oblivious to the jvmRoute attribute). Am I right? Regarding EAF 6.5-1: will 'com.lutris.appserver.server.sessionContainerAdapter.TomcatContainerAdapterSessionManager' behave like 'com.lutris.appserver.server.sessionContainerAdapter.JmxContainerAdapterSessionManager'? I.e., will it ignore the SessionHome settings that 'SimpleServletSessionManager' and 'StandardSessionManager' use? If so, then 'SimpleServletSessionManager' will still (in Enhydra 6.5) be the session manager to use if I want the features of Enhydra 'StandardSessionManager' using session IDs generated by the servlet container, right? Best regards, -- Edgar Alves -- You receive this message as a subscriber of the enhydra@xxxxxxxxxxxxx mailing list. To unsubscribe: mailto:enhydra-unsubscribe@xxxxxxxxxxxxx For general help: mailto:sympa@xxxxxxxxxxxxx?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: [enhydra] Re: jvmRoute effect on JSESSIONID, Edgar Alves |
|---|---|
| Next by Date: | Re: [enhydra] Servlet container and session IDs, Slobodan Vujasinovic |
| Previous by Thread: | [enhydra] Bug in QueryBuilder. addUpdateColumn(RDBColumn column, Object value) or may be not, João Paulo Ribeiro |
| Next by Thread: | Re: [enhydra] Servlet container and session IDs, Slobodan Vujasinovic |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |