[ 
https://issues.apache.org/jira/browse/WW-4842?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16117955#comment-16117955
 ] 

Yasser Zamani edited comment on WW-4842 at 8/8/17 7:14 AM:
-----------------------------------------------------------

It seems you wrongly have defined devMode as bean: {{<bean 
name="struts.devMode"  type="java.lang.String"   class="java.lang.String"/>}}.

devMode should be defined as constant : {{<constant name="struts.devMode" 
value="true"/>}}


was (Author: yasser.zamani):
It seems you wrongly have `<bean name="struts.devMode"  type="java.lang.String" 
  class="java.lang.String"/>`. devMode should be defined as constant : 
`<constant name="struts.devMode" value="true"/>`

> Struts 2 Fails to Initialize with JRebel
> ----------------------------------------
>
>                 Key: WW-4842
>                 URL: https://issues.apache.org/jira/browse/WW-4842
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Dispatch Filter
>    Affects Versions: 2.5.13
>            Reporter: Aaron Johnson
>            Priority: Minor
>
> * JRebel 7.0.13
> * Tomcat 8.5.15
> * Java 1.8.0_131
> {noformat}
> ERROR Dispatcher Dispatcher initialization failed
>  com.opensymphony.xwork2.inject.DependencyException: Dependency mapping for 
> [type=java.lang.String, name='struts.devMode'] already exists.
>       at 
> com.opensymphony.xwork2.inject.ContainerBuilder.checkKey(ContainerBuilder.java:108)
>       at 
> com.opensymphony.xwork2.inject.ContainerBuilder.factory(ContainerBuilder.java:83)
>       at 
> com.opensymphony.xwork2.inject.ContainerBuilder.constant(ContainerBuilder.java:517)
>       at 
> com.opensymphony.xwork2.inject.ContainerBuilder.constant(ContainerBuilder.java:398)
>       at 
> com.opensymphony.xwork2.config.impl.DefaultConfiguration.createBootstrapContainer(DefaultConfiguration.java:284)
>       at 
> com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:159)
>       at 
> com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:63)
>       at 
> org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:960)
>       at 
> org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:466)
>       at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:499)
>       at 
> org.apache.struts2.dispatcher.InitOperations.initDispatcher(InitOperations.java:75)
>       at 
> org.apache.struts2.dispatcher.listener.StrutsListener.contextInitialized(StrutsListener.java:46)
>       at 
> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4745)
>       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:1419)
>       at 
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
>       at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>       at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>       at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>       at java.lang.Thread.run(Thread.java:748)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to