rfa::common::RespStatus::SuspectEnum

vijay.rao1
vijay.rao1 Newcomer

When subscribed to a single symbol 'MRN_STORY' the callback we use for the subscription is providing us with a Context object that has a status member. When we call getDataState() on the status member it returns SuspectEnum. Even so, we continue to receive updates (news articles) so it's not clear why this subscription would be marked as being suspect. It doesn't look like getDataState() immediately returns SuspectEnum, only after having been subscribed for some time (several minutes).

Is there any more documentation available for this flag? What is the significance of this flag if we continue to receive updates for this symbol's subscription?

Thanks

Tagged:

Best Answer

  • @vijay.rao1

    I think the SuspectEnum you received is just default value that RFA set in the RespStatus object. Actually the Update message type does not contains Response Status. It just like the MarketPrice domain spec.

    Basically applications can identify whether or not the Response Message contains RespStatus by retrieving the Hint mask using getHintMask() and checking the value against RespStatusFlag. Our example such as StarterConsumer use this approach to verify if the response message contains RespStatus before print it to console.

    if(respMsg.getHintMask() & RespMsg::RespStatusFlag)
    {
    const RespStatus& status = respMsg.getRespStatus();
    //... Shows Response Status
    }


    Not sure have you added the codes to check RespStatusFlag before you get the RespStatus ?

Answers

  • We do perform that AND operation on getHintMask prior to checking the
    status. We can stream out the status and I'm currently trying to
    capture the 'suspect' status. Looks like status has a stream operator
    defined. On startup we get:

    (1) Status : None, Text : All connections Pending, Stream : Open, Data : Suspect

    Then our initial login fails which seems to be expected behavior:

    (2) Status : None, Text : All connections Pending, Stream : Open, Data : Suspect

    (3) Status : None, Text : Source unavailable... will recover when source is up, Stream : Open, Data : Suspect

    Then the login succeeds:

    (4) Status : None, Text : Login accepted by host EDGE...., Stream : Open, Data : Ok

    (5) Status : None, Text : All is well, Stream : Open, Data : Ok

    After that we only receive the following message for each incoming message:

    (6) Status : None, Text : All is well, Stream : Open, Data : Ok

    I
    suspect something happens after running for some time that causes a
    resubscribe which causes responses (1) through (3) to reoccur. I'm
    currently logging output in the hopes of encountering this condition.

    Thanks