cxf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin" <>
Subject Re: Difference between XML and HTTP bindings
Date Thu, 25 Jan 2007 11:20:44 GMT

Just thinking aloud... So it appears there's no difference between these bindings, right ?
Would it make sense to differentiate between them like this :

* XMLBinding : used by Provider<Source> providers. Specifically GET requests are served
by returning Source (XMLs).

* HTTPBinding : providers are dealing with request InputStream, response OutputStream directly.

They implement an interface like handleRequest(InputData, ResponseData), where InputData/ResponseData
encapsulate the underlying engine's details so that such providers can run on Jetty/Tomcat/etc...

For ex, I need a provider which saves (binary) attachments and then can serve them through
simple GET requests issued from browsers, etc.. I can implement an XMLBinding (HTTPBinding)
provider, but this provider can not handle GET requests which would just return some non-XML
data. Well, it can return XOP multipart/related packages, but that is not something I need.

Any thoughts ?

Thanks, Sergey


What is the difference between XML and HTTP bindings from the perspective of the provider
and the client ?
I'm looking at the org.apache.cxf.systest.test, I can see RestSourcePayloadProvider and RestSourcePayloadProviderHTTPBinding
providers, both are absolutely identical except that the former one has one extra annotation, =

Corresponding test clients exercising these both providers are absoultely identical between
each other. Are there any subtle differences ? 

Thanks, Sergey

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message