Is there a way to connect redis as a full featured stompbroker?
As per redis documentation, we can use redis as message broker. we are planning to use redis as a message broker for our chat product. I am trying to connect to redis but its failing. Is there a way to connect reids message broker for stomp?
@Configuration
@EnableWebSocketMessageBroker
public class WebSocketConfig implements WebSocketMessageBrokerConfigurer {
@Override
public void registerStompEndpoints(StompEndpointRegistry registry) {
registry.addEndpoint("/chat");
}
@Override
public void configureMessageBroker(MessageBrokerRegistry registry) {
registry.setApplicationDestinationPrefixes("/app");
// registry.enableSimpleBroker("/topic");
registry.enableStompBrokerRelay("/topic").setRelayHost("localhost").setRelayPort(6379).setClientLogin("guest").setClientPasscode("guest");
}
}
I got this exception, when I tried.
io.netty.handler.codec.DecoderException: java.lang.IllegalArgumentException: No enum constant org.springframework.messaging.simp.stomp.StompCommand.-ERR unknown command CONNECT
, with args beginning with: