-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Konstantin,
On 12/10/12 3:37 PM, Konstantin Kolinko wrote: > 2012/12/10 Christopher Schultz <ch...@christopherschultz.net>: >> >> If the Valve is configured at the Engine or Host level, will the >> call to getSession know what webapp's session should be fetched? >> Obviously, Tomcat figures this out eventually, but I was >> wondering if that resolution has been done before the host- or >> engine-level valves are invoked. > > The Context to which the request maps to is known from requestURI > + mapper. (Regardless of where the valve is configured). Great, thanks. >>> See also org.apache.catalina.ha.session.JvmRouteBinderValve, >>> http://tomcat.apache.org/tomcat-7.0-doc/config/cluster-valve.html >> >> >>> I think that may be the right place for this to ultimately live, but >> developing separately probably makes sense for now. >> > > I do not think such feature belongs to Tomcat itself. I think it'd > be better to do at the balancer (to ignore jvmRoute occasionally). The problem is that the balancer (e.g. mod_jk) doesn't know if the session id is valid without forwarding it to the Tomcat instance with the specified jvmroute. If you haven't already done so, please take a quick look back at the earlier posts in this thread to see the evolution of this proposal. Briefly, we were looking for something that would not require any changes to the balancer software (specifically, mod_jk and mod_proxy_ajp) so that it could be fixed in one version of one product (Tomcat). Fixing this in the balancer would require either a) a ping-style session-checking message to be designed and implemented in both the balancer and Tomcat or b) a custom HTTP response code from Tomcat that would trigger a re-balance at the balancer level. I'm sure there are other possibilities, but these were the ones I initially proposed. > If balancer sends request to a different Tomcat, tomcat can deal > with it thanks to JvmRouteBinderValve and like it deals with the > usual fail-over scenario. Of course. The Tomcat that eventually receives the (possibly re-balanced) request should not behave any differently than now. Thanks, - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEAREIAAYFAlDGYfMACgkQ9CaO5/Lv0PDwtgCgj478uOry6qn3rBsGPzyZ5vAH FvoAoLa+9iccQ6OE4+Sa02kBdQFotU+g =GyP4 -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org