EMA CPP - Exception adding ric into OmmArray

Im getting below exceptoin while adding ric codes into OmmArray for subscription.

Exception Type='OmmInvalidUsageException', Text='Failed to addArray() while encoding ElementList. Reason='RSSL_RET_INVALID_DATA'.

Could not figure out why this is being thrown.

Noticed that , when i add a lesser number of RIC codes , no issue , but when large number of ric's are added , this exception is thrown..

Best Answer

  • Hi @yajnasteju

    This should be because the encoded size of your OmmArray is more than 65535 bytes.

    The addArray() of ElementList will add the OmmArray as content of Element entry. Currently, the content of Element entry has a maximum encoded size of 65535 bytes. EMA will thrown an invalid usage exception once the OmmArray size is more than the maximum value.

Answers