Link to home
Start Free TrialLog in
Avatar of Rohit Bajaj
Rohit BajajFlag for India

asked on

Understanding websocket example in spring

HI,
I am using hte websocket example on : https://spring.io/guides/gs/messaging-stomp-websocket/
when i click on the connect button on the web page which loads when this application code is run the following code executes :
function connect() {
    var socket = new SockJS('/gs-guide-websocket');
    stompClient = Stomp.over(socket);
    stompClient.connect({}, function (frame) {
        setConnected(true);
        console.log('Connected: ' + frame);
        stompClient.subscribe('/topic/greetings', function (greeting) {
            showGreeting(JSON.parse(greeting.body).content);
        });
    });
}

Open in new window


And i see the following two network calls in the Network tab of chrome :
http://localhost:8080/gs-guide-websocket/info?t=1474970676486
ws://localhost:8080/gs-guide-websocket/614/vbxj5iok/websocket

What do these mean and what are there purpose... what are the things in bold means and where did they come from ?


Thanks
ASKER CERTIFIED SOLUTION
Avatar of Kimputer
Kimputer

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial