tiles-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Venu Gopalan <venugopala...@yahoo.com.INVALID>
Subject Re: Null pointer in Struts1/Tiles 2 on weblogic server startup
Date Mon, 27 Mar 2017 13:15:05 GMT
Thank you very much Torsten for your valuble time. I tried removing the struts-tiles-1.4.0-SNAPSHOT.jar,
but it was giving hell lot of errors. struts-tiles2-1.4.0-SNAPSHOT.jar. is just 29 KB. I
will try remove tiles-portlet and tiles-servlet jars. Being said that you were unable to read
the stack trace, below is the same again. Trying to debug more and will let you know. If you
are able to read the entire stack trace here and make out some thing pls let me know.

####<Mar 24, 2017 3:40:41 PM EDT> <Warning> <org.apache.struts.config.impl.ModuleConfigImpl>
<PC0033670> <AdminServer> <[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default
(self-tuning)'> <<anonymous>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441158> <BEA-000000> <Overriding MessageResources bundle of key org.apache.struts.action.MESSAGE> ####<Mar
24, 2017 3:40:41 PM EDT> <Warning> <org.apache.struts.config.impl.ModuleConfigImpl>
<PC0033670> <AdminServer> <[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default
(self-tuning)'> <<anonymous>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441219> <BEA-000000> <Overriding MessageResources bundle of key org.apache.struts.action.MESSAGE> ####<Mar
24, 2017 3:40:41 PM EDT> <Warning> <org.apache.struts.util.PropertyMessageResources>
<PC0033670> <AdminServer> <[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default
(self-tuning)'> <<anonymous>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441250> <BEA-000000> <  Resource org/apache/struts/action/ActionResources_en_US.properties
Not Found.> ####<Mar 24, 2017 3:40:41 PM EDT> <Warning> <org.apache.struts.util.PropertyMessageResources>
<PC0033670> <AdminServer> <[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default
(self-tuning)'> <<anonymous>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441251> <BEA-000000> <  Resource org/apache/struts/action/ActionResources_en.properties
Not Found.> ####<Mar 24, 2017 3:40:41 PM EDT> <Error> <ServletContext-/cms3.9_Sh>
<PC0033670> <AdminServer> <[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default
(self-tuning)'> <<anonymous>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441252> <BEA-000000> <action: nulljava.lang.NullPointerException at
java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:247) at org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:67)
at org.apache.tiles.reflect.ClassUtil.instantiate(ClassUtil.java:103) at org.apache.tiles.reflect.ClassUtil.instantiate(ClassUtil.java:82)
at org.apache.tiles.factory.TilesContainerFactory.createFactory(TilesContainerFactory.java:541)
at org.apache.tiles.factory.TilesContainerFactory.getFactory(TilesContainerFactory.java:203)
at org.apache.tiles.factory.TilesContainerFactory.getFactory(TilesContainerFactory.java:178)
at org.apache.struts.tiles2.TilesPlugin.init(TilesPlugin.java:241) at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:891)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:359) at javax.servlet.GenericServlet.init(GenericServlet.java:241)
at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120) at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539) at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1986)
at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1960)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1879)
at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3161) at
weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1511) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:483)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200) at
weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27) at
weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:43)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:531)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)> ####<Mar
24, 2017 3:40:41 PM EDT> <Error> <HTTP> <PC0033670> <AdminServer>
<[STANDBY] ExecuteThread: '5' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS
Kernel>> <> <2d77fd9e20723ca4:-76df48df:15b01d3bc22:-8000-000000000000003b>
<1490384441268> <BEA-101216> <Servlet: "action" failed to preload on startup
in Web application: "cms3.9_Sh".javax.servlet.UnavailableException at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:900)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:359) at javax.servlet.GenericServlet.init(GenericServlet.java:241)
at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120) at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539) at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1986)
at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1960)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1879)
at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3161) at
weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1511) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:483)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200) at
weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27) at
weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:43)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:531)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)Caused
By: java.lang.NullPointerException at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:247)
at org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:67) at org.apache.tiles.reflect.ClassUtil.instantiate(ClassUtil.java:103)
at org.apache.tiles.reflect.ClassUtil.instantiate(ClassUtil.java:82) at org.apache.tiles.factory.TilesContainerFactory.createFactory(TilesContainerFactory.java:541)
at org.apache.tiles.factory.TilesContainerFactory.getFactory(TilesContainerFactory.java:203)
at org.apache.tiles.factory.TilesContainerFactory.getFactory(TilesContainerFactory.java:178)
at org.apache.struts.tiles2.TilesPlugin.init(TilesPlugin.java:241) at org.apache.struts.action.ActionServlet.initModulePlugIns(ActionServlet.java:891)
at org.apache.struts.action.ActionServlet.init(ActionServlet.java:359) at javax.servlet.GenericServlet.init(GenericServlet.java:241)
at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120) at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539) at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1986)
at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1960)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1879)
at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3161) at
weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1511) at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:483)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200) at
weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52) at
weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119) at
weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27) at
weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205) at weblogic.application.internal.SingleModuleDeployment.activate(SingleModuleDeployment.java:43)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:531)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

Regards,Venu

    On Monday, 27 March 2017 8:54 AM, Torsten Krah <krah.tm@gmail.com> wrote:
 

 Am Montag, den 27.03.2017, 12:22 +0000 schrieb Venu Gopalan:
>  Finally I was able to built a sample program which I converted from
> Struts1/Tiles1 to Struts1/Tiles2. So I started to implement the same
> to a govt project where I need to upgrade spring and hibernate to 4.x
> Now after all the known changes, when I start the server, I get a
> error as below:I do have following jars in the lib and
> classpath:tiles-core-2.2.1.jar
> tiles-api-2.2.1.jar
> tiles-api-2.2.1.jar
> tiles-jsp-2.2.1.jar
> tiles-portlet-2.2.1.jar
> tiles-servlet-2.2.1.jar
> tiles-template-2.2.1.jar
> 
> struts-core-1.4.0-SNAPSHOT.jar
> struts-extras-1.4.0-SNAPSHOT.jar
> struts-tiles-1.4.0-SNAPSHOT.jar
> struts-tiles2-1.4.0-SNAPSHOT.jar
> 
> Am I missing any configuration or any other thing? Any help will be
> highly appreciated.

Had only a short look. Your stacktraces are hard to read ... btw.

It looks to me that the NPE is happen in native code - in don't remember
to have seen such thing lately - i would expect NoClassDefFound or
ClassNotFoundException of something from Class.forName(..) - but a NPE -
strange.
While writing that and having that said - imho the name it wants to load
is "null" ... could that be? But in that case a debugger would have
revealed that and you already tried to use a debugger ... right?

So just unweal your stacktrace up to the frame where the code does fetch
its classname via reflection and have a look at:

1. either is it the correct name (of cause null is not the correct one)
- so why it chooses this one?
2. If you fixed that - make sure that class is actually there.

And if you're using Tiles 2 - you can remove
struts-tiles-1.4.0-SNAPSHOT.jar.

Next - are you running in a portlet or servlet environment? Just remove
the 

tiles-portlet or tiles-servlet jar - whichever you don't need.

And the next thing *i would* try is to just hit a debugger from line:

org.apache.tiles.factory.TilesContainerFactory.getFactory(TilesContainerFactory.java:203)

over
org.apache.tiles.reflect.ClassUtil.instantiate(ClassUtil.java:82) 
to
org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:67)

which class it wants to instantiate to get a clue what's going wrong
here - like said above, step up in the frame until you get to the point
where it chooses the classname to be loaded - there is some flaw or some
expectation made there which does not fit your environment.

kind regards

Torsten



   
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message