0

auEngine threw exception: org.zkoss.zk.ui.DesktopUnavailableException: Unable to activate destroyed desktop

asked 2021-09-10 20:32:36 +0800

avabyabhi gravatar image avabyabhi
1

Hi Team,

We are getting below error stack trace on production environment. The sequence of line that are executed :

  1. invalidating the session
  2. logger.info("custom message")
  3. Clients.evalJavaScript('backToURL()')

The logs confirmed the execution till second statement and we can see custom message in the below stack trace as : ssoTokenIdT2d5WXlHdkw5K2U4YjNIc1ZkYnNZOUZ1OUQvRk4yMmtYaEZkR2twS3NFSXV2dDFkZW9IK21zVm1uQlk3KzRORVpMNnVWS2ZCeThpOXdaZ3Vxdm16YlNWWTZOMXhVdTR6Q2tXSk5nOUkvZnFJMDQ5Q1dZaXlXd3crNWpsRFRGalkxZzQ0YmxpYkVESzNhT0szK3U0N0RlRGNQZks1L1NWRGV4YUNxbk5GcFZ0bFZUQUh1SUd4RG5qaktiWWJrY2VG

After that the session expires. Also it should be noted that the issue is arising in some browser while it is not working in others. We checked the version and other troubleshooting details of the browser and they are same. Please suggest.

===================================

(Thread-17921) ssoTokenIdT2d5WXlHdkw5K2U4YjNIc1ZkYnNZOUZ1OUQvRk4yMmtYaEZkR2twS3NFSXV2dDFkZW9IK21zVm1uQlk3KzRORVpMNnVWS2ZCeThpOXdaZ3Vxdm16YlNWWTZOMXhVdTR6Q2tXSk5nOUkvZnFJMDQ5Q1dZaXlXd3crNWpsRFRGalkxZzQ0YmxpYkVESzNhT0szK3U0N0RlRGNQZks1L1NWRGV4YUNxbk5GcFZ0bFZUQUh1SUd4RG5qaktiWWJrY2VG 12:29:26,843 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/].[auEngine]] (http-/0.0.0.0:8082-5) JBWEB000236: Servlet.service() for servlet auEngine threw exception: org.zkoss.zk.ui.DesktopUnavailableException: Unable to activate destroyed desktop, [Desktop zgaw:/WEB-INF/zul/core/MainLayout.zul] at org.zkoss.zk.ui.impl.UiEngineImpl.doActivate(UiEngineImpl.java:1706) [zk.jar:5.0.6] at org.zkoss.zk.ui.impl.UiEngineImpl.execUpdate(UiEngineImpl.java:1059) [zk.jar:5.0.6] at org.zkoss.zk.au.http.DHtmlUpdateServlet.process(DHtmlUpdateServlet.java:563) [zk.jar:5.0.6] at com.tcs.sgv.zk.controller.BaseDHtmlUpdateServlet.process(BaseDHtmlUpdateServlet.java:136) [DigiGOVGUIFramework.jar:] at org.zkoss.zk.au.http.DHtmlUpdateServlet.doGet(DHtmlUpdateServlet.java:457) [zk.jar:5.0.6] at com.tcs.sgv.zk.controller.BaseDHtmlUpdateServlet.doGet(BaseDHtmlUpdateServlet.java:70) [DigiGOVGUIFramework.jar:] at org.zkoss.zk.au.http.DHtmlUpdateServlet.doPost(DHtmlUpdateServlet.java:465) [zk.jar:5.0.6] at com.tcs.sgv.zk.controller.BaseDHtmlUpdateServlet.doPost(BaseDHtmlUpdateServlet.java:150) [DigiGOVGUIFramework.jar:] at javax.servlet.http.HttpServlet.service(HttpServlet.java:754) [jboss-servlet-api3.0spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1] at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api3.0spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:378) [spring-security-core-2.0.5.jar:] at org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109) [spring-security-core-2.0.5.jar:] at org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter.doFilterHttp(SecurityContextHolderAwareRequestFilter.java:91) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.logout.LogoutFilter.doFilterHttp(LogoutFilter.java:89) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at com.tcs.sgv.acl.security.filter.ApplicationContextIntegrationFilter.doFilterHttp(ApplicationContextIntegrationFilter.java:120) [Security.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at com.tcs.sgv.acl.security.filter.BlackListedIPFilter.doFilterHttp(BlackListedIPFilter.java:79) [Security.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.AbstractProcessingFilter.doFilterHttp(AbstractProcessingFilter.java:278) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.preauth.AbstractPreAuthenticatedProcessingFilter.doFilterHttp(AbstractPreAuthenticatedProcessingFilter.java:69) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.context.HttpSessionContextIntegrationFilter.doFilterHttp(HttpSessionContextIntegrationFilter.java:235) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at com.tcs.sgv.acl.security.filter.ROBORequestFilter.doFilterHttp(ROBORequestFilter.java:122) [Security.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.securechannel.ChannelProcessingFilter.doFilterHttp(ChannelProcessingFilter.java:116) [spring-security-core-2.0.5.jar:] at org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:390) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterChainProxy.doFilter(FilterChainProxy.java:175) [spring-security-core-2.0.5.jar:] at org.springframework.security.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:99) [spring-security-core-2.0.5.jar:] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:231) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:420) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.4.0.Final-redhat-19.jar:7.4.0.Final-redhat-19] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:344) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:926) [jbossweb-7.4.8.Final-redhat-4.jar:7.4.8.Final-redhat-4] at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.079]

delete flag offensive retag edit

1 Reply

Sort by ยป oldest newest

answered 2021-09-13 16:34:28 +0800

MDuchemin gravatar image MDuchemin
1986 1 5
ZK Team

Hi There,

Regarding the error itself: org.zkoss.zk.ui.DesktopUnavailableException: Unable to activate destroyed desktop This error is thrown when a destroyed desktop is targeted for activation.

Desktop is the ZK representation of a browser tab at server-side. (it's slightly more complicated than that, but that statement is true in 95% of cases).

Desktops can be destroyed for multiple reasons. First and most obvious, a desktop is destroyed if the corresponding browser tab is closed. A desktop can also be destroyed if it is older than the desktop expiration limit, if the parent session containing the desktop is invalidated, or if the user has more tabs opened at the same time than the limit of desktop-per-session.

A good option while debugging would be to output desktop creation and destruction events to the console. This way, you can monitor when desktops are destroyed, and identify why. cleanup interface, init interface

From the stacktrace, I can see that you are doing some internal redirection. I assume you are doing SSO authentication, and redirecting the user to a login / auth page if they are reaching your webapp without an active session.

I see that you are landing at DHtmlUpdateServlet which is usually tapped by zkau requests. (UI update requests). This might have an effect of the order of executions of the requests.

You mentioned that the issue is happening in some browsers (I understand, some installations of a specific browser type and version). If this is timing / processing related, you might be encountering an issue based on network lag and response times. I'd recommend trying to set a network delay in your browser developer tools to try and reproduce locally. (you can change network condition to 3G or 2G mobile network in chrome dev tools for example.)

Have a look and let us know how it goes.

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
2 followers

RSS

Stats

Asked: 2021-09-10 20:32:36 +0800

Seen: 6 times

Last updated: Sep 13

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More