You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for you sample about to use Hikari connection pool.
I am trying your sample to integrate with our code, which is hybris 1811 upgrade from 5.2 so bundle with many legacy code like logger is using log4j.
During server startup HybrisStorefrontContextLoaderListener throw exception:
Any idea how to fix?
ront.filters.HybrisStorefrontContextLoaderListener]
java.lang.ExceptionInInitializerError
at de.hybris.platform.core.ClassLoaderUtils.executeWithWebClassLoaderParentIfNeeded(ClassLoaderUtils.java:42)
at de.hybris.platform.spring.HybrisContextLoaderListener.startRegistry(HybrisContextLoaderListener.java:325)
at de.hybris.platform.spring.HybrisContextLoaderListener.doInitWebApplicationContext(HybrisContextLoaderListener.java:211)
at de.hybris.platform.spring.HybrisContextLoaderListener.initWebApplicationContext(HybrisContextLoaderListener.java:199)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:107)
at de.hybris.platform.spring.HybrisContextLoaderListener.contextInitialized(HybrisContextLoaderListener.java:95)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4792)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5256)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1421)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1411)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassCastException: org.apache.logging.log4j.core.LoggerContext cannot be cast to de.hybris.platform.util.logging.log4j2.HybrisLoggerContext
at de.hybris.platform.util.logging.HybrisLogger.setLevel(HybrisLogger.java:512)
at org.apache.log4j.PropertyConfigurator.parseCategory(PropertyConfigurator.java:753)
at org.apache.log4j.PropertyConfigurator.parseCatsAndRenderers(PropertyConfigurator.java:672)
at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:516)
at de.hybris.platform.core.Log4JUtils.readConfig(Log4JUtils.java:103)
at de.hybris.platform.core.Log4JUtils.startup(Log4JUtils.java:56)
at de.hybris.platform.core.Registry.lambda$0(Registry.java:81)
at de.hybris.platform.core.ClassLoaderUtils.executeWithWebClassLoaderParentIfNeeded(ClassLoaderUtils.java:42)
at de.hybris.platform.core.Registry.<clinit>(Registry.java:79)
... 15 more
Apr 04, 2020 5:18:16 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: One or more listeners failed to start. Full details will be found in the appropriate container log file
Apr 04, 2020 5:18:16 PM org.apache.catalina.core.StandardContext startInternal
SEVERE: Context [] startup failed due to previous errors
The text was updated successfully, but these errors were encountered:
As you see we have many legacy dependency and when we start planing upgrade, 1811 is latest version so all test plan only cover 1811.
For the log4j2 doc, that suggests
It is not necessary to change the existing code that uses the Log4j API because all logs are redirected to Log4j 2.
so we just keep all old log4 logger and work fine until now.
i just think will this work if remove all log4 jar dependency but the doc do not cover more about totally remove old log4 jar.
Hi @TONYHOKAN ,
Could you check where the org.apache.logging.log4j.core.LoggerContext is being used in your code/configuration please?
The log4j JAR should only be in the platform folder but maybe Hybris 5.2 was still including such JARs in the custom extensions?
Thanks for you sample about to use Hikari connection pool.
I am trying your sample to integrate with our code, which is hybris 1811 upgrade from 5.2 so bundle with many legacy code like logger is using log4j.
During server startup HybrisStorefrontContextLoaderListener throw exception:
Any idea how to fix?
The text was updated successfully, but these errors were encountered: