Liang
I don't understand what NIO has to do with it. The
response.sendRedirect() is part of the servlet spec and what type
connector you are using in Tomcat should have no effect on this. I'd
appreciate it if someone would correct me here if I am wrong. As a
matter of interest I use redirects extensively on tomcats with NIO, APR
and the standard connector and they all work ok.
As Johnny K correctly observed and as its name implies it sends a
'redirect' 302 response to the browser. As also observed the 'session'
is a UNIQUE relationship between the server and the browser. I think it
would be helpful if the you actually clarified exactly the purpose of
redirecting from one tomcat instance to another.
On another point from the your earlier message you talk of a 'refused
session' being the reason for a redirect. AFAIKS a 'refused session' is
no session at all. Maybe a better way of putting it is refusing to start
a new session? Sending a redirect would allow a session to be created
between the browser and the 2nd server. But it does sound suspiciously
like load balancing to me... and of course there is the issue of making
sessions sticky. So I would agree with Johnny and others as below, use
something like mod_jk and a cluster.
Regards
Alan Chaney
Johnny Kewl wrote:
Liang,
I think whats bothering all of us, is that sometimes the concept itself
is going wrong, and that what I think the other guys are asking.
As you can see, you now getting into cookie management and all that
heavy stuff, and eventually maybe suicide ;)
If its load sharing, maybe think about putting it behind Apache and
using a JK connector. I'm not sure if there or NIO issues there, maybe
the other guys can comment... but if something like that is possible,
then your servlets are standard and JK is watching sessions and doing
all that for you.
Just a thought..
---------------------------------------------------------------------------
HARBOR: http://coolharbor.100free.com/index.htm
The most powerful application server on earth.
The only real POJO Application Server.
Only appearing once now in emails ;)
---------------------------------------------------------------------------
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
!DSPAM:482c8ec0298441572928584!
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]