You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by Bruce Altner <ba...@hq.nasa.gov> on 2001/11/21 14:23:03 UTC

upload service

I am trying to get the upload service to work, using the defaults in 
TurbineResources.properties, including
setting services.UploadService.automatic to true. I think I've followed the 
how-to carefully but I get this nasty StackTrace indicatinf a class can't 
be found. What am I doing wrong?

Interestingly, the error I get depends which file I try to 
upload...sometimes it's the one shown and at other times it just says
Stack Trace: java.lang.NoClassDefFoundError: javax/activation/DataSource, 
not Horrible Exception. Why?
Thanks,
Bruce


(I apologize for the long StackTrace but I don't know which line would 
offer the information you'd need to help.)

Horrible Exception: java.lang.NoClassDefFoundError: javax/activation/DataSource
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:486)
         at 
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111)
         at java.net.URLClassLoader.defineClass(URLClassLoader.java:248)
         at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
         at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at 
org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.java:664)
         at 
org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:1077)
         at 
org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.java:976)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313)
         at 
org.apache.turbine.services.upload.TurbineUploadService.createItem(TurbineUploadService.java:298)
         at 
org.apache.turbine.services.upload.TurbineUploadService.parseRequest(TurbineUploadService.java:190)
         at 
org.apache.turbine.services.upload.TurbineUpload.parseRequest(TurbineUpload.java:178)
         at 
org.apache.turbine.util.parser.DefaultParameterParser.setRequest(DefaultParameterParser.java:189)
         at 
org.apache.turbine.services.rundata.DefaultTurbineRunData.getParameters(DefaultTurbineRunData.java:502)
         at org.apache.turbine.Turbine.doGet(Turbine.java:278)
         at org.apache.turbine.Turbine.doPost(Turbine.java:537)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at 
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
         at 
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at 
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:255)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:225)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2252)
         at 
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:446)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:564)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:163)
         at 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:566)
         at 
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
         at 
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
         at 
org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:875)
         at 
org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:952)
         at java.lang.Thread.run(Thread.java:484)
_________________________________________________________________
"It's a magical world, Hobbes, ol' buddy...let's go exploring!" ---Calvin

Phone: 202-651-8553
Pager Email:8273479@skytel.com




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: upload service

Posted by Daniel Rall <dl...@finemaltcoding.com>.
Bruce Altner <ba...@hq.nasa.gov> writes:

> Hmmmmm...I was premature in my celebration. I got the 2.2b1
> distribution and built the turbine jar file, installed it, and
> recompiled everything.
> Unfortunately I still get zero length files transferred over.

What version of the source is that JAR built from (I don't see a
corresponding tag in CVS)?  You could try building a fresh JAR from
CVS HEAD.  Failing that, I'd try sprinkling debugging breadcrumbs
through the code of whatever API you're using to access the uploaded
files (i.e. DefaultParameterParser or TurbineUploadService), or
running in the debugger to see what's happening.

> Do I need an even later version? Do I need to reinstall the whole tdk
> rather than just turbine-2.1.jar?

I think that replacing the JAR should be sufficient for this case.

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: upload service

Posted by Bruce Altner <ba...@hq.nasa.gov>.
Hmmmmm...I was premature in my celebration. I got the 2.2b1 distribution 
and built the turbine jar file, installed it, and recompiled everything.
Unfortunately I still get zero length files transferred over.

Do I need an even later version? Do I need to reinstall the whole tdk 
rather than just turbine-2.1.jar?

Thanks,
Bruce


At 06:07 AM 11/22/2001 -0500, you wrote:
>Yes!!!!!!!!!!!!!
>Jason was right about the jar and you are right about the zero length 
>files. I was going nuts with this one...everything seemed to be
>set up as it was supposed to be and even flushing and closing the stream 
>didn't help. I will try the latest release to see what this does.
>
>Thank you, Daniel.
>
>Bruce
>
>At 01:38 PM 11/21/2001 -0800, you wrote:
>>As Jason mentions, you may be missing activation.jar (or classes it
>>references).  Also (unrelated), if you're using the UploadService from
>>2.1 release, you're likely going to need updates to the service from
>>CVS to properly close the output stream of the file written to disk
>>(otherwise you may get zero length files).
>>
>>- Daniel
>>
>>
>>--
>>To unsubscribe, 
>>e-mail:   <ma...@jakarta.apache.org>
>>For additional commands, e-mail: 
>><ma...@jakarta.apache.org>
>
>_________________________________________________________________
>"It's a magical world, Hobbes, ol' buddy...let's go exploring!" ---Calvin
>
>Phone: 202-651-8553
>Pager Email:8273479@skytel.com
>
>
>
>
>--
>To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>
>

_________________________________________________________________
"It's a magical world, Hobbes, ol' buddy...let's go exploring!" ---Calvin

Phone: 202-651-8553
Pager Email:8273479@skytel.com




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: upload service

Posted by Bruce Altner <ba...@hq.nasa.gov>.
Yes!!!!!!!!!!!!!
Jason was right about the jar and you are right about the zero length 
files. I was going nuts with this one...everything seemed to be
set up as it was supposed to be and even flushing and closing the stream 
didn't help. I will try the latest release to see what this does.

Thank you, Daniel.

Bruce

At 01:38 PM 11/21/2001 -0800, you wrote:
>As Jason mentions, you may be missing activation.jar (or classes it
>references).  Also (unrelated), if you're using the UploadService from
>2.1 release, you're likely going to need updates to the service from
>CVS to properly close the output stream of the file written to disk
>(otherwise you may get zero length files).
>
>- Daniel
>
>
>--
>To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
>For additional commands, e-mail: <ma...@jakarta.apache.org>

_________________________________________________________________
"It's a magical world, Hobbes, ol' buddy...let's go exploring!" ---Calvin

Phone: 202-651-8553
Pager Email:8273479@skytel.com




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: upload service

Posted by Daniel Rall <dl...@finemaltcoding.com>.
As Jason mentions, you may be missing activation.jar (or classes it
references).  Also (unrelated), if you're using the UploadService from
2.1 release, you're likely going to need updates to the service from
CVS to properly close the output stream of the file written to disk
(otherwise you may get zero length files).

- Daniel


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: upload service

Posted by Jason van Zyl <jv...@zenplex.com>.
On 11/21/01 8:23 AM, "Bruce Altner" <ba...@hq.nasa.gov> wrote:

> I am trying to get the upload service to work, using the defaults in
> TurbineResources.properties, including
> setting services.UploadService.automatic to true. I think I've followed the
> how-to carefully but I get this nasty StackTrace indicatinf a class can't
> be found. What am I doing wrong?
> 
> Interestingly, the error I get depends which file I try to
> upload...sometimes it's the one shown and at other times it just says
> Stack Trace: java.lang.NoClassDefFoundError: javax/activation/DataSource,
> not Horrible Exception. Why?

You either removed the Java Activation Framework jar from your WEB-INF/lib
directory if you're using the TDK or you don't have it in your classpath.

> Thanks,
> Bruce
> 
> 
> (I apologize for the long StackTrace but I don't know which line would
> offer the information you'd need to help.)
> 
> Horrible Exception: java.lang.NoClassDefFoundError:
> javax/activation/DataSource
>        at java.lang.ClassLoader.defineClass0(Native Method)
>        at java.lang.ClassLoader.defineClass(ClassLoader.java:486)
>        at 
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111)
>        at java.net.URLClassLoader.defineClass(URLClassLoader.java:248)
>        at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
>        at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
>        at java.security.AccessController.doPrivileged(Native Method)
>        at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>        at 
> org.apache.catalina.loader.StandardClassLoader.findClass(StandardClassLoader.j
> ava:664)
>        at 
> org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.j
> ava:1077)
>        at 
> org.apache.catalina.loader.StandardClassLoader.loadClass(StandardClassLoader.j
> ava:976)
>        at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313)
>        at 
> org.apache.turbine.services.upload.TurbineUploadService.createItem(TurbineUplo
> adService.java:298)
>        at 
> org.apache.turbine.services.upload.TurbineUploadService.parseRequest(TurbineUp
> loadService.java:190)
>        at 
> org.apache.turbine.services.upload.TurbineUpload.parseRequest(TurbineUpload.ja
> va:178)
>        at 
> org.apache.turbine.util.parser.DefaultParameterParser.setRequest(DefaultParame
> terParser.java:189)
>        at 
> org.apache.turbine.services.rundata.DefaultTurbineRunData.getParameters(Defaul
> tTurbineRunData.java:502)
>        at org.apache.turbine.Turbine.doGet(Turbine.java:278)
>        at org.apache.turbine.Turbine.doPost(Turbine.java:537)
>        at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
>        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
>        at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFi
> lterChain.java:247)
>        at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChai
> n.java:193)
>        at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java
> :255)
>        at 
> 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66> )
>        at 
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>        at 
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>        at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java
> :225)
>        at 
> 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66> )
>        at 
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>        at 
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>        at 
> org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2252)
>        at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
>        at 
> 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66> )
>        at 
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:446)
>        at 
> 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
64> )
>        at 
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>        at 
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>        at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:1
> 63)
>        at 
> 
org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java:5
66> )
>        at 
> org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:472)
>        at 
> org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:943)
>        at 
> org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java:87
> 5)
>        at 
> org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java:952)
>        at java.lang.Thread.run(Thread.java:484)
> _________________________________________________________________
> "It's a magical world, Hobbes, ol' buddy...let's go exploring!" ---Calvin
> 
> Phone: 202-651-8553
> Pager Email:8273479@skytel.com
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>

-- 

jvz.

Jason van Zyl

http://tambora.zenplex.org
http://jakarta.apache.org/turbine
http://jakarta.apache.org/velocity
http://jakarta.apache.org/alexandria
http://jakarta.apache.org/commons



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>