A possible solution is check Attributes.RENEW_NATIVE_SESSION attribute in org.zkoss.zk.ui.http.SimpleSession.sessionWillPassivate() method, then try to call SimpleSession.sessionWillPassivate() again while new session ready.