On 07/09/2012 10:37 AM, Andrei Shakirin wrote:
Hi Glen,
OK, the first question was not precise formulated: I mean is there any other ways
excepting Dispatch<> to send stream oriented message from client side?
Oh, you had written you wanted to avoid the DOM model, not the Dispatch
interface. Dispatch<> is the defined JAX-WS mechanism for when you're
doing streaming, I don't know of anything else in JAX-WS. I don't
understand your reservations about the Dispatch interface (performance
maybe?), it seems to be a pretty empty wrapper of the standard Java
streaming solutions.
Dispatch provides StreamSource, DOMSource, SAXSource, and I believe
JAXBSource. Which Java streaming mechanism are you looking for? Then we
can find out if there's a non-Dispatch way of using it. I won't know of
any (besides lower-level coding like Apache HTTP Components), but
hopefully others might.
In you sample you use Dispatch<> client as well, but interesting for me is the
following:
Is it possible to configure stream oriented client using spring/blueprint
jaxws:client?
I don't know--we have to see what you're looking for in the standard
Java case, once that's ascertained and shown doable, the next question
is how to do the same within OSGi.
Glen
On my opinion, it is not very exotic use case.
Regards,
Andrei.
-----Original Message-----
From: Glen Mazza [mailto:[email protected]]
Sent: 09 July 2012 16:07
To: [email protected]
Subject: Re: Using Dispatch with spring/blueprint configuration
On 07/09/2012 03:22 AM, Andrei Shakirin wrote:
Hi,
Just two short questions regarding CXf streaming & spring/blueprint
configuration on client side:
1) Is using Dispatch<Source> only the way to achieve streaming on the
client side? I would like to avoid DOM model on the client side.
No, search for doubleItWorksForPrimeNumbers() on this page:
http://www.jroller.com/gmazza/entry/junit_web_service_testing, you can use
DOM/SAX/StreamSource.
2) Is it possible somehow to configure Dispatch using spring/blueprint? I
have found this Jira entry https://issues.apache.org/jira/browse/CXF-980, but
it seems to be postponed for the future.
Using standard Spring dependency injection, you can of course convert just
about any Java code to XML configuration. Apparently nobody wanted to put in
the effort to create something OOTB (CXF-980 has been ignored since 2007); that
might be because the amount of customizations necessary would make a generic
object impractical, or Apache Camel already provides those bells and whistles,
you might wish to look at Camel's CXF component for more ideas, this blog entry
is rather out of
date: http://www.jroller.com/gmazza/entry/camel_jms_and_soap but can also give
you a general idea of functionality available with Camel.
HTH,
Glen
In my use case, clients send a large untyped XML messages, so I would like to
use stream-oriented clients. From other side, clients use a lot of features and
interceptors easily configured via spring/blueprint (sure, it is also possible
to do it programmatically, but not so easy and obvious).
Could anybody suggest an elegant solution for this situation?
Regards,
Andrei.
--
Glen Mazza
Talend Community Coders
coders.talend.com
blog: www.jroller.com/gmazza
--
Glen Mazza
Talend Community Coders
coders.talend.com
blog: www.jroller.com/gmazza