Discover Refinitiv
MyRefinitiv Refinitiv Perspectives Careers
Created with Sketch.
All APIs Questions & Answers  Register |  Login
Ask a question
  • Questions
  • Tags
  • Badges
  • Unanswered
Search:
  • Home /
  • Elektron /
  • EMA /
avatar image
Question by Sergei Nazarov · Apr 23, 2020 at 10:58 AM · rmtespartial update

How to check whether Rmtes string contains partial update

We are implementing Rmtes string partial updates in our application and facing problems with testing it on rics ICAB[1-5]. Initial data snapshot contains proper data and looks like this (e.g. from fid ROW80_5):

1 Yr -07.25/-17.25  +13.50/+07.50  +15.25/+09.25  +09.25/+03.25   -20.75/-30.75

but in refresh message we are receiving update on the same fid and string replaced with something like this

09:02 1.00020 6.0000¥¥6.50/-25.50  .25.25¥¥36.25¥¥¥20.50¥¥¥4.50¥¥¥¥¥0.75¥¥¥0.75

We are using Ema library 1.2.0 and applying updates like this

    const FieldEntry& fe = fieldList.getEntry();
    rmtesBuffer.apply( fe.getRmtes() );

Initially we were storing char array from obtained string with getAsUTF8().c_buf(), it had the same effect.

So we would like to check whether updated rmtes string contains proper update sequence 0x1B 0x5B <offset position> 0x60, but we were wondering what is the proper way to translate Rmtes string into hex? Also does translation of Rmtes string into EmaBuffer removes any sequences like the one showed above?

People who like this

0 Show 0
Comment
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

4 Replies

  • Sort: 
avatar image
Best Answer
Answer by Sergei Nazarov · May 12, 2020 at 08:34 AM

So what was found out:

  • the corruption of underlying on transformation to EmaBuffer is present in 1.2.0 version of ema library, but was fixed somewhere before 1.4.0.
  • transformation to EmaBuffer will return wrong data anyway, so it's not usable even in later versions
  • as a solution we've decided to copy field as Data and store it as hex in EmaBuffer
const FieldEntry& fe = fl.getEntry();
const thomsonreuters::ema::access::Data& data = fe.getLoad();
const thomsonreuters::ema::access::EmaBuffer buffer = data.getAsHex();
rmtesBuffer.apply(buffer.c_buf(), buffer.length());
Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
REFINITIV
Answer by zoya.farberov · Apr 23, 2020 at 08:04 PM

Hello @Sergei Nazarov,

EMA would differentiate between refreshes and updates on the application's behalf, and trigger the appropriate registered callback.

I would try testing with example 310_MarketPrice_RMTES that comes with SDK.

The example is geared toward news RMTES, so in order to test with ICAB1-5, you would:

Modify on register:

UInt64 handle = consumer.registerClient( ReqMsg().serviceName( "ELEKTRON_EDGE" ).name( "ICAB1"/*"N2_UBMS"*/ ), client, closure 

And modify on decode:

void AppClient::decode( const FieldList& fl )
{
    while ( fl.forth("ROW80_5" /* "BCAST_TEXT"*/ ) )
    {
        const FieldEntry& fe = fl.getEntry();

        cout << "Name: " << fe.getName() << " Value: ";

        rmtesBuffer.apply( fe.getRmtes() );
        cout << rmtesBuffer.toString() << endl;
    }
}

I am unable to test an update on this now, as the instrument is not active.

For more information, if you would like to learn more about the RMTES refresh and update, as Transport tier handles RMTES for Message tier in ETA Developer Guide, lookup section "RMTES Decoding" and "rsslHasPartialRMTESUpdate".

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
Answer by Sergei Nazarov · Apr 27, 2020 at 03:43 PM

Hi, @zoya.farberov! Thanks for the suggestion with 310 example. It works as expected and I've noticed what was different in our app. Since creating RmtesBuffer copy with update is restricted and throws exception, we were getting EmaBuffer(EmaBufferU16 has the same effect), but turns out that this exact action is corrupting data in RmtesBuffer and we see gibberish I've shown as example in first question in buffer. Could you please tell what is the proper way to store a copy of rmtes update? Due to our design it's not really possible to apply it immediately after obtaining.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
REFINITIV
Answer by zoya.farberov · May 01, 2020 at 09:06 PM

Hi @Sergei Nazarov,

For me, the simpler approach is to copy the message, rather then the buffer, if you are on one of the later versions of EMA that supports the feature.

In Reference Guide see

:UpdateMsg::UpdateMsg    (    const UpdateMsg &     other    )    
Copy constructor.

This will save you processing time in main thread callback which is very important, and potentially allow to offload heavy processing to worker threads as design choice.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

Watch this question

Add to watch list
Add to your watch list to receive emailed updates for this question. Too many emails? Change your settings >
7 People are following this question.
  • Feedback
  • Copyright
  • Cookie Policy
  • Privacy Statement
  • Terms of Use
  • Careers
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Alpha
  • App Studio
  • Block Chain
  • Bot Platform
  • Calais
  • Connected Risk APIs
  • DSS
  • Data Fusion
  • Data Model Discovery
  • Datastream
  • Eikon COM
  • Eikon Data APIs
  • Elektron
    • EMA
    • ETA
    • WebSocket API
  • Legal One
  • Messenger Bot
  • Messenger Side by Side
  • ONESOURCE
    • Indirect Tax
  • Open PermID
    • Entity Search
  • Org ID
  • PAM
    • PAM - Logging
  • ProView
  • ProView Internal
  • Product Insight
  • Project Tracking
  • Refinitiv Data Platform
    • Refinitiv Data Platform Libraries
  • Rose's Space
  • Screening
    • Qual-ID API
    • Screening Deployed
    • Screening Online
    • World-Check One
    • World-Check One Zero Footprint
  • Side by Side Integration API
  • TR Knowledge Graph
  • TREP APIs
    • CAT
    • DACS Station
    • Open DACS
    • RFA
    • UPA
  • TREP Infrastructure
  • TRIT
  • TRKD
  • TRTH
  • Thomson One Smart
  • Transactions
    • REDI API
  • Velocity Analytics
  • Wealth Management Web Services
  • World-Check Data File
  • Explore
  • Tags
  • Questions
  • Badges