I'm attempting to write and test out a JellyServlet (similar to
VelocityServlet), but I'm having trouble when the XML parser tries to
locate/read the .jelly file. I'm using the jars that are specified in the
jelly project.xml file (I think xerces-2.0.2 and xml-apis... I put those in
my WEB-INF/lib/, and I assume they will take precedence over the catalina
jars)

It looks like xerces is trying to use ftp to get the file (see stack trace
below)... here is the relevant code in my servlet:

ServletOutputStream output = response.getOutputStream();
JellyContext context = new JellyContext();
XMLOutput xmlOutput = XMLOutput.createXMLOutput(output);
context.runScript( "sample.jelly", xmlOutput );

I also tried other variations, like
context.runScript( "file://C:/../sample.jelly", xmlOutput );

It may be something simple, I don't have a lot of experience with xerces, or
servlets for that matter, but I'm stumped.

thanks in advance,
Otto

java.net.UnknownHostException: C
        at java.net.InetAddress.getAllByName0(InetAddress.java:571)
        at java.net.InetAddress.getAllByName0(InetAddress.java:540)
        at java.net.InetAddress.getByName(InetAddress.java:449)
        at java.net.Socket.(Socket.java:100)
        at sun.net.NetworkClient.doConnect(NetworkClient.java:50)
        at sun.net.NetworkClient.openServer(NetworkClient.java:38)
        at sun.net.ftp.FtpClient.openServer(FtpClient.java:267)
        at sun.net.ftp.FtpClient.(FtpClient.java:381)
        at
sun.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:77)
        at
sun.net.www.protocol.ftp.FtpURLConnection.getInputStream(FtpURLConnection.ja
va:96)
        at java.net.URL.openStream(URL.java:798)
        at
org.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityManager.java:79
6)
        at
org.apache.xerces.impl.XMLEntityManager.startDocumentEntity(XMLEntityManager
.java:741)
        at
org.apache.xerces.impl.XMLDocumentScannerImpl.setInputSource(XMLDocumentScan
nerImpl.java:260)
        at
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:498)
        at
org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:580)
        at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
        at
org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:110
8)
        at org.apache.commons.jelly.parser.XMLParser.parse(XMLParser.java:328)
        at
org.apache.commons.jelly.JellyContext.compileScript(JellyContext.java:447)
        at org.apache.commons.jelly.JellyContext.runScript(JellyContext.java:485)
        at JellyServlet.merge(JellyServlet.java:322)
        at JellyServlet.doRequest(JellyServlet.java:270)
        at JellyServlet.doGet(JellyServlet.java:217)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to