I want to use dynamic-tcp-client in my project as a dynamic-tcp-client. I want to get reply in this client,so I changed the interface ,add a retrun String.
@MessagingGateway() public interface ToTCP { @Gateway(requestChannel = "toTcp.input") public String send(String data, @Header("host") String host, @Header("port") int port); }
I want to get reply message from server
ToTCP toTcp = context.getBean(ToTCP.class);
String receive =toTcp.send("foo", "localhost", 1234);
now I get a waring
Unexpected message - no endpoint registered with connection interceptor:
I don't know how to add the reply-channel?