Hi

On 27/10/11 13:02, Jacob Zwiers wrote:
That's great, Daniel... I'll try the snapshot.

Just so I know all my options, is there a configuration hook to instruct the 
JAX-RS services to use a SAX or DOM parser instead of StAX?

DOM can be used only if you specify Document instead of AnalyzeResults. Otherwise, specifying a (jaxp) Source parameter and setting a "source-preferred-format" contextual property (via jaxrs:properties) to "sax" will do it - this is something I copied from Dan enhancing the relevant CXF databinding code

Cheers, Sergey

jz

-----Original Message-----
From: Daniel Kulp [mailto:[email protected]]
Sent: Wednesday, October 26, 2011 5:18 PM
To: [email protected]
Cc: Jacob Zwiers
Subject: Re: Changing Parser Type on for JAX-RS Services


I cannot really help you with the Oracle part of this, but after reading the 
stack trace, I updated StaxUtils to trap the unsupported properties and
continue.   Thus, tomorrows snapshots should start working for this.

That said, getting it to use woodstox is definitely a good thing to keep
pursuing.   Woodstox is pretty much the best stax parser out there.


Dan



On Wednesday, October 26, 2011 2:51:05 PM Jacob Zwiers wrote:
I've deployed a JAX-RS method defined as follows:

    @POST
    @Consumes( "text/xml")
    @Path( "{order_id}/" + ANALYSE_PARAM )
    public void reportResult( @PathParam( "order_id") int _orderId,
AnalyseResults _analyseResults ) { // NOTE: AnalyseResults is a JAXB object
    }

When using CXF 2.4.0 with Weblogic 9.2.3 (Java 1.5), I get all sorts
of grief because of the StAX parser.

The details are in an Oracle Forums[1] post.

While I wait for them to tell me I can't change the StAX parser in
WebLogic...

... is there a way to instruct the JAX-RS to use a different type of
parsing (eg. SAX rather than StAX ... I'd even take DOM at this point)?

Thanks...
jz

[1] -
https://forums.oracle.com/forums/message.jspa?messageID=9953045#995304
5
--
Daniel Kulp
[email protected]
http://dankulp.com/blog
Talend - http://www.talend.com

Reply via email to