RAP 2.3: Close a RAP application session and redirect to another page [message #1802504] |
Mon, 11 February 2019 03:39  |
Eclipse User |
|
|
|
Hi,
what is the recommended way to close a workbench-based RAP application (session) in response to a user action?
We are in the process of switching from login within the application to handling it outside (redirect to html form and back to application after successful authentication.)
The Logout handler within the application should now close the application and redirect back to the login page. What we have tried:
1) redirect from handler and invalidate the http session. Redirect does not work reliably (maybe debugging interferes) and I'm not sure the application cleans up resources
RWT.getClient().getService(JavaScriptExecutor.class).execute("parent.window.location.href=\"" + url + "\";");
RWT.getUISession().getHttpSession().setMaxInactiveInterval(1);
2) Close the workbench and redirect immediately. Redirect does't seem to work in that case
3) Close the workbench and redirect in IWorkbenchLIstener.postShutdown. Redirect does't seem to work in that case
Closing the workbench would feel much cleaner than the first approach - so basically the question boils down to: what is the best way to send a redirect in the processing of closing the application/workbench.
Any advice?
Thanks in advance
Moritz
|
|
|
|
Powered by
FUDForum. Page generated in 0.23478 seconds