-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mike,

On 4/28/12 10:52 AM, Mike Wilson wrote:
> uriworkermap.properties /*       = serverA /path2/* = serverB 
> /path3/* = serverB /path3/xyz/* = serverA

Like André, I'm curious about this, too. I would have expected some of
these things to interfere with each other. Are you just using
shorthand when you say /path2/* or is that similar to your real JkMount?

> But how do I best solve the issue with each server setting its own
> JSESSIONID?

The first thing to determine is if you actually have a problem: Tomcat
can tolerate having multiple JSESSIONID cookies coming-in from a
request. It will try the JSESSIONID cookies sequentially until it
finds a valid one. So, there's no reason two webapps cannot share the
same URL space (though you're in for some surprises, occasionally).

> The browser client will see one site with one domain and one
> JSESSIONID cookie, so this will cause interference between the two
> servers when switching between pages.

Remember that a cookie also has a "path" associated with it. What are
the webapp context paths for your various webapps? If they are both
"/" (i.e. the ROOT webapp) then you are kind of screwed: the webapps
will fight each other for the JSESSIONID cookie and your client will
probably always send the wrong cookie. :(

If you have disjoint paths (/foo versus /bar) then everything will be
fine. If you have nested paths (/ versus /foo -- which is looks like
you probably do), then things will *mostly* work, except when they
don't. I had the experience of using nested paths in the past and
things became very confused under certain circumstances.

(IIRC, we were also using proxied-JSESSIONIDs through the nested URL
space to communicate back to the top-level URL space so we couldn't
have Tomcat tell us if a session id was valid or not... we had to
blindly choose one of the JSESSIONID cookies and send *that* to the
Tomcat back-end. I can see that this isn't making any sense and it was
kind of a cluster#$@*%& so forget it.)

> Does mod_jk offer any feature to solve this, or is my best bet to
> change the name of the JSESSIONID cookie on one of the servers?

I would go back to my first question: is there actually a problem? Or,
are you simply forecasting one?

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk+eqS8ACgkQ9CaO5/Lv0PCYpwCeI+BSXcLhZj11prRQdRSODzMB
XDMAniFPBmAnx13PMzzoomaQfcighWmW
=wX91
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to