1

I am trying to use RSocket for Microservices within my org. As we have lot to communicate and fetch from databases like Cassandra and Postgresql, I observed a dip in performance.

When I run a sample Rsocket Client and Rsocket Server that returns a mocked response, I am getting a throughput of 12k TPS. Once I integrate to get the same codebase with Cassandra it is 300 TPS and Postgresql is 400 TPS. If I add HikariCP to Postgresql, it is 700 TPS.

For the same usecase with blocking HTTP it is 800 TPS and non-blocking HTTP is 1900 TPS.

This study is made on Mac Laptop 8 cores, 16 GB, rsocket-java (No Spring or RPC).

I am confused whether RSocket is suited for Microservices usecase or not.

Please provide your experience and any benchmark available for further studies.

8
  • You need to show what your code looks like for each Commented Jun 2, 2020 at 17:53
  • Its a simple RSocket Client calling Rsocket Server over JDBC to Database. Commented Jun 2, 2020 at 18:16
  • That doesn't add up - JDBC isn't non-blocking, so you can't utilise it in a fully non-blocking solution. In any case, we'll need to see the code and preferably raw results for each case, not just a description of what it does. This isn't answerable at present. Commented Jun 3, 2020 at 10:03
  • I understand JDBC is blocking. But still a throughput does not add up against the motivation statement by rsocket. I will try to put a sample code here. Thank you Commented Jun 3, 2020 at 14:18
  • You should be using the non-blocking DB clients Cassandra - baeldung.com/spring-data-cassandra-reactive Postgres - github.com/r2dbc/r2dbc-postgresql Without these, it's more likely that the problems are in your code. Commented Jun 15, 2020 at 7:50

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.