[Logo] Enterprise Client Community
  [Search] Search   [Recent Topics] Recent Topics   [Members]  Member Listing   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Messages posted by: mmohr  XML
Profile for mmohr -> Messages posted by mmohr [7]
Author Message

CaptainCasa wrote:
snippet 

Hi Björn,
Thanks for your answer.
I checked what you said, but my problem is I cannot reproduce it locally (only happens on customer side) and it appears randomly.
So on my side workpagecontainer is not null when inspecting the dispatcher inside the constructor of the bean.
The code that's calling it looks like this, but I don't think this is of any help:
Code:
WorkplaceBean workplace = (WorkplaceBean) dispatcher.getDispatchedBean("workplace");

The bean extends "WorkpageDispatchedPageBean".
Is there any function that I could look out for that modifies the WorkpageContainer of the dispatcher, so that it could ever return null? Isn't the only possibility that "destroy" is called on a dispatcher which sets the WorkpageContainer to null?

Best regards
Marcel
Hi Björn,
I'm currently trying to solve an npe with the following stacktrace on cc version 20210201:
Code:
Caused by: java.lang.NullPointerException
                                               	at org.eclnt.workplace.WorkpageDefaultStarter.startWorkpage(WorkpageDefaultStarter.java:40)
                                               	at org.eclnt.workplace.WorkpageDefaultStarter.startWorkpage(WorkpageDefaultStarter.java:23)
                                               	at de.vps.act.frontend.workplace.controller.WorkplaceController.createBaseBean(WorkplaceController.java:74)
                                               	at de.vps.act.frontend.workplace.controller.WorkplaceController.openOverlayPopup(WorkplaceController.java:111)
                                               	at de.vps.act.frontend.workplace.controller.WorkplaceController.openProcessPage(WorkplaceController.java:101)
                                               	at de.vps.act.explorer.action.commands.CoreObjectHistoryButtonCommand.execute(CoreObjectHistoryButtonCommand.java:26)
                                               	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
                                               	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
                                               	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
                                               	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
                                               	at org.eclnt.jsfserver.util.StackedMethodExpression.invoke(StackedMethodExpression.java:68)
                                               	... 85 more

My code that calls captaincasa looks like this
Code:
private IWorkpage createBaseBean(final WorkpageStartInfo startInfo) {
         if (startInfo == null)
             return null;
         
         var topDispatcher = (IWorkpageDispatcher) m_bean.getOwningDispatcher().getTopOwner();
 
         return WorkpageStarterFactory.getWorkpageStarter().startWorkpage(
                 topDispatcher, topDispatcher.getWorkpageContainer(), startInfo);
     }

Apparently the WorkpageContainer that is returned by my topDispatcher is null, now I'm wondering how this can happen. The null WorkpageContainer leads later to the npe when passed to captaincasa code. I really have no idea how this can ever become null, do you have any idea how I can debug this further?

Best regards
Marcel
Thanks, makes sense now.
I implemented this as a popup and I want it to be closed, as soon as the download is finished.
The only thing I found as callback after the download has been finished is by overriding the "endGetting" method of "DefaultBufferedContent". Therefore i tried to put the removing of content and closing the popup in this method. Removing the content works, but now the popup doesn't close
Is this the wrong place for a "Download finished" callback or do you have any other idea?
Hi again,
thanks for the help, you were right. The log is indicating that the content is removed too early.
I'm using a filedownloadbutton. I have specified a method to be called on the downloadUrl property, which does the "BufferedContentMgr.add()" call if it hasn't been done. I also have an actionListener specified, which does the "BufferedContentMgr.remove()" call.
Is that correct, or should the "BufferedContentMgr.remove" rather be called somewhere else?
Hello,
I'm occasionally experiencing an issue using BufferedContent for downloading with multiple sessions simultaneously, but only when tomcat is running in docker. The exception says, that no Object has been found in buffered content. I'm of course making sure, that Code:
BufferedContentMgr.add()
is called with a non null value.

The exception looks like this:
Code:
Nov 15, 2021 1:46:24 PM org.apache.catalina.core.StandardWrapperValve invoke
 SEVERE: Servlet.service() for servlet [BufferedContentServlet] in context with path [] threw exception [Servlet execution threw an exception] with root cause
 java.lang.Exception: Could not find any object in buffered content
 	at org.eclnt.jsfserver.bufferedcontent.BufferedContentServlet.processRequest(BufferedContentServlet.java:64)
 	at org.eclnt.jsfserver.util.CCServletBaseWithContextMgmt.manageRequest(CCServletBaseWithContextMgmt.java:99)
 	at org.eclnt.jsfserver.util.CCServletBaseWithContextMgmt.doGet(CCServletBaseWithContextMgmt.java:52)
 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:655)
 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:764)
 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:227)
 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
 	at org.eclnt.jsfserver.util.ResponseLoggerFilter.doFilter(ResponseLoggerFilter.java:276)
 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
 	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:53)
 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:320)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:320)
 	at de.nexus.http.filter.SecurityHeaderFilter.doFilter(SecurityHeaderFilter.java:44)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:82)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.web.filter.ForwardedHeaderFilter.doFilterInternal(ForwardedHeaderFilter.java:149)
 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215)
 	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:186)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
 	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:119)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.authentication.www.BasicAuthenticationFilter.doFilterInternal(BasicAuthenticationFilter.java:158)
 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.authentication.ui.DefaultLoginPageGeneratingFilter.doFilter(DefaultLoginPageGeneratingFilter.java:206)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:200)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:74)
 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)
 	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:119)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)
 	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
 	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215)
 	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178)
 	at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:358)
 	at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:271)
 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:189)
 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:162)
 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:197)
 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:97)
 	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:540)
 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:135)
 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:92)
 	at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:687)
 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:78)
 	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:357)
 	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:382)
 	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:65)
 	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:895)
 	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1722)
 	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
 	at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1191)
 	at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
 	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
 	at java.base/java.lang.Thread.run(Thread.java:829)


Do you perhaps have any idea what this could be caused by?

Admin wrote:
Hi,

no LABEL (if used with FORMAT="date"), FIELD, FORMATTEDFIELD, CALENDARFIELD either use "java.util.Date" or its long-representation, or LocalDate.

Please convert to one of these formats. 


I tried displaying an epoch timestamp of some minutes ago, but that still displays a wrong time.
What I tried:
Code:
 LABELNode label = new LABELNode();
 label.setText("1618316807");
 label.setFormat("datetime");
 label.setTimezone(TimeZone.getDefault().getID());
 

Should show:04/13/2021 14:26:47
Instead shows: 01/19/1970 17:31:56

Do you have any idea what I'm doing wrong?
Hello,
I want to use a Label to display a timestamp that I receive from ldap. The timestamp is stored in the "GeneralizedTime" format, which I then pass as value for the Label.
An example of a timestamp: "20080508200557Z" should result in: 2008 May 8, 20:05:57. But in my testing it results in: 2606 April 30, 06:56:40.

Is the "GeneralizedTime" format supported at all?
 
Profile for mmohr -> Messages posted by mmohr [7]
Go to:   
Powered by JForum 2.1.6 © JForum Team