question

Upvotes
Accepted
27 2 4 9

RICs data not coming back

Hi

I am using Java EMA API. I am sending 53000 RICs using my program. But when I see in my Analytics APP (AWS), I don't find RICs, which are supposed to be there. I doubt if I am getting all the RICs data back. When I send only the RICs (supposed to appear in my app around 1900), then I can see those RICs data in the app. Following is part of my code, which sends data to API.

public static OmmArray processResultRows(AthenaClient athenaClient, String queryExecutionId,OmmArray arrayI,ElementList batchView,AppClient appClient,OmmConsumer consumer,OmmArray array) throws IOException {


try {

BufferedWriter writer = new BufferedWriter(new FileWriter("C:\\Users\\Operations\\Desktop\\RICS\\RicsGotIn.csv"));

GetQueryResultsRequest getQueryResultsRequest = GetQueryResultsRequest.builder()

// Max Results can be set but if its not set,

// it will choose the maximum page size

// As of the writing of this code, the maximum value is 1000

// .withMaxResults(1000)

.queryExecutionId(queryExecutionId).build();


GetQueryResultsIterable getQueryResultsResults = athenaClient.getQueryResultsPaginator(getQueryResultsRequest);

int j = 0;

for (GetQueryResultsResponse result : getQueryResultsResults) {

List<ColumnInfo> columnInfoList = result.resultSet().resultSetMetadata().columnInfo();

List<Row> results = result.resultSet().rows();

processRow(results, columnInfoList,arrayI,writer);


batchView.add(EmaFactory.createElementEntry().array(EmaRdm.ENAME_BATCH_ITEM_LIST, arrayI));

batchView.add(EmaFactory.createElementEntry().uintValue(EmaRdm.ENAME_VIEW_TYPE, 1));

batchView.add(EmaFactory.createElementEntry().array(EmaRdm.ENAME_VIEW_DATA, array));

try {

consumer.registerClient(EmaFactory.createReqMsg().serviceName("ELEKTRON_DD").payload(batchView), appClient);

}catch(Exception e) {

consumer.registerClient(EmaFactory.createReqMsg().serviceName("ELEKTRON_DD").payload(batchView), appClient);

}

j = j + 1;

//consumer.uninitialize();

arrayI = null;

arrayI = EmaFactory.createOmmArray();

}


System.out.println("The value of j is:" + j);


} catch (AthenaException e) {


Is there any restriction on the number of RICs, I am supposed to send?


GE-XXXXXX is the username.all_input_rics.zip

Attached is the file, which has all the RICs, I am requesting data for. Please let me know, if I should send you the full code.

Thanks

Dhruv


elektronrefinitiv-realtimeelektron-sdkrrtema-apielektron-message-api
all-input-rics.zip (263.5 KiB)
icon clock
10 |1500

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

Upvotes
Accepted
23k 22 9 14

Hello @dhruv.arora,

Firstly, you are correct, the total max ERT entitlement is for 50K RICs.

However, I would not recommend submitting all 50K in one batch, rather, I would submit more reasonable batches of 2-3K. (I would also examine the response per batch, and make sure if any invalid/expired RICs you would not be submitting them next time that you submit that batch)

I would additionally, for larger performance requirements, increase EMA GuaranteedOutputBuffers parameter in EmaConfig.xml. If you go with 2-3K batches, GuaranteedOutputBuffers 10K should work well, if you go with extra-large batches, you may wish to test and tune the configuration to your consumer requirements.


icon clock
10 |1500

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

Upvotes
27 2 4 9

Hi @zoya.farberov ,

I am attaching my code here.Consumer.txt

I am sending the RICs in batches only (please check the code), but still not getting RICs. Also, as you said in your answer to use GuaranteedOutputBuffers , I am not using config. Is there any other way to implement GuaranteedOutputBuffers programmatically ?

Thanks

Dhruv



consumer.txt (32.4 KiB)
icon clock
10 |1500

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

forgot to add, one batch is of 1000 RICs so the loop runs 54 times

Upvotes
23k 22 9 14

Hi @dhruv.arora,

Having looked at your RIC list file:

  • Each instrument is quoted, so if you submit as is, they will all come up as "not found".
  • There is an empty line on line 6866 which should cause an error on submit.
  • A significant percentage of the instruments appear to be invalid RICs.

However, this got me to think, are you printing/logging the responses that you get back in the callbacks? Are you seeing Refresh, Update, Status messages pertaining to the RICs that you request, so once you tally the responses, you should know exactly how many you are getting back? And what errors/status conditions happen?

icon clock
10 |1500

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

Click below to post an Idea Post Idea