Quantcast

Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

Ricardo Zuasti
Hi, I'm trying to use Tiles 2.1 in a web app deployed in a Tomcat 6.0
environment.

 

Everything is working just fine, but I keep getting an exception during
tomcats startup:

 

java.lang.ClassNotFoundException:
org.apache.tiles.portlet.context.PortletTilesApplicationContextFactory

        at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1360)

        at
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
a:1206)

        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)

        at java.lang.Class.forName0(Native Method)

        at java.lang.Class.forName(Class.java:247)

        at org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:60)

        at
org.apache.tiles.context.ChainedTilesApplicationContextFactory.init(ChainedT
ilesApplicationContextFactory.java:98)

        at
org.apache.tiles.startup.BasicTilesInitializer.createAndInitializeTilesAppli
cationContextFactory(BasicTilesInitializer.java:89)

        at
org.apache.tiles.startup.BasicTilesInitializer.createTilesApplicationContext
(BasicTilesInitializer.java:69)

        at
org.apache.tiles.startup.BasicTilesInitializer.initialize(BasicTilesInitiali
zer.java:51)

        at
org.apache.tiles.web.startup.TilesListener.contextInitialized(TilesListener.
java:76)

        at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:
3843)

        at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4350)

        at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:7
91)

        at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)

        at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)

        at
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:626)

        at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:511)

        at
org.apache.catalina.startup.HostConfig.check(HostConfig.java:1229)

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39
)

        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl
.java:25)

        at java.lang.reflect.Method.invoke(Method.java:597)

        at
org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297
)

        at
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanSer
verInterceptor.java:836)

        at
com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)

        at
org.apache.catalina.manager.ManagerServlet.check(ManagerServlet.java:1465)

        at
org.apache.catalina.manager.ManagerServlet.deploy(ManagerServlet.java:821)

        at
org.apache.catalina.manager.ManagerServlet.doGet(ManagerServlet.java:349)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)

        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)

        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:290)

        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:206)

        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.ja
va:233)

        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.ja
va:175)

        at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase
.java:525)

        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128
)

        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102
)

        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java
:109)

        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)

        at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)

        at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http
11Protocol.java:583)

        at
org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)

        at java.lang.Thread.run(Thread.java:619)

 

I mean, everything works, but it's not nice to have an exception popping up
on every server startup on a production environment. I tried to add the
tiles-portlet JAR but it gets worse, if I do the application won't start and
a classnotfound is raised for javax/portlet/PortletRequest

 

Thanks!

Ricardo

 

Ricardo Zuasti

----------------------------------------------------------------------------
-----------------

Manentia Software

Obligado 1207 | C.P. 11300

Montevideo - Uruguay | (598) 99 333888 | (598) 2 7090695

http://www.manentiasoftware.com <http://www.manentiasoftware.com/>

----------------------------------------------------------------------------
-----------------

This e-mail was sent from Manentia Software (5IT SRL) and its content may be
private and confidential, therefore protected by law.

The reception of this by a wrong person does not imply the waivering of
those rights.

If you receive this e-mail by mistake, please delete it from your computer
and alert the sender.

In addition to that, we remind you that it is your responsability to check
the e-mail for virus.

We would appreciate for this e-mail to be handled accordingly.

 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

Antonio Petrelli-3
2010/1/25 Ricardo Zuasti <[hidden email]>:

> Hi, I'm trying to use Tiles 2.1 in a web app deployed in a Tomcat 6.0
> environment.
>
> Everything is working just fine, but I keep getting an exception during
> tomcats startup:
>
>
>
> java.lang.ClassNotFoundException:
> org.apache.tiles.portlet.context.PortletTilesApplicationContextFactory
>
>        at
> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
> a:1360)
>
>        at
> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
> a:1206)
>
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
>
>        at java.lang.Class.forName0(Native Method)
>
>        at java.lang.Class.forName(Class.java:247)
>
>        at org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:60)
>
>        at
> org.apache.tiles.context.ChainedTilesApplicationContextFactory.init(ChainedT
> ilesApplicationContextFactory.java:98)


Either you are using Tiles 2.0.x prior to 2.0.5, or you set DEBUG
level to Tiles classes logging.
Here is the related issue:
http://issues.apache.org/struts/browse/TILES-180

Antonio
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

Ricardo Zuasti
Antonio, thanks for your answer. I'm using Tiles 2.1.4, and the log was
indeed set to debug. I changed it to warn and now the exception isn't
visible. I'm still getting some warnings while starting tomcat:

WARN  org.apache.tiles.context.ChainedTilesApplicationContextFactory  -
Cannot find TilesContextFactory class
org.apache.tiles.portlet.context.PortletTilesApplicationContextFactory

It's not a big deal, but imho it should not be printed as a warning since
I'm purposely not using portlets.

Cheers,
Ricardo

-----Original Message-----
From: Antonio Petrelli [mailto:[hidden email]]
Sent: Monday, January 25, 2010 12:40 PM
To: [hidden email]
Subject: Re: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

2010/1/25 Ricardo Zuasti <[hidden email]>:

> Hi, I'm trying to use Tiles 2.1 in a web app deployed in a Tomcat 6.0
> environment.
>
> Everything is working just fine, but I keep getting an exception during
> tomcats startup:
>
>
>
> java.lang.ClassNotFoundException:
> org.apache.tiles.portlet.context.PortletTilesApplicationContextFactory
>
>        at
>
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav
> a:1360)
>
>        at
>
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.jav

> a:1206)
>
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
>
>        at java.lang.Class.forName0(Native Method)
>
>        at java.lang.Class.forName(Class.java:247)
>
>        at org.apache.tiles.reflect.ClassUtil.getClass(ClassUtil.java:60)
>
>        at
>
org.apache.tiles.context.ChainedTilesApplicationContextFactory.init(ChainedT
> ilesApplicationContextFactory.java:98)


Either you are using Tiles 2.0.x prior to 2.0.5, or you set DEBUG
level to Tiles classes logging.
Here is the related issue:
http://issues.apache.org/struts/browse/TILES-180

Antonio

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

Antonio Petrelli-3
In reply to this post by Antonio Petrelli-3
2010/1/25 Ricardo Zuasti <[hidden email]>:
> It's not a big deal, but imho it should not be printed as a warning since
> I'm purposely not using portlets.

I agree, I reopened TILES-180. I think that putting it into INFO level
and logging something like "Skipping portlet support" should be ok.

WDYT?

Thanks
Antonio
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

Ricardo Zuasti
Indeed, i agree 100%!

cheers
r.

-----Original Message-----
From: Antonio Petrelli [mailto:[hidden email]]
Sent: Monday, January 25, 2010 1:35 PM
To: [hidden email]
Subject: Re: Tiles 2.1, Struts 2 and Tomcat 6 - Portlet exception

2010/1/25 Ricardo Zuasti <[hidden email]>:
> It's not a big deal, but imho it should not be printed as a warning since
> I'm purposely not using portlets.

I agree, I reopened TILES-180. I think that putting it into INFO level
and logging something like "Skipping portlet support" should be ok.

WDYT?

Thanks
Antonio

Loading...