You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Andrew123 <In...@ukr.net> on 2007/11/07 16:48:04 UTC

tomcat trouble

Hi all

I use tomcat 5.5.25 and xfire 1.2.6. Tomcat doesn't want to extract .jar
archives from /WEB-INF/lib directory. When I extract .jar and copy classes
to /WEB-INF/classes, all works fine. Can you help me with this trouble?
-- 
View this message in context: http://www.nabble.com/tomcat-trouble-tf4765489.html#a13629644
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Running a Script in a web application

Posted by Rocco Scappatura <Ro...@sttspa.it>.
Hello,

I'm tring to run a script inside a web application using JSR223Script class.

I get an error and I get to do so that JSR223Script is visible to Tomcat,
but I'm not experienced with Java.

Here the relative Tomcat log I get:

7-nov-2007 20.41.27 org.apache.catalina.core.ApplicationContext log INFO:
Marking servlet JSR223Script as unavailable
7-nov-2007 20.41.27 org.apache.catalina.core.StandardWrapperValve invoke
GRAVE: Allocate exception for servlet JSR223Script
java.lang.NoSuchMethodError:
javax.script.ScriptEngineManager.getEngineFactories()[Ljavax/script/ScriptEngineFactory;
        at
com.sun.script.http.ScriptServlet$EngineRepository.<init>(ScriptServlet.java:106)
        at com.sun.script.http.ScriptServlet.<init>(ScriptServlet.java:27)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at java.lang.Class.newInstance0(Class.java:355)
        at java.lang.Class.newInstance(Class.java:308)
        at
org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1089)
        at
org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:791)
        at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:127)
        at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
        at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
        at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:544)
        at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
        at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
        at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
        at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)
        at
org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
        at
org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
        at
org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
        at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
        at java.lang.Thread.run(Thread.java:619)


Could somebody help me?

rocsca


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat trouble

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Andrew123 [mailto:Intel123@ukr.net] 
> Subject: RE: tomcat trouble
> 
> Exception:
> org.springframework.beans.factory.BeanDefinitionStoreException: Error
> registering bean with name '' defined in class path resource 
> [services.xml]:
> Class that bean class [some.class] depends on not found; 
> nested exception is
> java.lang.NoClassDefFoundError:
> org/codehaus/xfire/service/invoker/ObjectInvoker
> 
> org.springframework.beans.factory.xml.DefaultXmlBeanDefinition
> Parser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionPars
> er.java:489)

I'm not familiar with xfire; does it have its own classloader?  Have you
by chance set CLASSPATH (you shouldn't)?

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: tomcat trouble

Posted by Konstantin Kolinko <kn...@gmail.com>.
When class cannot be loaded, it usually is a classloader issue.

Are you familiar with Tomcat classloaders hierarchy?
See here:
http://tomcat.apache.org/tomcat-5.5-doc/class-loader-howto.html

Note that although Webapp classloader is a child of all the others,
but it is being asked first, as if it were the parent to all of them.


Do you use single "all modules" xfire jar, or separate jars for
separate modules of it? Are all those jars in the same place?

Note that loading ObjectInvoker class fails, but
XFireConfigurableServlet etc. classes were successfully loaded.


Does your web-inf/lib contain any jars that are already available
through tomcat's common/lib or shared/lib? Those should be removed
from web-inf/lib.



2007/11/7, Andrew123 <In...@ukr.net>:
>
> I use jdk 1.6.0_02 and linux. Tomcat has permission to read the .jar files.
>
> Exception:
> org.springframework.beans.factory.BeanDefinitionStoreException: Error
> registering bean with name '' defined in class path resource [services.xml]:
> Class that bean class [some.class] depends on not found; nested exception is
> java.lang.NoClassDefFoundError:
> org/codehaus/xfire/service/invoker/ObjectInvoker
>
> org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:489)
>
> org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:392)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanDefinitionElement(XBeanXmlBeanDefinitionParser.java:835)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseChildExtensionBean(XBeanXmlBeanDefinitionParser.java:645)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseNestedPropertyViaIntrospection(XBeanXmlBeanDefinitionParser.java:555)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.tryParseNestedPropertyViaIntrospection(XBeanXmlBeanDefinitionParser.java:470)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.addNestedPropertyElements(XBeanXmlBeanDefinitionParser.java:436)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanFromExtensionElement(XBeanXmlBeanDefinitionParser.java:157)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanFromExtensionElement(XBeanXmlBeanDefinitionParser.java:176)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanDefinitions(XBeanXmlBeanDefinitionParser.java:807)
>
> org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.registerBeanDefinitions(DefaultXmlBeanDefinitionParser.java:191)
>
> org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionReader.registerBeanDefinitions(XBeanXmlBeanDefinitionReader.java:78)
>
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:223)
>
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:173)
>
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:148)
>
> org.codehaus.xfire.spring.XFireConfigLoader.getXFireApplicationContext(XFireConfigLoader.java:103)
>
> org.codehaus.xfire.spring.XFireConfigLoader.loadContext(XFireConfigLoader.java:41)
>
> org.codehaus.xfire.transport.http.XFireConfigurableServlet.loadConfig(XFireConfigurableServlet.java:86)
>
> org.codehaus.xfire.transport.http.XFireConfigurableServlet.createXFire(XFireConfigurableServlet.java:54)
>         org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:45)
>         javax.servlet.GenericServlet.init(GenericServlet.java:212)
>
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
>         org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
>         org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)
>
> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
>
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
>
> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
>
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
>         java.lang.Thread.run(Unknown Source)
>
> Some weeks ago all worked fine, so, I think, this is a problem of linux
> configuration.
>
> Caldarale, Charles R wrote:
> >
> >> From: Andrew123 [mailto:Intel123@ukr.net]
> >> Subject: tomcat trouble
> >>
> >> Tomcat doesn't want to extract .jar archives from
> >> /WEB-INF/lib directory.
> >
> > So the error message displayed is something like "don't want to"?
> > Perhaps you could be a bit more precise in the description of the
> > problem.  Also include pertinent information such as JRE/JDK version and
> > the OS you're running on.  Check the logs for anything that might be
> > related, and insure that Tomcat has permission to read the .jar files.
> >
> >  - Chuck
> >
> >
> > THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
> > MATERIAL and is thus for use only by the intended recipient. If you
> > received this in error, please contact the sender and delete the e-mail
> > and its attachments from all computers.
> >
>
> --
> View this message in context: http://www.nabble.com/tomcat-trouble-tf4765489.html#a13633699
> Sent from the Tomcat - User mailing list archive at Nabble.com.
>

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat trouble

Posted by Andrew123 <In...@ukr.net>.
I use jdk 1.6.0_02 and linux. Tomcat has permission to read the .jar files.

Exception:
org.springframework.beans.factory.BeanDefinitionStoreException: Error
registering bean with name '' defined in class path resource [services.xml]:
Class that bean class [some.class] depends on not found; nested exception is
java.lang.NoClassDefFoundError:
org/codehaus/xfire/service/invoker/ObjectInvoker

org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:489)

org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.parseBeanDefinitionElement(DefaultXmlBeanDefinitionParser.java:392)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanDefinitionElement(XBeanXmlBeanDefinitionParser.java:835)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseChildExtensionBean(XBeanXmlBeanDefinitionParser.java:645)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseNestedPropertyViaIntrospection(XBeanXmlBeanDefinitionParser.java:555)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.tryParseNestedPropertyViaIntrospection(XBeanXmlBeanDefinitionParser.java:470)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.addNestedPropertyElements(XBeanXmlBeanDefinitionParser.java:436)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanFromExtensionElement(XBeanXmlBeanDefinitionParser.java:157)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanFromExtensionElement(XBeanXmlBeanDefinitionParser.java:176)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionParser.parseBeanDefinitions(XBeanXmlBeanDefinitionParser.java:807)

org.springframework.beans.factory.xml.DefaultXmlBeanDefinitionParser.registerBeanDefinitions(DefaultXmlBeanDefinitionParser.java:191)

org.apache.xbean.spring.context.v1.XBeanXmlBeanDefinitionReader.registerBeanDefinitions(XBeanXmlBeanDefinitionReader.java:78)

org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:223)

org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:173)

org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:148)

org.codehaus.xfire.spring.XFireConfigLoader.getXFireApplicationContext(XFireConfigLoader.java:103)

org.codehaus.xfire.spring.XFireConfigLoader.loadContext(XFireConfigLoader.java:41)

org.codehaus.xfire.transport.http.XFireConfigurableServlet.loadConfig(XFireConfigurableServlet.java:86)

org.codehaus.xfire.transport.http.XFireConfigurableServlet.createXFire(XFireConfigurableServlet.java:54)
	org.codehaus.xfire.transport.http.XFireServlet.init(XFireServlet.java:45)
	javax.servlet.GenericServlet.init(GenericServlet.java:212)

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
	org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
	org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)

org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)

org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)

org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)

org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
	java.lang.Thread.run(Unknown Source)

Some weeks ago all worked fine, so, I think, this is a problem of linux
configuration.  

Caldarale, Charles R wrote:
> 
>> From: Andrew123 [mailto:Intel123@ukr.net] 
>> Subject: tomcat trouble
>> 
>> Tomcat doesn't want to extract .jar archives from
>> /WEB-INF/lib directory.
> 
> So the error message displayed is something like "don't want to"?
> Perhaps you could be a bit more precise in the description of the
> problem.  Also include pertinent information such as JRE/JDK version and
> the OS you're running on.  Check the logs for anything that might be
> related, and insure that Tomcat has permission to read the .jar files.
> 
>  - Chuck
> 
> 
> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
> MATERIAL and is thus for use only by the intended recipient. If you
> received this in error, please contact the sender and delete the e-mail
> and its attachments from all computers.
> 
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/tomcat-trouble-tf4765489.html#a13633699
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: tomcat trouble

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Andrew123 [mailto:Intel123@ukr.net] 
> Subject: tomcat trouble
> 
> Tomcat doesn't want to extract .jar archives from
> /WEB-INF/lib directory.

So the error message displayed is something like "don't want to"?
Perhaps you could be a bit more precise in the description of the
problem.  Also include pertinent information such as JRE/JDK version and
the OS you're running on.  Check the logs for anything that might be
related, and insure that Tomcat has permission to read the .jar files.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY
MATERIAL and is thus for use only by the intended recipient. If you
received this in error, please contact the sender and delete the e-mail
and its attachments from all computers.

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org