Reputation: 26527
We are looking to communicate between a .net client and a java server using 'Protocol Buffers'.
Ideally would would like to use protobuf-net through WCF since all the rest of our communications to other services goes through the WCF stack.
I have a proof of concept .net WCF client talking to a .net WCF server using protobuf-net endpoint behaviour and that seems to work fine.
My question is how would we go about configuring the java server to send the proto-buf to our WCF client? I.e. Do we need to expose the java server to WCF as a SOAP services and send the proto-buf over that?
Upvotes: 2
Views: 819
Reputation: 1063338
In that scenario, I would strongly recommend using regular SOAP for the protocol, and exposing a byte[]
or Stream
(or whatever works) as the payload - and then handle the encoding in your application.
The serializer hooks in WCF mean that it is largely similar to a byte[]
payload (on a per-parameter/result basis), but I can't guarantee that it will be easily deconstructed outside of WCF.
Besides... if you describe it as a SOAP message that includes a BLOB, you are being truthful to SOAP.
Upvotes: 0
Reputation: 1502076
If your WCF client is using a protobuf-net endpoint, it's not using SOAP is it? I can't say I've used protobut-net personally, but I understood that it was an alternative to SOAP. Basically, have a look at the protocol it uses and implement the same protocol as a servlet. I would expect that to be reasonably simple, to be honest.
If it works and you can contribute the servlet as open source, I suspect you're not the only one who'd like to do this :)
Upvotes: 1