|
@@ -9,7 +9,7 @@ public class GreetingController {
|
|
|
|
|
|
|
|
|
|
@MessageMapping("/hello")
|
|
@MessageMapping("/hello")
|
|
- @SendTo("/topic/greetings")
|
|
|
|
|
|
+ @SendTo("/direct/greetings")
|
|
public Greeting greeting(HelloMessage message) throws Exception {
|
|
public Greeting greeting(HelloMessage message) throws Exception {
|
|
Thread.sleep(3000); // simulated delay
|
|
Thread.sleep(3000); // simulated delay
|
|
return new Greeting("Hello, " + message.getName() + "!");
|
|
return new Greeting("Hello, " + message.getName() + "!");
|