You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by Scott Carter <sc...@dotsconnect.com> on 2000/12/20 19:54:18 UTC

Xml Over Http Question

I'm using the Xerces XmlSerializer class to serialize XML documents to and
from an HttpServlet.  For some strange reason, this is screwing up my
server's(weblogic) session tracking mechanism and it is creating a new one
each time a user comes in.  Has anyone had this problem before or know how
to resolve it?


Also, I've also noticed that if I create a session and then try to parse a
document, in this order, I get an error from the parser about the stream
being closed before the whole document can be read.  If I do this in reverse
order, it seems to work most of the time, however, its a little quirky.  Has
anyone experienced this problem?

-----Original Message-----
From: Arnaud Le Hors [mailto:lehors@us.ibm.com]
Sent: Wednesday, December 06, 2000 8:52 PM
To: xerces-j-dev@xml.apache.org
Subject: Re: Non-validating parse causes presence of the DTD to be...


All right, I did it. I implemented this afternoon a new feature called:
http://apache.org/xml/features/nonvalidating/load-external-dtd

When this and validation is off the external subset isn't fetched at
all. It's checked in and will be part of the new release that Jeff is
wrapping up.
Enjoy! :-)
--
Arnaud  Le Hors - IBM Cupertino, XML Technology Group

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-dev-help@xml.apache.org


Re: Xml Over Http Question

Posted by Brent L Johnson <br...@bjohnson.net>.
I'm parsing and validating documents that are posted to an HTTP server, but
I'm not handling session information.  But, here is what I'm doing...

....
InputStream in = request.getInputStream();
InputSource source = new InputSource(in);
DOMParser parser = new DOMParser();
parser.setFeature("http://apache.org/xml/features/dom/defer-node-expansion",
false);
parser.setFeature("http://xml.org/sax/features/validation", true);
parser.setFeature("http://xml.org/sax/features/namespaces", true);
parser.setFeature("http://apache.org/xml/features/validation/schema", true);
parser.setErrorHandler(this);
parser.parse(source);
....

Don't know if this will help, but I gave it a shot ;)

- Brent

----- Original Message -----
From: "Scott Carter" <sc...@dotsconnect.com>
To: <xe...@xml.apache.org>
Sent: Wednesday, December 20, 2000 1:54 PM
Subject: Xml Over Http Question


>
> I'm using the Xerces XmlSerializer class to serialize XML documents to and
> from an HttpServlet.  For some strange reason, this is screwing up my
> server's(weblogic) session tracking mechanism and it is creating a new one
> each time a user comes in.  Has anyone had this problem before or know how
> to resolve it?
>
>
> Also, I've also noticed that if I create a session and then try to parse a
> document, in this order, I get an error from the parser about the stream
> being closed before the whole document can be read.  If I do this in
reverse
> order, it seems to work most of the time, however, its a little quirky.
Has
> anyone experienced this problem?
>
> -----Original Message-----
> From: Arnaud Le Hors [mailto:lehors@us.ibm.com]
> Sent: Wednesday, December 06, 2000 8:52 PM
> To: xerces-j-dev@xml.apache.org
> Subject: Re: Non-validating parse causes presence of the DTD to be...
>
>
> All right, I did it. I implemented this afternoon a new feature called:
> http://apache.org/xml/features/nonvalidating/load-external-dtd
>
> When this and validation is off the external subset isn't fetched at
> all. It's checked in and will be part of the new release that Jeff is
> wrapping up.
> Enjoy! :-)
> --
> Arnaud  Le Hors - IBM Cupertino, XML Technology Group
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-dev-help@xml.apache.org
>
>