|
We are upgrading DWR v2 to v3 for our application that is deployed in websphere v8. before upgrading all struts creator are working fine. after upgrading the DWR jar file, when deploying the application we got the "failed to add struts creator error" and all struts creator are not able to be created. The DWT test page also return a blank page, that means no creator at all.
For this upgrade, we didn't change anything else except the dwr.jar upgrade. Please help to look at what went wrong. thanks. The dwr.xml is as below: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <convert converter="bean" match="com.form.ViewClientProfileForm"/> <create creator="struts" javascript="ViewClientProfileForm"> <include method="getTransactionAccessListAjax"/> </create> </allow> </dwr> in web.xml, the dwr configure: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet> the struts config: <servlet> <servlet-name>action</servlet-name> <servlet-class>com.aviva.framework.struts.ExtendedActionServlet</servlet-class> <init-param> <param-name>application</param-name> <param-value>/firiumconfig/IplanResources</param-value> </init-param> <init-param> <param-name>config</param-name> <param-value> /WEB-INF/struts-config-aa.xml, </param-value> </init-param> <init-param> <param-name>debug</param-name> <param-value>3</param-value> </init-param> <init-param> <param-name>detail</param-name> <param-value>3</param-value> </init-param> <init-param> <param-name>validate</param-name> <param-value>true</param-value> </init-param> <load-on-startup>2</load-on-startup> </servlet> The struts config: <form-bean name="viewClientProfileForm" type="com.form.ViewClientProfileForm"/> the error: org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=ViewClientProfileForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) |
|
Administrator
|
Hi cyb,
It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
Hi Mike,
Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
Administrator
|
I see. I've improved the logging in StrutsCreator; download and run
with the updated dwr.jar from here:
and tell us what you get in the exception
stacktrace.
Best regards
Mike
Yabing Chen wrote:
Hi Mike, |
|
Hi Mike,
Thanks. I have deployed using the latest jar file. attached please find the error log file. looks like it is the same error as before. but now there is a bit more information that shows it is caused by a nullpointexception from StrutsCreator.getType (line 93). The sample dwr.xml is: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <create creator="struts" javascript="PortfolioBuilderForm"> <param name="formBean" value="portfolioBuilderForm"/> <include method="formatAndCalculateTmpPercentage"/> <include method="getStrTmpTotalMix"/> <include method="getSubTotalOfTmpTargetMix"/> <include method="formatPercentage"/> </create> <create creator="struts" javascript="PortfolioRebalancerForm"> <param name="formBean" value="portfolioRebalancerForm"/> <include method="setAndFormatSwitchAmount"/> </create> </allow> ... </dwr> and the dwr config in web.xml: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet>
I see. I've improved the logging in StrutsCreator; download and run with the updated dwr.jar from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-382/artifact and tell us what you get in the exception stacktrace. Best regards Mike Yabing Chen wrote: Hi Mike, Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
Administrator
|
Ok, it seems something unexpected is happening. Could
you please tell me the following:
Best
regards
Mike
Yabing Chen wrote:
Hi Mike, |
|
Hi Mike,
We are using Struts 1.2.9. In the log it shows "Using Struts 1.2 based ModuleUtils code", then followed by the previous error logs. you can find all trace in the attached file. Thanks.
Ok, it seems something unexpected is happening. Could you please tell me the following:
Mike Yabing Chen wrote: Hi Mike, Thanks. I have deployed using the latest jar file. attached please find the error log file. looks like it is the same error as before. but now there is a bit more information that shows it is caused by a nullpointexception from StrutsCreator.getType (line 93). The sample dwr.xml is: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <create creator="struts" javascript="PortfolioBuilderForm"> <param name="formBean" value="portfolioBuilderForm"/> <include method="formatAndCalculateTmpPercentage"/> <include method="getStrTmpTotalMix"/> <include method="getSubTotalOfTmpTargetMix"/> <include method="formatPercentage"/> </create> <create creator="struts" javascript="PortfolioRebalancerForm"> <param name="formBean" value="portfolioRebalancerForm"/> <include method="setAndFormatSwitchAmount"/> </create> </allow> ... </dwr> and the dwr config in web.xml: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet>
I see. I've improved the logging in StrutsCreator; download and run with the updated dwr.jar from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-382/artifact and tell us what you get in the exception stacktrace. Best regards Mike Yabing Chen wrote: Hi Mike, Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
Administrator
|
Thanks, that helped me locate the problem and I have logged it
as:
I have implemented a fix to what seems to be the problem, and you
can download a new build from here:
Please test this and get back to us and tell us if it solves your
problem!
Best regards
Mike
Yabing Chen
wrote:
Hi Mike, |
|
Hi Mike,
Thanks for the prompt solution. The new build solved the previous error. Now all the struts creators are added and I can see the list of known modules. However, when I tested the application, the dwr ajax call is not working. Not much log information are displaed and I copied them below. The original error, the "session error" pop up window also disappear now. it appeared when I was using the combination of dwr 2.0.5 and WebSphere v8, the error log was showing it was because the potential csrf attack. Actually that's the reason why I tried to upgrade to dwr 3. Since the new version is not officially released yet, I'd like to find alternative solution to solve "session error" pop up that stops dwr ajax call in our production environment. I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? Meanwhile I would continue testing the dwr 3 in our development environment. The log when application is deployed using the new dwr build: [1/18/12 9:26:26:399 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.Exceptio n. Using org.directwebremoting.convert.ExceptionConverter in place of org.directwebremoting.convert.ExceptionConverter [1/18/12 9:26:26:403 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.StackTra ceElement. Using org.directwebremoting.convert.BeanConverter in place of org.directwebremoting.convert.BeanConverter the log when I move to a page where dwr ajax call is present. [1/18/12 9:58:26:273 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/Cx9x] from /xxx/xxx.do [1/18/12 10:01:26:287 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/0c$w] from /xxx/dwr/test/xxxForm
Thanks, that helped me locate the problem and I have logged it as: http://bugs.directwebremoting.org/jira/browse/DWR-553 I have implemented a fix to what seems to be the problem, and you can download a new build from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-383 Please test this and get back to us and tell us if it solves your problem! Best regards Mike Yabing Chen wrote: Hi Mike, We are using Struts 1.2.9. In the log it shows "Using Struts 1.2 based ModuleUtils code", then followed by the previous error logs. you can find all trace in the attached file. Thanks.
Ok, it seems something unexpected is happening. Could you please tell me the following:
Mike Yabing Chen wrote: Hi Mike, Thanks. I have deployed using the latest jar file. attached please find the error log file. looks like it is the same error as before. but now there is a bit more information that shows it is caused by a nullpointexception from StrutsCreator.getType (line 93). The sample dwr.xml is: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <create creator="struts" javascript="PortfolioBuilderForm"> <param name="formBean" value="portfolioBuilderForm"/> <include method="formatAndCalculateTmpPercentage"/> <include method="getStrTmpTotalMix"/> <include method="getSubTotalOfTmpTargetMix"/> <include method="formatPercentage"/> </create> <create creator="struts" javascript="PortfolioRebalancerForm"> <param name="formBean" value="portfolioRebalancerForm"/> <include method="setAndFormatSwitchAmount"/> </create> </allow> ... </dwr> and the dwr config in web.xml: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet>
I see. I've improved the logging in StrutsCreator; download and run with the updated dwr.jar from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-382/artifact and tell us what you get in the exception stacktrace. Best regards Mike Yabing Chen wrote: Hi Mike, Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
"However, when I tested the
application,
the dwr ajax call is not working."
You need to provide more information. "Not working" doesn't help. What errors are you getting? Have you debugged the problem (looked at request/response in Firebug, etc.)? "I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? " Prior to the development version DWR read the session cookie and used that as a token for the double submit cookie pattern to prevent CSRF. Most containers now have a default configuration that does not allow clients to read the session cookie which presents a problem. You have already mentioned one work-around, the other work-around also presents a security concern (configure your container to allow the client to read the session cookie). On 01/17/2012 07:50 PM, Yabing Chen wrote: Hi Mike, |
|
Hi David & Mike,
I found out how to solve the issue. it was because of the sequence of dwr js include statements in my jsp page. the sequence was as below and working in dwr 2. /dwr/interface/xxx.js /dwr/engine.js /dwr/util.js then the firebug shows a xxx is not defined error. So I changed the order as below and then the error disappear and the dwr call in is working because I can see my list is populated in the web page. /dwr/engine.js /dwr/util.js /dwr/interface/xxx.js With the new version, we will change the order of dwr js includes for all the jsp page. Btw, since the new build is in development release, when do you think we can start to use the new build in production as stable release? thanks.
"However, when I tested the application, the dwr ajax call is not working." You need to provide more information. "Not working" doesn't help. What errors are you getting? Have you debugged the problem (looked at request/response in Firebug, etc.)? "I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? " Prior to the development version DWR read the session cookie and used that as a token for the double submit cookie pattern to prevent CSRF. Most containers now have a default configuration that does not allow clients to read the session cookie which presents a problem. You have already mentioned one work-around, the other work-around also presents a security concern (configure your container to allow the client to read the session cookie). On 01/17/2012 07:50 PM, Yabing Chen wrote: Hi Mike, Thanks for the prompt solution. The new build solved the previous error. Now all the struts creators are added and I can see the list of known modules. However, when I tested the application, the dwr ajax call is not working. Not much log information are displaed and I copied them below. The original error, the "session error" pop up window also disappear now. it appeared when I was using the combination of dwr 2.0.5 and WebSphere v8, the error log was showing it was because the potential csrf attack. Actually that's the reason why I tried to upgrade to dwr 3. Since the new version is not officially released yet, I'd like to find alternative solution to solve "session error" pop up that stops dwr ajax call in our production environment. I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? Meanwhile I would continue testing the dwr 3 in our development environment. The log when application is deployed using the new dwr build: [1/18/12 9:26:26:399 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.Exceptio n. Using org.directwebremoting.convert.ExceptionConverter in place of org.directwebremoting.convert.ExceptionConverter [1/18/12 9:26:26:403 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.StackTra ceElement. Using org.directwebremoting.convert.BeanConverter in place of org.directwebremoting.convert.BeanConverter the log when I move to a page where dwr ajax call is present. [1/18/12 9:58:26:273 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/Cx9x] from /xxx/xxx.do [1/18/12 10:01:26:287 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/0c$w] from /xxx/dwr/test/xxxForm
Thanks, that helped me locate the problem and I have logged it as: http://bugs.directwebremoting.org/jira/browse/DWR-553 I have implemented a fix to what seems to be the problem, and you can download a new build from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-383 Please test this and get back to us and tell us if it solves your problem! Best regards Mike Yabing Chen wrote: Hi Mike, We are using Struts 1.2.9. In the log it shows "Using Struts 1.2 based ModuleUtils code", then followed by the previous error logs. you can find all trace in the attached file. Thanks.
Ok, it seems something unexpected is happening. Could you please tell me the following:
Mike Yabing Chen wrote: Hi Mike, Thanks. I have deployed using the latest jar file. attached please find the error log file. looks like it is the same error as before. but now there is a bit more information that shows it is caused by a nullpointexception from StrutsCreator.getType (line 93). The sample dwr.xml is: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <create creator="struts" javascript="PortfolioBuilderForm"> <param name="formBean" value="portfolioBuilderForm"/> <include method="formatAndCalculateTmpPercentage"/> <include method="getStrTmpTotalMix"/> <include method="getSubTotalOfTmpTargetMix"/> <include method="formatPercentage"/> </create> <create creator="struts" javascript="PortfolioRebalancerForm"> <param name="formBean" value="portfolioRebalancerForm"/> <include method="setAndFormatSwitchAmount"/> </create> </allow> ... </dwr> and the dwr config in web.xml: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet>
I see. I've improved the logging in StrutsCreator; download and run with the updated dwr.jar from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-382/artifact and tell us what you get in the exception stacktrace. Best regards Mike Yabing Chen wrote: Hi Mike, Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
|
Administrator
|
We can't give you a date, but if you are just upgrading
from a working 2.x setup then I expect that you can use the current development
build for production as the 2.x features are stable, and the development
version are in many ways better than the 2.x version. You can then upgrade
to 3.0.RC3 or 3.0 once they become available. We will document any potentially
breaking changes for these versions in their release notes so you can see if you
need to do any adjustments to your code.
Best regards
Mike
Hi David & Mike, |
|
Hi Mike,
That's a good idea. Thank you very much for your help!
We can't give you a date, but if you are just upgrading from a working 2.x setup then I expect that you can use the current development build for production as the 2.x features are stable, and the development version are in many ways better than the 2.x version. You can then upgrade to 3.0.RC3 or 3.0 once they become available. We will document any potentially breaking changes for these versions in their release notes so you can see if you need to do any adjustments to your code. Best regards Mike Yabing Chen wrote: Hi David & Mike, I found out how to solve the issue. it was because of the sequence of dwr js include statements in my jsp page. the sequence was as below and working in dwr 2. /dwr/interface/xxx.js /dwr/engine.js /dwr/util.js then the firebug shows a xxx is not defined error. So I changed the order as below and then the error disappear and the dwr call in is working because I can see my list is populated in the web page. /dwr/engine.js /dwr/util.js /dwr/interface/xxx.js With the new version, we will change the order of dwr js includes for all the jsp page. Btw, since the new build is in development release, when do you think we can start to use the new build in production as stable release? thanks.
"However, when I tested the application, the dwr ajax call is not working." You need to provide more information. "Not working" doesn't help. What errors are you getting? Have you debugged the problem (looked at request/response in Firebug, etc.)? "I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? " Prior to the development version DWR read the session cookie and used that as a token for the double submit cookie pattern to prevent CSRF. Most containers now have a default configuration that does not allow clients to read the session cookie which presents a problem. You have already mentioned one work-around, the other work-around also presents a security concern (configure your container to allow the client to read the session cookie). On 01/17/2012 07:50 PM, Yabing Chen wrote: Hi Mike, Thanks for the prompt solution. The new build solved the previous error. Now all the struts creators are added and I can see the list of known modules. However, when I tested the application, the dwr ajax call is not working. Not much log information are displaed and I copied them below. The original error, the "session error" pop up window also disappear now. it appeared when I was using the combination of dwr 2.0.5 and WebSphere v8, the error log was showing it was because the potential csrf attack. Actually that's the reason why I tried to upgrade to dwr 3. Since the new version is not officially released yet, I'd like to find alternative solution to solve "session error" pop up that stops dwr ajax call in our production environment. I understand one work around is to disable the crossDomainSessionSecurity in web.xml, but it pose a security concern. So please advise what are the other ways to solve the error without having to upgrading to dwr 3? Meanwhile I would continue testing the dwr 3 in our development environment. The log when application is deployed using the new dwr build: [1/18/12 9:26:26:399 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.Exceptio n. Using org.directwebremoting.convert.ExceptionConverter in place of org.directwebremoting.convert.ExceptionConverter [1/18/12 9:26:26:403 CST] 00000030 startup W org.directwebremoting.impl.DefaultConverterManager addConverter Clash of converters for java.lang.StackTra ceElement. Using org.directwebremoting.convert.BeanConverter in place of org.directwebremoting.convert.BeanConverter the log when I move to a page where dwr ajax call is present. [1/18/12 9:58:26:273 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/Cx9x] from /xxx/xxx.do [1/18/12 10:01:26:287 CST] 00000072 session 1 org.directwebremoting.impl.DefaultScriptSessionManager invalidate Invalidating DefaultScriptSession[id=mC2C/0c$w] from /xxx/dwr/test/xxxForm
Thanks, that helped me locate the problem and I have logged it as: http://bugs.directwebremoting.org/jira/browse/DWR-553 I have implemented a fix to what seems to be the problem, and you can download a new build from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-383 Please test this and get back to us and tell us if it solves your problem! Best regards Mike Yabing Chen wrote: Hi Mike, We are using Struts 1.2.9. In the log it shows "Using Struts 1.2 based ModuleUtils code", then followed by the previous error logs. you can find all trace in the attached file. Thanks.
Ok, it seems something unexpected is happening. Could you please tell me the following:
Mike Yabing Chen wrote: Hi Mike, Thanks. I have deployed using the latest jar file. attached please find the error log file. looks like it is the same error as before. but now there is a bit more information that shows it is caused by a nullpointexception from StrutsCreator.getType (line 93). The sample dwr.xml is: <!DOCTYPE dwr PUBLIC "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" "http://getahead.org/dwr/dwr30.dtd"> <dwr> <allow> <create creator="struts" javascript="PortfolioBuilderForm"> <param name="formBean" value="portfolioBuilderForm"/> <include method="formatAndCalculateTmpPercentage"/> <include method="getStrTmpTotalMix"/> <include method="getSubTotalOfTmpTargetMix"/> <include method="formatPercentage"/> </create> <create creator="struts" javascript="PortfolioRebalancerForm"> <param name="formBean" value="portfolioRebalancerForm"/> <include method="setAndFormatSwitchAmount"/> </create> </allow> ... </dwr> and the dwr config in web.xml: <servlet> <servlet-name>dwr-invoker</servlet-name> <servlet-class> org.directwebremoting.servlet.DwrServlet </servlet-class> <init-param> <param-name>debug</param-name> <param-value>true</param-value> </init-param> <init-param> <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> </init-param> <load-on-startup>99</load-on-startup> </servlet>
I see. I've improved the logging in StrutsCreator; download and run with the updated dwr.jar from here: http://directwebremoting.org/bamboo/browse/DWRTRUNK-ALL-382/artifact and tell us what you get in the exception stacktrace. Best regards Mike Yabing Chen wrote: Hi Mike, Thanks for the suggestion. However this error was caught when WebSphere was deploying the application. So I am not sure how to set the Websphere deployment into debug mode. Normally we debug the application only after the deployment is completed. pls advise if you have any idea on this. we are using eclipse as the IDE. Btw, an example of the full stack trace of the error is: 00000028 startup E org.directwebremoting.impl.DwrXmlConfigurator loadCreate Failed to add creator: type=struts, javascript=PortfolioBuilderForm java.lang.IllegalArgumentException at org.directwebremoting.struts.StrutsCreator.getType(StrutsCreator.java:100) at org.directwebremoting.extend.AbstractCreator.getJavascript(AbstractCreator.java:45) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:87) at org.directwebremoting.impl.DefaultCreatorManager.addCreator(DefaultCreatorManager.java:78) at org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXmlConfigurator.java:269) at org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXmlConfigurator.java:219) at org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXmlConfigurator.java:165) at org.directwebremoting.impl.StartupUtil.configureFromDefaultDwrXml(StartupUtil.java:612) at org.directwebremoting.impl.StartupUtil.configureContainerFully(StartupUtil.java:726) at org.directwebremoting.servlet.DwrServlet.configureContainer(DwrServlet.java:109) at org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) at com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWrapper.java:329) at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(ServletWrapperImpl.java:168) at com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCheck(ServletWrapper.java:1274) at com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(WebApp.java:586) at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally(WebApp.java:557) at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImpl.java:421) at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication(WebGroupImpl.java:88) at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(VirtualHostImpl.java:169) at com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContainer.java:748) at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWebContainer.java:633) at com.ibm.ws.webcontainer.component.WebContainerImpl.install(WebContainerImpl.java:422) at com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebContainerImpl.java:714) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:1134) at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:1369) at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:638) at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:730) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicationDynamically(ApplicationMgrImpl.java:1328) at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:2126) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:445) at com.ibm.ws.runtime.component.CompositionUnitImpl.start(CompositionUnitImpl.java:123) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(CompositionUnitMgrImpl.java:388) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500(CompositionUnitMgrImpl.java:116) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(CompositionUnitMgrImpl.java:663) at com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManagerImpl.java:5367) at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(ContextManagerImpl.java:5493) at com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityContext.java:255) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:677) at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompositionUnit(CompositionUnitMgrImpl.java:621) at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:1220) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:60) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) at sun.reflect.GeneratedMethodAccessor92.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:611) at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) at javax.management.modelmbean.RequiredModelMBean.invokeMethod(RequiredModelMBean.java:1085) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:966) at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:848) at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) at com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl.java:1334) at com.ibm.ws.security.util.AccessController.doPrivileged(AccessController.java:118) at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:1227) at com.ibm.ws.management.connector.AdminServiceDelegator.invoke(AdminServiceDelegator.java:181) at com.ibm.ws.management.connector.ipc.CallRouter.route(CallRouter.java:247) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.doWork(IPCConnectorInboundLink.java:353) at com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IPCConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1784) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217) at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) And the reason why we tried to upgrade to DWR v3 is because the WebSphere v8 gave a session error pop up when the application using DWR v2, which is related to the CSRF prevention in dwr configuration below. I searched the forum and understand the fix is in DWR v3. <param-name>crossDomainSessionSecurity</param-name> <param-value>true</param-value> Or probably you can suggest any other way to fix this pop up session error? Thanks
Hi cyb, It'd be great if you can aid us in debugging this. Download and set up the source code if you haven't got it already, and put a breakpoint at org.directwebremoting.struts.StrutsCreator.java:100 and then tell us what exception (variable "ex") is caught here? Best regards Mike Wilson cyb wrote: > We are upgrading DWR v2 to v3 for our application that is deployed in > websphere v8. before upgrading all struts creator are working > fine. after > upgrading the DWR jar file, when deploying the application we got the > "failed to add struts creator error" and all struts creator > are not able to > be created. The DWT test page also return a blank page, that means no > creator at all. > > For this upgrade, we didn't change anything else except the > dwr.jar upgrade. > > Please help to look at what went wrong. thanks. > > The dwr.xml is as below: > <!DOCTYPE dwr PUBLIC > "-//GetAhead Limited//DTD Direct Web Remoting 3.0//EN" > "http://getahead.org/dwr/dwr30.dtd"> > > <dwr> > <allow> > <convert converter="bean" > match="com.form.ViewClientProfileForm"/> > <create creator="struts" javascript="ViewClientProfileForm"> > > <include method="getTransactionAccessListAjax"/> > </create> > </allow> > </dwr> > > in web.xml, the dwr configure: > <servlet> > <servlet-name>dwr-invoker</servlet-name> > <servlet-class> > org.directwebremoting.servlet.DwrServlet > </servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>true</param-value> > </init-param> > <init-param> > > <param-name>crossDomainSessionSecurity</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>99</load-on-startup> > </servlet> > > the struts config: <servlet> > <servlet-name>action</servlet-name> > > <servlet-class>com.aviva.framework.struts.ExtendedActionServle > t</servlet-class> > <init-param> > <param-name>application</param-name> > <param-value>/firiumconfig/IplanResources</param-value> > </init-param> > <init-param> > <param-name>config</param-name> > <param-value> > /WEB-INF/struts-config-aa.xml, > > </param-value> > </init-param> > <init-param> > <param-name>debug</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>detail</param-name> > <param-value>3</param-value> > </init-param> > <init-param> > <param-name>validate</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>2</load-on-startup> > </servlet> > > The struts config: > <form-bean name="viewClientProfileForm" > type="com.form.ViewClientProfileForm"/> > > > the error: > org.directwebremoting.impl.DwrXmlConfigurator loadCreate > Failed to add > creator: type=struts, javascript=ViewClientProfileForm > java.lang.IllegalArgumentException > at > org.directwebremoting.struts.StrutsCreator.getType(StrutsCreat > or.java:100) > at > org.directwebremoting.extend.AbstractCreator.getJavascript(Abs > tractCreator.java:45) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:87) > at > org.directwebremoting.impl.DefaultCreatorManager.addCreator(De > faultCreatorManager.java:78) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadCreate(DwrXm > lConfigurator.java:269) > at > org.directwebremoting.impl.DwrXmlConfigurator.loadAllows(DwrXm > lConfigurator.java:219) > at > org.directwebremoting.impl.DwrXmlConfigurator.configure(DwrXml > Configurator.java:165) > at > org.directwebremoting.impl.StartupUtil.configureFromDefaultDwr > Xml(StartupUtil.java:612) > at > org.directwebremoting.impl.StartupUtil.configureContainerFully > (StartupUtil.java:726) > at > org.directwebremoting.servlet.DwrServlet.configureContainer(Dw > rServlet.java:109) > at > org.directwebremoting.servlet.DwrServlet.init(DwrServlet.java:68) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.init(ServletWra > pper.java:329) > at > com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init(Servle > tWrapperImpl.java:168) > at > com.ibm.ws.webcontainer.servlet.ServletWrapper.loadOnStartupCh > eck(ServletWrapper.java:1274) > at > com.ibm.ws.webcontainer.webapp.WebApp.doLoadOnStartupActions(W > ebApp.java:586) > at > com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFina > lly(WebApp.java:557) > at > com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize(WebAppImp > l.java:421) > at > com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication( > WebGroupImpl.java:88) > at > com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication(Virt > ualHostImpl.java:169) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApp(WSWebContaine > r.java:748) > at > com.ibm.ws.webcontainer.WSWebContainer.addWebApplication(WSWeb > Container.java:633) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.install(Web > ContainerImpl.java:422) > at > com.ibm.ws.webcontainer.component.WebContainerImpl.start(WebCo > ntainerImpl.java:714) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:1134) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeplo > yedObjectStart(DeployedApplicationImpl.java:1369) > at > com.ibm.ws.runtime.component.DeployedModuleImpl.start(Deployed > ModuleImpl.java:638) > at > com.ibm.ws.runtime.component.DeployedApplicationImpl.start(Dep > loyedApplicationImpl.java:967) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:730) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > onDynamically(ApplicationMgrImpl.java:1328) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.start(Applicat > ionMgrImpl.java:2126) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:445) > at > com.ibm.ws.runtime.component.CompositionUnitImpl.start(Composi > tionUnitImpl.java:123) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start(Comp > ositionUnitMgrImpl.java:388) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$500 (CompositionUnitMgrImpl.java:116) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl$1.run(Comp > ositionUnitMgrImpl.java:663) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAs(ContextManag > erImpl.java:5367) > at > com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem(Contex > tManagerImpl.java:5493) > at > com.ibm.ws.security.core.SecurityContext.runAsSystem(SecurityC > ontext.java:255) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:677) > at > com.ibm.ws.runtime.component.CompositionUnitMgrImpl.startCompo > sitionUnit(CompositionUnitMgrImpl.java:621) > at > com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplicati > on(ApplicationMgrImpl.java:1220) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccess > orImpl.java:60) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.Trampoline.invoke(MethodUtil.java:49) > at > sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMeth > odAccessorImpl.java:37) > at java.lang.reflect.Method.invoke(Method.java:611) > at sun.reflect.misc.MethodUtil.invoke(MethodUtil.java:256) > at > javax.management.modelmbean.RequiredModelMBean.invokeMethod(Re > quiredModelMBean.java:1085) > at > javax.management.modelmbean.RequiredModelMBean.invoke(Required > ModelMBean.java:966) > at > com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(D > efaultMBeanServerInterceptor.java:848) > at > com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:773) > at > com.ibm.ws.management.AdminServiceImpl$1.run(AdminServiceImpl. > java:1334) > at > com.ibm.ws.security.util.AccessController.doPrivileged(AccessC > ontroller.java:118) > at > com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl > .java:1227) > at > com.ibm.ws.management.connector.AdminServiceDelegator.invoke(A > dminServiceDelegator.java:181) > at > com.ibm.ws.management.connector.ipc.CallRouter.route(CallRoute > r.java:247) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink.do > Work(IPCConnectorInboundLink.java:353) > at > com.ibm.ws.management.connector.ipc.IPCConnectorInboundLink$IP CConnectorReadCallback.complete(IPCConnectorInboundLink.java:595) > at > com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompl etedCallback.complete(SSLReadServiceContext.java:1784) > at > com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCo > mpleted(AioReadCompletionListener.java:165) > at > com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAs > yncFuture.java:217) > at > com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(Asyn > cChannelFuture.java:161) > at > com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138) > at > com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204) > at > com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHa > ndler.java:775) > at > com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905) > at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648) > > -- > View this message in context: > http://dwr.2114559.n2.nabble.com/failed-to-add-struts-creator- > error-when-upgrading-from-DWR-v2-to-v3-tp7182483p7182483.html > Sent from the DWR - Users mailing list archive at Nabble.com. |
| Powered by Nabble | See how NAML generates this page |
