All demos and samples uses protocol buffer for the IDL. Can I use the proteus broker with only the TCP to transport plain JSON object (without protobuf support)
I will have a Java example tomorrow or Thursday.
Thanks for taking time in providing the replay. I missed to mention that I am looking for a java solution without protobuf support.
Here’s the Java example I threw together:
I found a bug while I was doing it so you need use proteus-java 1.5.4.
Here’s the command to start the broker:
docker run -p 8001:8001 -p 7001:7001 -p 9000:9000 -e BROKER_SERVER_OPTS="’-Dnetifi.authentication.0.accessKey=9007199254740991’
Inside it uses a new concept we’re working on called a “Named RSocket”. Proteus lets you assign a name to a raw RSocket, and then route requests to that RSocket. In the example the service binds an RSocket called “JsonAddingExample”, and the client creates an connection to it using that name. Any calls to the interaction methods of the RSocket interface will automatically route to that RSocket on the service. Additionally, nothing special is needed for the RSocket - it just takes the standard interface - so anything that implements RSocket can be served from here. And this lets you have more than one RSocket handler per connection. This is a flexible example - you don’t even need to send JSON with this- you can send whatever you’d like - pictures, binary files, etc. I’m using it to send JSON in the data field of the Payload, and using a string in metadata field to do routing. In the near future there are going to be some opinionated options that JSON as well.
Let me know if you have any more questions.