Streaming API not sending/accepting the subscription

1 post / 0 new
Jompe71
Streaming API not sending/accepting the subscription


const lightstreamerSubscription = new ls.Subscription( "MERGE", [ "MARKET:IX.D.OMX.IFD.IP" ], [ "BID", "OFFER", "UPDATE_TIME" ] );
lightstreamerSubscription.setRequestedSnapshot( "yes" );
lightstreamerSubscription.addListener({
onListenStart: function( subscription ) {
console.log( "Listen Start Subscription:" + subscription.isActive() );
},
onListenEnd: function( subscription ) {
console.log( "Listen End Subscription:" + subscription );
},
onSubscription: function() {
console.log( "Subscribing" );
},
onSubscriptionError: function( code, error ) {
console.log( "Subscription error:" + code + ", reason:" + error );
},
onItemUpdate: function( updateItem ) {
console.log( updateItem );
},
onUnsubscription: function() {
console.log( "Unsubscribed" );
}
});
lightstreamerClient.subscribe( lightstreamerSubscription );

The above code gives in the console:

"Lightstreamer.js:30 Listen Start Subscription:false"

but no onSubscription callback event is sent no update data either. Anyone know the reason for it?