Author |
Message |
06/04/2011 11:29:18
|
dstrigel
Power User
Joined: 09/12/2010 09:23:42
Messages: 69
Offline
|
Hello!
We have tried to implement a Log Off Button. Like in the Demo Workplace...
Code:
public void onButtonPressedLogOff( ActionEvent ae )
{
getWorkpageContainer().closeAllWorkpages( false, new Runnable()
{
public void run()
{
HttpSessionAccess.getCurrentHttpSession().invalidate();
}
} );
}
After pressing this button a error page is shown. Server Side Error
Code:
java.io.IOException: Server returned HTTP response code: 500 for URL: <a href="http://localhost:8080/antos-1.0/faces/jsp/workplace/surroundingpage.jsp;jsessionid=a159facae14cd3af0c38da63cd9e" target="_blank" rel="nofollow">http://localhost:8080/antos-1.0/faces/jsp/workplace/surroundingpage.jsp;jsessionid=a159facae14cd3af0c38da63cd9e</a>
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
at org.eclnt.client.comm.http.DataTransfer.transferXML(DataTransfer.java:692)
at org.eclnt.client.comm.http.DataTransfer.communicateToServerSynchronous(DataTransfer.java:217)
at org.eclnt.client.page.Page.transferDataRun(Page.java:1021)
Does someone have an idea what could be wrong?
Kind regards,
Daniel
|
|
|
06/04/2011 13:41:08
|
CaptainCasa
Power User
Joined: 21/11/2007 12:23:06
Messages: 5555
Offline
|
...will check.
I remeber, that you are using Glassfish. We'll test with the most current version, if you have a specific version that you prefer, pls tell us.
Regards, Björn
|
Björn Müller, CaptainCasa GmbH |
|
|
06/04/2011 13:53:04
|
dstrigel
Power User
Joined: 09/12/2010 09:23:42
Messages: 69
Offline
|
current version is fine...
Regards,
Daniel
|
|
|
06/04/2011 15:50:03
|
CaptainCasa
Power User
Joined: 21/11/2007 12:23:06
Messages: 5555
Offline
|
Hi,
for whatever reason, Glassfish does remove all http-response-header parameters for the response, in which the session was invalidated!!! One of them "eclnt-reload" is indicating to the client to internally re-start with a new session.
This seems to be a Glassfish Bug.
We'll check if we can do a bypass on our side...
Regards, Björn
|
Björn Müller, CaptainCasa GmbH |
|
|
06/04/2011 17:00:38
|
CaptainCasa
Power User
Joined: 21/11/2007 12:23:06
Messages: 5555
Offline
|
Hi,
end of analysis: it's not the response header parameters that are missing - it's the whole response that is returned as 500-repsonse.
Björn
Code:
Glassfish:
HTTP/1.1 500 Internal Server Error
eclnt-reload: true
Content-Encoding: gzip
Content-Length: 236
Tomcat:
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
X-Powered-By: JSF/2.0
Set-Cookie: JSESSIONID=9A7B15EB755C2B4E6A902514F506AB09; Path=/demos; HttpOnly
eclnt-reload: true
Content-Encoding: gzip
Content-Type: text/html;charset=UTF-8
|
Björn Müller, CaptainCasa GmbH |
|
|
06/04/2011 17:23:44
|
CaptainCasa
Power User
Joined: 21/11/2007 12:23:06
Messages: 5555
Offline
|
...and the end of the story is: we now check returned header parameters also in the error case ("500") on client side.
Or, in short words: it now works, also with Glassfish... - the change is part of the next regluar update, or earlier on your request.
Thanks for your input +
Regards! Björn
|
Björn Müller, CaptainCasa GmbH |
|
|
07/04/2011 08:33:24
|
dstrigel
Power User
Joined: 09/12/2010 09:23:42
Messages: 69
Offline
|
Thanks for the quick solution!
Regards,
Daniel
|
|
|
|