Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4570

Conflicting dependencies in full lib distribution

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.3.24
    • 2.3.28, 2.5
    • Other
    • None
    • Tested both with Java 8 on Ubuntu 14 & Windows 7.

    Description

      Error when launching simple struts 2 application when all dependencies are added to WEB-INF/lib.

      It appears that some struts-plugin.xml are conflicting :

      • struts2-gxp-plugin
      • struts2-portlet-plugin

      If those dependencies are removed, then the Spring struts integration plugin complains because it is not properly initialized.
      It would be nice to be able to download a simple set of plugins with can be integrated to a webapp without worring about those dependencies.

      Full stack traces :

      Console
      nov. 20, 2015 8:46:45 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
      AVERTISSEMENT: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:DemoStruts' did not find a matching property.
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Server version:        Apache Tomcat/8.0.28
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Server built:          Oct 7 2015 18:25:21 UTC
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Server number:         8.0.28.0
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: OS Name:               Windows 7
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: OS Version:            6.1
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Architecture:          amd64
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Java Home:             C:\Program Files\Java\jre1.8.0_65
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: JVM Version:           1.8.0_65-b17
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: JVM Vendor:            Oracle Corporation
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: CATALINA_BASE:         C:\Users\ILI16\Documents\PERL\workspaceEclipse\.metadata\.plugins\org.eclipse.wst.server.core\tmp0
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: CATALINA_HOME:         C:\Program Files\apache-tomcat-8.0.28
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Command line argument: -Dcatalina.base=C:\Users\ILI16\Documents\PERL\workspaceEclipse\.metadata\.plugins\org.eclipse.wst.server.core\tmp0
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Command line argument: -Dcatalina.home=C:\Program Files\apache-tomcat-8.0.28
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Command line argument: -Dwtp.deploy=C:\Users\ILI16\Documents\PERL\workspaceEclipse\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Command line argument: -Djava.endorsed.dirs=C:\Program Files\apache-tomcat-8.0.28\endorsed
      nov. 20, 2015 8:46:45 AM org.apache.catalina.startup.VersionLoggerListener log
      INFOS: Command line argument: -Dfile.encoding=Cp1252
      nov. 20, 2015 8:46:45 AM org.apache.catalina.core.AprLifecycleListener lifecycleEvent
      INFOS: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jre1.8.0_65\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\ProgramData\Oracle\Java\javapath;C:\wamp\bin\perl\site\bin;C:\wamp\bin\perl\bin;C:\Perl\site\bin;C:\Perl\bin;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Strawberry\c\bin;C:\Strawberry\perl\site\bin;C:\Strawberry\perl\bin;C:\Windows\system32\config\systemprofile\.dnx\bin;C:\Program Files\Microsoft DNX\Dnvm\;C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin;.
      nov. 20, 2015 8:46:46 AM org.apache.coyote.AbstractProtocol init
      INFOS: Initializing ProtocolHandler ["http-nio-8080"]
      nov. 20, 2015 8:46:46 AM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
      INFOS: Using a shared selector for servlet write/read
      nov. 20, 2015 8:46:46 AM org.apache.coyote.AbstractProtocol init
      INFOS: Initializing ProtocolHandler ["ajp-nio-8009"]
      nov. 20, 2015 8:46:46 AM org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
      INFOS: Using a shared selector for servlet write/read
      nov. 20, 2015 8:46:46 AM org.apache.catalina.startup.Catalina load
      INFOS: Initialization processed in 390 ms
      nov. 20, 2015 8:46:46 AM org.apache.catalina.core.StandardService startInternal
      INFOS: Démarrage du service Catalina
      nov. 20, 2015 8:46:46 AM org.apache.catalina.core.StandardEngine startInternal
      INFOS: Starting Servlet Engine: Apache Tomcat/8.0.28
      nov. 20, 2015 8:46:47 AM org.apache.jasper.servlet.TldScanner scanJars
      INFOS: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      nov. 20, 2015 8:46:47 AM com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info
      INFOS: Parsing configuration file [struts-default.xml]
      nov. 20, 2015 8:46:48 AM com.opensymphony.xwork2.config.providers.XmlConfigurationProvider info
      INFOS: Parsing configuration file [struts-plugin.xml]
      nov. 20, 2015 8:46:48 AM org.apache.struts2.dispatcher.Dispatcher error
      GRAVE: Dispatcher initialization failed
      Unable to load configuration. - bean - jar:file:/C:/Users/ILI16/Documents/PERL/workspaceEclipse/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DemoStruts/WEB-INF/lib/struts2-gxp-plugin-2.3.24.1.jar!/struts-plugin.xml:8:162
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:70)
      	at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)
      	at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)
      	at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74)
      	at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57)
      	at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
      	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
      	at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
      	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4583)
      	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5207)
      	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at java.lang.Thread.run(Unknown Source)
      Caused by: Unable to load bean: type:org.apache.struts2.views.gxp.inject.InjectedObjectContainer class:org.apache.struts2.views.gxp.inject.InjectedObjectContainer - bean - jar:file:/C:/Users/ILI16/Documents/PERL/workspaceEclipse/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DemoStruts/WEB-INF/lib/struts2-gxp-plugin-2.3.24.1.jar!/struts-plugin.xml:8:162
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:247)
      	at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(StrutsXmlConfigurationProvider.java:102)
      	at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:240)
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67)
      	... 17 more
      Caused by: java.lang.ClassNotFoundException: org.apache.struts2.views.gxp.inject.InjectedObjectContainer
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1333)
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1167)
      	at com.opensymphony.xwork2.util.ClassLoaderUtil.loadClass(ClassLoaderUtil.java:152)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:218)
      	... 20 more
      
      nov. 20, 2015 8:46:48 AM org.apache.catalina.core.StandardContext filterStart
      GRAVE: Exception au démarrage du filtre struts2
      Unable to load configuration. - bean - jar:file:/C:/Users/ILI16/Documents/PERL/workspaceEclipse/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DemoStruts/WEB-INF/lib/struts2-gxp-plugin-2.3.24.1.jar!/struts-plugin.xml:8:162
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:493)
      	at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74)
      	at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57)
      	at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
      	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
      	at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
      	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4583)
      	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5207)
      	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at java.lang.Thread.run(Unknown Source)
      Caused by: Unable to load configuration. - bean - jar:file:/C:/Users/ILI16/Documents/PERL/workspaceEclipse/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DemoStruts/WEB-INF/lib/struts2-gxp-plugin-2.3.24.1.jar!/struts-plugin.xml:8:162
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:70)
      	at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)
      	at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)
      	... 14 more
      Caused by: Unable to load bean: type:org.apache.struts2.views.gxp.inject.InjectedObjectContainer class:org.apache.struts2.views.gxp.inject.InjectedObjectContainer - bean - jar:file:/C:/Users/ILI16/Documents/PERL/workspaceEclipse/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/DemoStruts/WEB-INF/lib/struts2-gxp-plugin-2.3.24.1.jar!/struts-plugin.xml:8:162
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:247)
      	at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(StrutsXmlConfigurationProvider.java:102)
      	at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:240)
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67)
      	... 17 more
      Caused by: java.lang.ClassNotFoundException: org.apache.struts2.views.gxp.inject.InjectedObjectContainer
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1333)
      	at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1167)
      	at com.opensymphony.xwork2.util.ClassLoaderUtil.loadClass(ClassLoaderUtil.java:152)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:218)
      	... 20 more
      
      nov. 20, 2015 8:46:48 AM org.apache.catalina.core.StandardContext startInternal
      GRAVE: One or more Filters failed to start. Full details will be found in the appropriate container log file
      nov. 20, 2015 8:46:48 AM org.apache.catalina.core.StandardContext startInternal
      GRAVE: Erreur de démarrage du contexte [/DemoStruts] suite aux erreurs précédentes
      nov. 20, 2015 8:46:48 AM org.apache.coyote.AbstractProtocol start
      INFOS: Starting ProtocolHandler ["http-nio-8080"]
      nov. 20, 2015 8:46:48 AM org.apache.coyote.AbstractProtocol start
      INFOS: Starting ProtocolHandler ["ajp-nio-8009"]
      nov. 20, 2015 8:46:48 AM org.apache.catalina.startup.Catalina start
      INFOS: Server startup in 2028 ms
      
      Console
      INFOS: Initializing Struts-Spring integration...
      nov. 20, 2015 9:05:37 AM org.apache.struts2.spring.StrutsSpringObjectFactory fatal
      GRAVE: ********** FATAL ERROR STARTING UP STRUTS-SPRING INTEGRATION **********
      Looks like the Spring listener was not configured for your web app! 
      Nothing will work until WebApplicationContextUtils returns a valid ApplicationContext.
      You might need to add the following to web.xml: 
          <listener>
              <listener-class&gt;org.springframework.web.context.ContextLoaderListener</listener-class&gt;
          </listener>
      nov. 20, 2015 9:05:37 AM org.apache.struts2.dispatcher.Dispatcher error
      GRAVE: Dispatcher initialization failed
      java.lang.NullPointerException
      	at com.opensymphony.xwork2.spring.SpringObjectFactory.getClassInstance(SpringObjectFactory.java:245)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.verifyResultType(XmlConfigurationProvider.java:608)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addResultTypes(XmlConfigurationProvider.java:578)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:534)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:295)
      	at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:112)
      	at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:264)
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67)
      	at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)
      	at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)
      	at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74)
      	at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57)
      	at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
      	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
      	at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
      	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4583)
      	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5207)
      	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at java.lang.Thread.run(Unknown Source)
      
      nov. 20, 2015 9:05:37 AM org.apache.catalina.core.StandardContext filterStart
      GRAVE: Exception au démarrage du filtre struts2
      Class: com.opensymphony.xwork2.spring.SpringObjectFactory
      File: SpringObjectFactory.java
      Method: getClassInstance
      Line: 245 - com/opensymphony/xwork2/spring/SpringObjectFactory.java:245:-1
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:493)
      	at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74)
      	at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57)
      	at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
      	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
      	at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
      	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4583)
      	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5207)
      	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1408)
      	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1398)
      	at java.util.concurrent.FutureTask.run(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      	at java.lang.Thread.run(Unknown Source)
      Caused by: java.lang.NullPointerException
      	at com.opensymphony.xwork2.spring.SpringObjectFactory.getClassInstance(SpringObjectFactory.java:245)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.verifyResultType(XmlConfigurationProvider.java:608)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addResultTypes(XmlConfigurationProvider.java:578)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:534)
      	at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:295)
      	at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:112)
      	at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:264)
      	at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67)
      	at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)
      	at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)
      	at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)
      	... 14 more
      
      nov. 20, 2015 9:05:37 AM org.apache.catalina.core.StandardContext startInternal
      GRAVE: One or more Filters failed to start. Full details will be found in the appropriate container log file
      nov. 20, 2015 9:05:37 AM org.apache.catalina.core.StandardContext startInternal
      GRAVE: Erreur de démarrage du contexte [/DemoStruts] suite aux erreurs précédentes
      nov. 20, 2015 9:05:37 AM org.apache.coyote.AbstractProtocol start
      INFOS: Starting ProtocolHandler ["http-nio-8080"]
      nov. 20, 2015 9:05:37 AM org.apache.coyote.AbstractProtocol start
      INFOS: Starting ProtocolHandler ["ajp-nio-8009"]
      nov. 20, 2015 9:05:37 AM org.apache.catalina.startup.Catalina start
      INFOS: Server startup in 2359 ms
      

      Attachments

        Issue Links

          Activity

            People

              lukaszlenart Lukasz Lenart
              SirBigoo Soann Dewasme
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: