Not able to communicate from Java Standalone client to SpringBoot enabled Rsocket server
See original GitHub issueI have an instance of Rsocket server(responder) and it works perfectly fine when I write a requester snippet out of a springboot API exposed client. The connection to the server is being established using ` private final RSocketRequester rSocketRequester;
public CustomerServiceAdapter(RSocketRequester.Builder rsocketRequesterBuilder) {
this.rSocketRequester = rsocketRequesterBuilder
.connectTcp("localhost", 7000).block();
}`
This works perfectly when invoked using the rsc.jar and command line invocation.
However, when I try to invoke using a standalone Java client as a requester, there are some issues .The client instance obtained by using
RSocket client = RSocketFactory.connect() .transport(TcpClientTransport.create(7000)) .start() .block();
RSocketFactory is not able to invoke the server . It connects but an exception with
_
MonoIgnoreThen
_ is returned on the client side and the responder server does not listen to the controller mapping and simply java.nio.channels.ClosedChannelException is thrown.
Any help would help.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top GitHub Comments
Hi Oleg,
Thanks for a prompt reply, As described above, I have put my code in git.
https://github.com/dushdushyant/rsocket-server/blob/master/src/main/java/io/pivotal/rsocketserver/RSocketController.java This is the responder server for RSocket Server and this works fine when tested over the rsc.jar file or another springboot requestor.
The issue is in this code , https://github.com/dushdushyant/rsocket-rnd/blob/master/src/main/java/com/rnd/SampleRScoketClient.java. This is the requestor code which is trying to create a connection to the Rsocket and invoke a simple message mapping.
Thanks and Regards, Dushyant
@dushdushyant Here is my example from vanilla rsocket client to spring boot rsocket server. Hope this helps you.