title: Getting Websockets in Spring to work with PostMan for testing
body: <p>I have created test project according to the spring boot websocket tutorial found here: <a href="https://spring.io/guides/gs/messaging-stomp-websocket/" rel="nofollow noreferrer">https://spring.io/guides/gs/messaging-stomp-websocket/</a></p>
  <pre><code>@Configuration
  @EnableWebSocketMessageBroker
  
  public class WebSocketConfig implements WebSocketMessageBrokerConfigurer {
  
  @Override
  public void configureMessageBroker(MessageBrokerRegistry config) {
      config.enableSimpleBroker(&quot;/topic&quot;);
      config.setApplicationDestinationPrefixes(&quot;/app&quot;);
  }
  
  @Override
  public void registerStompEndpoints(StompEndpointRegistry registry) {
      registry.addEndpoint(&quot;/OrderBookSample&quot;).setAllowedOrigins(&quot;*&quot;);
     registry.addEndpoint(&quot;/OrderBookSample&quot;).setAllowedOrigins(&quot;*&quot;).withSockJS();
  }
  </code></pre>
  <p>}</p>
  <p>and</p>
  <pre><code>@Controller
  public class OrderController {
          @MessageMapping(&quot;/hello&quot;)
          @SendTo(&quot;/topic/greetings&quot;)
          public String greeting(String message) throws Exception {
              Thread.sleep(1000); // simulated delay
              return message;
          }
  
  }
  </code></pre>
  <p>What I am trying to figure out is how to test the topic and read from it via post man I can connect just fine ws://localhost:8080/OrderBookSample</p>
  <p>but I have been trying to figure out a method to connect to the topics I have created so I can read/write from them</p>
  <p>Any help would be appreciated ( I am new to websockets)</p>