Error message when trying to subscribe streaming data via deployed TREP session.

Using the example 2.1.2. (Pricing.CreateStreamingPrices) connecting via "DEPLOYED" session to a local TREP I get the following error:

{
"ID": 2,
"Type": "Status",
"Key": {
"Name": "EUR="
},
"State": {
"Stream": "Closed",
"Data": "Suspect",
"Code": "AlreadyOpen",
"Text": "Request Rejected: Request key did not contain service Id."
}
}

The log file does not show any errors.

What does it mean?

Is there something I can do to fix it?

Best Answer

  • umer.nalla
    umer.nalla LSEG
    Answer ✓

    Hi @martin.grunwald

    When consuming data from TREP, if your request is rejected with a message similar to 'Request key did not contain service Id' then you will need to explicitly specify the service you want to source the data from:

      "ID":2,   "Key":{     "Name":"VOD.L"   },   "Service":"ELEKTRON_DD" 

    Here, I have explicitly specified ELEKTRON_DD as the service from which to request the item.

    This would be because your TREP team has not specified a Default Websocket request service in their TREP config.

    Feel free to read my short tutorials on using Websocket API which covers the above point as well as other pertinent information.

Answers