paperclips-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Paperclips-discuss] Problem with FileURLConnection


From: Andy Madigan
Subject: Re: [Paperclips-discuss] Problem with FileURLConnection
Date: Wed, 10 Nov 2004 19:27:54 -0800 (PST)

The commands you sent failed, it seems my system didn't expand *.jar,
and I'd really rather not try throwing all the jar paths in. I know it
didn't get the right jar files b/c it says it can't find gnu getopt.
I'm sure this problem wouldn't happen if the VM was forced to use the
provided classes. Since I was planning on making some changes to
paperclips for my purposes anyway, and since I don't need (or want)
access to anything other than regular files, I'm just going to remove
the use of URLConnections as much as possible.
--- Nic Ferrier <address@hidden> wrote:

> Andy Madigan <address@hidden> writes:
> 
> > I managed to run into a problem I had before on Sun's VM, but this
> time
> > it's sablevm. I ran make, which gave me a gnupaperclips.jar. I
> added
> > this jar to the classpath and started with java gnupaperclips
> > --config=server.xml. When I checked the server I got a 404 on the
> root
> > directory (same problem as before). But this time I also got
> exception
> > stack traces on the console. The stack trace is this:
> >
> > java.lang.ClassCastException
> >    at gnu.paperclips.Service.getResource (Service.java:703)
> >    at gnu.paperclips.servlets.WWW.getLastModified (WWW.java:208)
> >    at javax.servlet.http.HttpServlet.testConditional
> > (HttpServlet.java:367)
> >    at javax.servlet.http.HttpServlet.service (HttpServlet.java:290)
> >    at javax.servlet.http.HttpServlet.service (HttpServlet.java:345)
> >    at gnu.paperclips.RequestableServlet.service
> > (RequestableServlet.java:144)
> >    at gnu.paperclips.Requestable.dispatch (Requestable.java:256)
> >    at gnu.paperclips.Dispatcher$DFilterChain.doFilter
> > (Dispatcher.java:320)
> >    at gnu.paperclips.filters.WebLog.doFilter (WebLog.java:69)
> >    at gnu.paperclips.RequestFilter.filter (RequestFilter.java:203)
> >    at gnu.paperclips.Dispatcher$DFilterChain.doFilter
> > (Dispatcher.java:325)
> >    at gnu.paperclips.Dispatcher.dispatch (Dispatcher.java:219)
> >    at gnu.paperclips.http.HTTPResponse.doRequest
> > (HTTPResponse.java:205)
> >    at gnu.paperclips.http.HTTPRequest.doRequest
> (HTTPRequest.java:192)
> >    at gnu.paperclips.http.HTTPConnection.handle
> > (HTTPConnection.java:247)
> >    at gnu.socketserver.Server.serviceSocket (Server.java:421)
> >    at gnu.socketserver.Server.run (Server.java:307)
> >    at java.lang.Thread.run (Thread.java:704)
> >    at java.lang.VMThread.callRun (VMThread.java:120)
> >    at java.lang.Thread.callRun (Thread.java:390)
> >    at java.lang.VirtualMachine.runThread (VirtualMachine.java:121)
> >
> > As  you can see the trace ends (or begins) at Service.java line
> 703,
> > this line is a cast from a URLConnection to a
> > gnu.java.net.protocol.file.FileURLConnection. I'm not sure why it
> fails
> > on sablevm (which uses the GNU Classpath), but this seems like a
> bad
> > cast since some platforms won't use that specific class for
> > FileURLConnections. What I really can't figure out is that this
> error
> > didn't occur when I used the jar that was already in CVS. 
> 
> Paperclips does some monkeying around to ensure it gets it's own
> URLConnection classes.
> 
> 
> Can you try something for me?
> 
> Try using the 'real' boot class:
> 
>   java -cp .... gnu.paperclips.paperclips --config=...
> 
> the classpath can be constructed with makepath which is in the root
> of
> the paperclips module. I do:
> 
>   java -cp `makepath phome/lib/*.jar`:phome/paperclips.jar ...
> 
> where 'phome' is the paperclips CVS module root dir.
> 
> 
> If you let me know about that then I will look at the problem.
> 
> -- 
> Nic Ferrier
> http://www.tapsellferrier.co.uk
> 
> 
> _______________________________________________
> Paperclips-discuss mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/paperclips-discuss
> 


=====





reply via email to

[Prev in Thread] Current Thread [Next in Thread]