How do you identify if a RIC is a chain RIC in order to subscribe to all the underlying RICs?

I don't believe there is an EMA function which will allow you to subscribe[registerClient] to all the underlying RICs in the chain. So in lieu of this functionality, I wish to pull FIDs from a RIC to determine if it is a chain RIC. From that I can likely subscribe to the associated LONGLINK 1-14 (FID 800 - 813) and see if the LONGNEXTLR (FID:815) has a value to keep pulling in further RICs.

Is the field REF_COUNT(239) a reliable field to use to determine if I'm dealing with a chain?

Best Answer

  • Hi @Nana,

    You are correct, EMA does not have the capability to automatically subscribe to the underlying RICs within a chain. In general, you will have to look for a specific field within the response message to determine if you are working with a chain. The reference to the LONGLINK 1-14 and REF_COUNT are fields which you can use as reliable indicators you are dealing with a chain. The LONGNEXTLR and LONGPREVLR are only present if you have additional/previous records within the chain.

    In general, the REF_COUNT field should be a sufficient indicator.

Answers

  • Hi @Nana,

    Nick is absolutely right.

    You also have to know that you may encounter different types of chains. They all work the same but use different fields
    that support different sizes of RICs. See bellow:

    • LINK_ chain records use the following fields that
      are limited to 10 char RICs:
      • LINK_1 to LINK_14
      • PREV_LR
      • NEXT_LR
    • LONGLINK chain records use the following fields that
      are limited to 17 char RICs:
      • LONGLINK_1 to LONGLINK_14
      • LONGPREVLR
      • LONGNEXTLR
    • BR_LINK_ chain records use the following fields that
      are limited to 32 char RICs:
      • BR_LINK1 to BR_LINK14
      • BR_PREVLR
      • BR_NEXTLR

    These 3 types of chain use the same REF_COUNT to indicate
    the number of links used by the chain element.

    I’m going to write an article with
    much more details about chains. I’ll keep you posted via this question.

  • Hello Wasin, I don't see any text saying "Accept". I only see "Like", "Add Comment", "Reward user" and "Share"...

  • Thanks Nick...good answer...

  • Thanks Olivier...very good information... I appreciate it

  • Hi @Nana,

    You may be interested by the following articles and the
    source code that goes with them: