question

Upvotes
Accepted
9 4 5 7

Dictionary Download for a Non-Interactive Provider

I am trying to implement a Non-Interactive Provider and my application is currently able to publish data to TREP.

the NIP application is currently loading the dictionary from local filesystem after logging in as a provider. So i have been able to publish data to TREP.

However, I would look to download this dictionary from the TREP ADH instead of relying on the local filesystem.

Whenever the dictionary request is sent, the NIP application receives a Close Request without any data.

I have ensured the the Login Response contains the SupportProviderDictionaryDownload element and is set to 1.

Could you please help with what i could be missing and why I would be receiving a Close Request?

Below is my Request and I have logged in as a Provider.

<REQUEST domainType="DICTIONARY" streamId="3" containerType="NO_DATA" flags="0x00" dataSize="0">
    <key flags="0x0B (HAS_SERVICE_ID|HAS_NAME|HAS_FILTER)" serviceId="258" name="RWFFld" filter="15"/>
    <dataBody>
    </dataBody>
</REQUEST>
elektronrefinitiv-realtimeelektron-sdktreprrteta-apiADH
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
24.6k 54 17 14

Hello @arvnar2407

I have tried to replicate your issue with ETA Java 3.6.1 (RTSDK 2.0.1) NIprovider example and I can replicate the issue by setting the streamId to 3 and 4 (for RWFFld and RWFEnum).

RWFFld Dictionary request message:

<REQUEST domainType="DICTIONARY" streamId="3" containerType="NO_DATA" flags="0x00" dataSize="0">
    <key flags="0x0B (HAS_SERVICE_ID|HAS_NAME|HAS_FILTER)" serviceId="258" name="RWFFld" filter="15"/>
    <dataBody>
    </dataBody>
</REQUEST>

RWFFld Dictionary response message:

<CLOSE domainType="DICTIONARY" streamId="3" containerType="NO_DATA" flags="0x00" dataSize="0">
    <dataBody>
    </dataBody>
</CLOSE>

The RWFEnum dictionary request message with streamId 4 also receives the close response message as well.

When I use the default streamId -1 for RWFFld and -2 for RWFEnum, the ETA receives dictionary information successfully.

<REQUEST domainType="DICTIONARY" streamId="-1" containerType="NO_DATA" flags="0x00" dataSize="0">
    <key flags="0x0B (HAS_SERVICE_ID|HAS_NAME|HAS_FILTER)" serviceId="258" name="RWFFld" filter="15"/>
    <dataBody>
    </dataBody>
</REQUEST>
...
<REQUEST domainType="DICTIONARY" streamId="-2" containerType="NO_DATA" flags="0x00" dataSize="0">
    <key flags="0x0B (HAS_SERVICE_ID|HAS_NAME|HAS_FILTER)" serviceId="258" name="RWFEnum" filter="15"/>
    <dataBody>
    </dataBody>
</REQUEST>
...
<REFRESH domainType="DICTIONARY" streamId="-1" containerType="SERIES" flags="0x168 (HAS_MSG_KEY|SOLICITED|REFRESH_COMPLETE|CLEAR_CACHE)" groupId="0" State: Non-streaming/Ok/None - text: "" dataSize="639364">
    <key flags="0x0B (HAS_SERVICE_ID|HAS_NAME|HAS_FILTER)" serviceId="258" name="RWFFld" filter="15"/>
...

Could you please test the dictionary request messages with streamId -1 (for RWFFld) and -2 (for RWFEnum)?

You can find more detail in ETA Java NIProvider.java and NIProviderDictionaryHandler.java example source code.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
24.6k 54 17 14

Hello @arvnar2407

I am not the ETA expert but based on the ETA Java NIprovider example, the application needs to manual sends the Dictionary request message to ADH if the Login response message contains SupportProviderDictionaryDownload as 1

if (loginHandler.refreshInfo().checkHasFeatures()
     && loginHandler.refreshInfo().features().checkHasSupportProviderDictionaryDownload()
   && loginHandler.refreshInfo().features().supportProviderDictionaryDownload() == 1) {

  int sendStatus = dictionaryHandler.sendDictionaryRequests(chnl, error, defaultServiceId);

You can see more detail in the ETA Java NIprovider example setupDictionary() function.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Thank you for the response. I have logged in as Provider and the login response contains the SupportProviderDictionaryDownload element and set to 1.

However, On sending the Dictionary request, a close Message is received and I am looking to find reasons as to why this could happen.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.