Anthony Vromant schrieb:
> Hi,
> 
> The scenario you explained me doesn't work in my env. I'm trying to find
> out the reasons below :
> 
> Here is the code :
> 
> jk_lb_worker.c : "find_bysession_route()"
> 
> candidate = find_by_session(p, name, l);
> 
>   if (!candidate) {
>       uses_domain = 1;
>       candidate = find_best_bydomain(p, name, l);
>   }
> 
> If route was changed on a worker, "find_by_session()" method can't find
> a good worker (and thus its domain).

It's not necessary to find a "good" worker (whatever that would mean).
find_by_session() only checks for a worker with the right name. So the
question is: why did you change the route? If you changed the route,
because the session was invalid, we proceed with a request without
session id and it can be balanced to any "active" node. In all other
cases we don't want to change the route. Then the function finds the
worker as a candidate and the code will bypass the "if" above. The next
part of the code checks, if the candidate does work (is usable). If not,
it will use the redirect or domain attributes to find an alternative.

> 
> It seems to me strange in this case, to call "find_best_bydomain()"
> method with a route in parameter whereas a domain name is expected  ?

This part of the code does not fit into our discussion. It can be used
for stateless service swithout stickyness. You can have the same
jvmRoute on a set of nodes and then have different workers, each with
domain=jvmRoute. This is not necessary any more, because we now can
define "route" of a worker. This feature did not exist, when the above
code was written.

> 
> With the current code, when a route is modified (!candidate), domain
> affinity doesn't work anymore for the old active session related to the
> changed worker ?
> Is it a normal behavior according to you ?

Why do you want to modify the route?

> 
> The JSESSIONID only knows the route, but not the domain and the code
> have to cope with this miss.
> By the way, I've also tried to use routes with a period like
> 'domain.worker', but it changes nothing.

Regards,

Rainer

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to