-
FEATURED COMPONENTS
First time here? Check out the FAQ!
I am getting NPE whenever I am invalidating session. Below is my code
System.out.println("Executions.getCurrent():"+Executions.getCurrent()); //Not null
ServletContext context = Sessions.getCurrent().getWebApp().getServletContext();
Map<String,HttpSession> multipleSessionMap = new HashMap<String,HttpSession>();
// code for putting session in map
HttpSession httpSession=multipleSessionMap.get("session");
httpSession.invalidate();
System.out.println("Executions.getCurrent() :"+Executions.getCurrent()); //returns null
Executions.sendRedirect("/success.zul");
I am getting Execution.getCurrent() before session invalidate call but after it sets to null.
Thanks for the help in advance.. Any help would be appreciated.
Hello
I will suggest you to read through below link's as they will give you more clear understanding about cleanups http://books.zkoss.org/wiki/ZKDeveloper'sReference/Customization/InitandCleanup
prefer using SessionCleanup to do your session cleaning http://www.zkoss.org/javadoc/latest/zk/org/zkoss/zk/ui/util/SessionCleanup.html
Harish.
Asked: 2015-04-14 13:52:21 +0800
Seen: 40 times
Last updated: Apr 22 '15
What's about WebSocket integration
wrong valueException come in front of modal popup [closed]
Use parameters in a conditional @command
Problems with multiple press and onCtrlKey
MVVM @save on the fly [closed]
Unable to activate destroyed desktop
org.zkoss.zk.ui.UiException: java.lang.ClassNotFoundException