Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

webui server is losing session context #701

Closed
teosarca opened this issue Nov 22, 2017 · 3 comments
Closed

webui server is losing session context #701

teosarca opened this issue Nov 22, 2017 · 3 comments

Comments

@teosarca
Copy link
Member

Is this a bug or feature request?

bug

What is the current behavior?

The session context gets lost after each request.

Which are the steps to reproduce?

It was causing the issues described here: metasfresh/metasfresh-webui-frontend-legacy#1280 (comment)

What is the expected or desired behavior?

Shall not be lost :)

@teosarca
Copy link
Member Author

note to IT: pls also check the Menu, Home etc tooltips.

teosarca added a commit to metasfresh/metasfresh that referenced this issue Nov 22, 2017
teosarca added a commit that referenced this issue Nov 22, 2017
i.e. before Language.getLoginLanguage() was indirectly called which was
calling some DAO which was calling Env.getCtx() which was trying to
fetch the context from here

#701
@teosarca
Copy link
Member Author

if you see things like this in console, pls ping me:

org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'scopedTarget.internalUserSessionData': Requested bean is currently in creation: Is there an unresolvable circular reference?
	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
	at org.springframework.aop.target.SimpleBeanTargetSource.getTarget(SimpleBeanTargetSource.java:35)
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.getTarget(CglibAopProxy.java:705)
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:655)
	at de.metas.ui.web.session.InternalUserSessionData$$EnhancerBySpringCGLIB$$8579425e.getCtx(<generated>)
	at de.metas.ui.web.session.UserSession.getCtx(UserSession.java:170)
	at de.metas.ui.web.session.WebRestApiContextProvider.getActualContext(WebRestApiContextProvider.java:104)
	at de.metas.ui.web.session.WebRestApiContextProvider.access$0(WebRestApiContextProvider.java:84)
	at de.metas.ui.web.session.WebRestApiContextProvider$1.getDelegate(WebRestApiContextProvider.java:54)
	at org.adempiere.util.AbstractPropertiesProxy.getProperty(AbstractPropertiesProxy.java:232)
	at org.compiere.util.Ini.getProperty(Ini.java:560)
	at org.compiere.util.Ini.isPropertyBool(Ini.java:589)
	at org.compiere.dbPort.Convert.logMigrationScript(Convert.java:292)
	at org.compiere.db.DB_PostgreSQL.convertStatement(DB_PostgreSQL.java:400)
	at org.adempiere.sql.impl.CPreparedStatementProxy.createVO(CPreparedStatementProxy.java:75)
	at org.adempiere.sql.impl.CPreparedStatementProxy.<init>(CPreparedStatementProxy.java:62)
	at org.adempiere.sql.impl.StatementsFactory.newCPreparedStatement(StatementsFactory.java:74)
	at org.compiere.util.DB.prepareStatement(DB.java:706)
	at org.compiere.util.DB.prepareStatement(DB.java:672)
	at org.adempiere.ad.dao.impl.TypedSqlQuery.list(TypedSqlQuery.java:306)
	at org.compiere.model.IQuery.stream(IQuery.java:513)
	at de.metas.i18n.impl.LanguageDAO.retrieveAvailableLanguages(LanguageDAO.java:67)
	at de.metas.i18n.impl.LanguageDAO_$$_jvst6_0._d11retrieveAvailableLanguages(LanguageDAO_$$_jvst6_0.java)
	at sun.reflect.GeneratedMethodAccessor427.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor.invokeForJavassist0(JavaAssistInterceptor.java:106)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor.access$0(JavaAssistInterceptor.java:90)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor$3.invoke(JavaAssistInterceptor.java:228)
	at de.metas.i18n.impl.LanguageDAO_$$_jvst6_0.retrieveAvailableLanguages(LanguageDAO_$$_jvst6_0.java)
	at sun.reflect.GeneratedMethodAccessor426.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.adempiere.util.proxy.impl.InvocationContext.proceed(InvocationContext.java:67)
	at org.adempiere.util.proxy.impl.InvocationContext.call(InvocationContext.java:81)
	at com.google.common.cache.LocalCache$LocalManualCache$1.load(LocalCache.java:5065)
	at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3716)
	at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2424)
	at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2298)
	at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2211)
	at com.google.common.cache.LocalCache.get(LocalCache.java:4154)
	at com.google.common.cache.LocalCache$LocalManualCache.get(LocalCache.java:5060)
	at org.compiere.util.CCache.get(CCache.java:477)
	at de.metas.adempiere.util.cache.CacheInterceptor.invokeCache(CacheInterceptor.java:243)
	at sun.reflect.GeneratedMethodAccessor252.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptorInstance.invoke(JavaAssistInterceptorInstance.java:81)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor.invokeForJavassist0(JavaAssistInterceptor.java:121)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor.access$0(JavaAssistInterceptor.java:90)
	at org.adempiere.util.proxy.impl.JavaAssistInterceptor$3.invoke(JavaAssistInterceptor.java:228)
	at de.metas.i18n.impl.LanguageDAO_$$_jvst6_0.retrieveAvailableLanguages(LanguageDAO_$$_jvst6_0.java)
	at org.compiere.util.Env.verifyLanguage(Env.java:1456)
	at de.metas.ui.web.session.InternalUserSessionData.verifyLanguageAndSet(InternalUserSessionData.java:223)
	at de.metas.ui.web.session.InternalUserSessionData.<init>(InternalUserSessionData.java:119)
	at sun.reflect.GeneratedConstructorAccessor1662.newInstance(Unknown Source)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
	at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:142)
	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:89)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:1147)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1099)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:513)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)
	at org.springframework.beans.factory.support.AbstractBeanFactory$2.getObject(AbstractBeanFactory.java:345)
	at org.springframework.web.context.request.AbstractRequestAttributesScope.get(AbstractRequestAttributesScope.java:44)
	at org.springframework.web.context.request.SessionScope.get(SessionScope.java:93)
	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:340)
	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197)
	at org.springframework.aop.target.SimpleBeanTargetSource.getTarget(SimpleBeanTargetSource.java:35)
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.getTarget(CglibAopProxy.java:705)
	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:655)
	at de.metas.ui.web.session.InternalUserSessionData$$EnhancerBySpringCGLIB$$8579425e.getUserName(<generated>)
	at de.metas.ui.web.session.UserSession.getUserName(UserSession.java:317)
	at de.metas.ui.web.config.ServletLoggingFilter.extractLoggedUser(ServletLoggingFilter.java:202)
	at de.metas.ui.web.config.ServletLoggingFilter.updateMDC(ServletLoggingFilter.java:118)
	at de.metas.ui.web.config.ServletLoggingFilter.doFilter(ServletLoggingFilter.java:87)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at de.metas.ui.web.config.CORSFilter.doFilter(CORSFilter.java:85)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.boot.actuate.trace.WebRequestTraceFilter.doFilterInternal(WebRequestTraceFilter.java:110)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:317)
	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:331)
	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:114)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:64)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at de.metas.ui.web.config.CORSFilter.doFilter(CORSFilter.java:85)
	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:331)
	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:214)
	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:177)
	at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)
	at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:262)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:105)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:81)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.session.web.http.SessionRepositoryFilter.doFilterInternal(SessionRepositoryFilter.java:167)
	at org.springframework.session.web.http.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:80)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.springframework.boot.actuate.autoconfigure.MetricsFilter.doFilterInternal(MetricsFilter.java:106)
	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
	at org.apache.catalina.core.StandardContextValve.__invoke(StandardContextValve.java:96)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java)
	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:478)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:80)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:799)
	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:861)
	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1455)
	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
	at java.lang.Thread.run(Thread.java:748)

@metas-lc metas-lc self-assigned this Nov 24, 2017
@metas-lc
Copy link

IT
login, set language to en_US
=> menu, tooltips, home - all are trl in en OK
go to settings and change language to de_DE. Do not refresh
=> menu, tooltips, home - all are trl in de OK
logout, login
=> language is still in de OK

metas-ts added a commit to metasfresh/metasfresh that referenced this issue Nov 26, 2017
[#1293](metasfresh/metasfresh-webui-frontend-legacy#1293)
Cannot scroll down in a filter with lots of parameters
[#669](metasfresh/metasfresh-webui-api-legacy#669)
CU-TU's built name and description is wrong
[#1366](metasfresh/metasfresh-webui-frontend-legacy#1366)
Error in Quickentry dropdown List
[#1345](metasfresh/metasfresh-webui-frontend-legacy#1345)
Invalid date was used on dateTime tablecell
[#701](metasfresh/metasfresh-webui-api-legacy#701)
webui server is losing session context
[#683](metasfresh/metasfresh-webui-api-legacy#683)
Source HU Actions shall only be "Drop Source HU"
[#1358](metasfresh/metasfresh-webui-frontend-legacy#1358)
View field editor: number field is behaving weird when using keyboard
[#2945](#2945) Adjustment
in pain001
[#3056](#3056) purchase
candidates: implement locking mechanism
[#694](metasfresh/metasfresh-webui-api-legacy#694)
purchase view: set modal title as process caption
[#700](metasfresh/metasfresh-webui-api-legacy#700)
Filter error after static filter set
[#3057](#3057) display
order, forecast or shipmentschedule in material dispo main window
[#3055](#3055) purchase
candidates: notify user when the purchase order was generated
[#697](metasfresh/metasfresh-webui-api-legacy#697)
New BPartner is not available as SubProducerBPartner in MaterialReceipt
BPartner
[#3034](#3034) solve
material dispo regressions
[#671](metasfresh/metasfresh-webui-api-legacy#671)
T_WEBUI_ViewSelection[Line] shall be truncated and not deleted
[#695](metasfresh/metasfresh-webui-api-legacy#695)
picking terminal: implement dynamic picking slot allocation/release
[#3043](#3043) A contract
shall not be created when a completing a quotation
[#1380](metasfresh/metasfresh-webui-frontend-legacy#1380)
Shortcut for new document
[#2944](#2944) Allow more
than 1 PostFinanceUserNo per Account
[#3023](#3023) ad_org is
ignored when doing quick order entry
[#1363](metasfresh/metasfresh-webui-frontend-legacy#1363)
jenkins: run npm test on each build
[#3010](#3010) Inherit
c_order_id and orderline_id from flatrate term to invoice candidate
[#2958](#2958) 2nd
Discount Break is ignored
[#2997](#2997) Partner
Import: Support importing the Org via value
[#689](metasfresh/metasfresh-webui-api-legacy#689)
Picking processed compress to top-level HU
[#692](metasfresh/metasfresh-webui-api-legacy#692)
Error in Quickentry Sales Order when canceling input
[#679](metasfresh/metasfresh-webui-api-legacy#679) HU
taken out in Picking Tray Clearing still displayed in the Picking Slot
in Picking Terminal
[#687](metasfresh/metasfresh-webui-api-legacy#687)
picking terminal: show BPartner instead of DeliveryDate
[#693](metasfresh/metasfresh-webui-api-legacy#693)
Error in create purchase orders from Sales order line
[#662](metasfresh/metasfresh-webui-api-legacy#662)
Aggregate Storage for Product and Warehouse
[#1351](metasfresh/metasfresh-webui-frontend-legacy#1351)
wrong backend api call for grid view editing

me-45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants