-
1. Re: Can I receive binary messages via REST?
clebert.suconic May 9, 2012 9:29 PM (in response to gkhrapunovich)1 of 1 people found this helpfulFor the messaging world, Messages are just byte arrays.
Java Object Messages are utilities in top of messaging. Lot of people actually tried to suggest XML and other formats to the JMS committe..
Having said that.. if you use ObjectMessages, you are bound to java, and you will need Java to deserialize-it. I would recommend you doing your own serialization to any format you want. like JSON and have it send it.
I don't think anyone ever wrote a deserialization from java to C#. It would be possible though.. but that's a hard route to follow. I wouldn't follow it in your shoes.
(Performance on serialization is bad anyways)
-
2. Re: Can I receive binary messages via REST?
gkhrapunovich May 10, 2012 10:33 AM (in response to clebert.suconic)Clebert, thank you for the quick reply. I need to clear two things: (1) If HornetQ sends a generic binary message, will the receiver know where it ends? (2) What message type should we put in the header?
-
3. Re: Can I receive binary messages via REST?
clebert.suconic May 10, 2012 11:11 AM (in response to gkhrapunovich)You have the message type on the hader as a property. The message will be sent in a binary way (byte-array, stream.. etc).
Converting it to java object will require a java runtime on the client side though.
-
4. Re: Can I receive binary messages via REST?
gkhrapunovich May 10, 2012 11:40 AM (in response to gkhrapunovich)We are planning to use Google Protocol Buffers for serialization/deserialization. It is my understanding that they support cross-language binaries.
-
5. Re: Can I receive binary messages via REST?
clebert.suconic May 10, 2012 1:03 PM (in response to gkhrapunovich)Sure.. that will go beyond of hornetQ though. We will just deliver byte arrays and you can do anything you want with them.