" + parseInt(Math.random() * 100, 10));

client.onConnectionLost = function (responseObject) {
    debug("CONNECTION LOST - " + responseObject.errorMessage);
};

client.onMessageArrived = function (message) {
    debug("RECEIVE ON " + message.destinationName + " PAYLOAD " + message.payloadString);

    var p = JSON.parse(message.payloadString);
    lines.push(p);
    draw(p, true);
};

var options = {
    timeout: 3,
    keepAliveInterval: 30,
    onSuccess: function () {
        debug("CONNECTION SUCCESS")