Hello,
I have a working lightstreamer integration based on a node js / javascript client implementation.
I have the following adapter.xml:
<adapter_class>com.lightstreamer.adapters.remote.metadata.RobustNetworkedMetadataProvider</adapter_class>
<classloader>log-enabled</classloader>
<param name="request_reply_port">6662</param>
<param name="timeout">36000000</param>
</metadata_provider>
<data_provider>
<adapter_class>com.lightstreamer.adapters.remote.data.RobustNetworkedDataProvider</adapter_class>
<classloader>log-enabled</classloader>
<param name="request_reply_port">6663</param>
<param name="notify_port">6664</param>
</data_provider>
I also have a notifyUser listener:
metadataProvider.on('notifyUser', function(request, response){
console.log("notifyUser...");
console.log(request);
console.log(request['userName']);
console.log(request['userPassword']);
response.success();
});
This prints the following:
notifyUser...
{ id: '10000014588ddcd8a',
verb: 'notifyUser',
userName: null,
userPassword: null,
headers:
{ 'content-type': 'application/x-www-form-urlencoded; charset=UTF-8',
'cache-control': 'no-cache',
connection: 'keep-alive',
host: 'localhost',
'accept-language': 'en-US,en;q=0.5',
accept: 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
'content-length': '147',
origin: '
https://localhost:4433',
'user-agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:28.0) Gecko/20100101 Firefox/28.0',
'accept-encoding': 'gzip, deflate',
referer: '
https://localhost:4433/view1',
pragma: 'no-cache',
REQUEST_ID: '294' } }
null
null
... and then crashes the server.
1) the userName and userPassword fields are null - where exactly do these need to be passed so that they are available here to carry out the authentication?
2) Why does the server then crash?
3) I have had a long look and play around with the code. I can't seem to find the correct documentation on the arguments that will be passed to :
metadataProvider.on('notifyUser',........
Thanks in advance.