Elecktron programtic config
std::stringstrSeverName("Server01");
MapinnerMap;
ElementListelementList;
// ConsumerGroup
elementList.addAscii( "DefaultConsumer", "Consumer_1" );
innerMap.addKeyAscii( "Consumer_1", MapEntry::AddEnum, ElementList()
.addAscii( "ChannelSet", "Channel_1,Channel_2" )
.addAscii( "Logger", "Logger_1" )
.addAscii( "Dictionary", "Dictionary_1" )
.addUInt( "ItemCountHint", 5000 )
.addUInt( "ServiceCountHint", 5000 )
.addUInt( "ObeyOpenWindow", 0 )
.addUInt( "PostAckTimeout", 5000 )
.addUInt( "RequestTimeout", 5000 )
.addUInt( "MaxOutstandingPosts", 5000 )
.addInt( "DispatchTimeoutApiThread", 1 )
.addUInt( "HandleException", 0 )
.addUInt( "MaxDispatchCountApiThread", 500 )
.addUInt( "MaxDispatchCountUserThread", 500 )
.addInt( "ReactorEventFdPort", 45000 )
.addInt( "PipePort", 4001 ).complete() ).complete();
elementList.addMap( "ConsumerList", innerMap );
elementList.complete();
innerMap.clear();
m_ConfigMap.addKeyAscii( "ConsumerGroup", MapEntry::AddEnum, elementList );
elementList.clear();
// ChannelGroup
innerMap.addKeyAscii( "Channel_2", MapEntry::AddEnum, ElementList()
.addEnum( "ChannelType", 0 )
.addAscii( "InterfaceName", strSeverName.c_str() )
.addEnum( "CompressionType", 0) // 0 none compression
.addUInt( "GuaranteedOutputBuffers", 5000 )
.addUInt( "ConnectionPingTimeout", 50000 )
.addInt( "ReconnectAttemptLimit", 10)
.addInt( "ReconnectMinDelay", 2000 )
.addInt( "ReconnectMaxDelay", 6000 )
.addAscii( "Host", strSeverName.c_str() )
.addAscii( "Port", "14002" )
.addUInt( "TcpNodelay", 1 ) // 1 mean no delay, 0 mean Nagle’s algorithm
.addUInt( "XmlTraceToFile", 0 ) // 0 : Turns off tracing, 1: Turns on tracing to an XML file.
.addUInt( "MsgKeyInUpdates", 1 ).complete());
innerMap.addKeyAscii( "Channel_1", MapEntry::AddEnum, ElementList()
.addEnum( "ChannelType", 0 )
.addAscii( "Host", strSeverName.c_str() )
.addAscii("Port", "14002" ).complete() ).complete();
elementList.addMap( "ChannelList", innerMap );
elementList.complete();
innerMap.clear();
m_ConfigMap.addKeyAscii( "ChannelGroup", MapEntry::AddEnum, elementList );
elementList.clear();
// LoggerGroup
innerMap.addKeyAscii( "Logger_1", MapEntry::AddEnum,
ElementList()
.addEnum( "LoggerType", 1 ) // 1 is stdout
.addEnum( "LoggerSeverity", 1 ).complete() );
innerMap.addKeyAscii( "Logger_2", MapEntry::AddEnum,
ElementList()
.addEnum( "LoggerType", 0 )
.addAscii( "FileName", "logFile" )
.addEnum( "LoggerSeverity", 1 ).complete() ).complete();
elementList.addMap( "LoggerList", innerMap );
elementList.complete();
innerMap.clear();
m_ConfigMap.addKeyAscii( "LoggerGroup", MapEntry::AddEnum, elementList );
elementList.clear();
//DictionaryGroup
innerMap.addKeyAscii( "Dictionary_1", MapEntry::AddEnum,
ElementList()
.addEnum( "DictionaryType", 1).complete());
innerMap.addKeyAscii( "Dictionary_2", MapEntry::AddEnum,
ElementList()
.addEnum( "DictionaryType", 0)
.addAscii( "RdmFieldDictionaryFileName", "./RDMFieldDictionary" )
.addAscii( "EnumTypeDefFileName", "./enumtype.def" ).complete() ).complete();
elementList.addMap( "DictionaryList", innerMap );
elementList.complete();
m_ConfigMap.addKeyAscii( "DictionaryGroup", MapEntry::AddEnum, elementList );
elementList.clear();
m_ConfigMap.complete();
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
error message is here, both logger_1 and Dictionary_1 is failed, why?
loggerMsg TimeStamp: 15:17:54.885 ClientName: EmaConfig Severity: Error Text: no configuration exists for consumer dictionary [DictionaryGroup|Di ctionaryList|Dictionary.Dictionary_1|]; will use dictionary defaults loggerMsgEnd
loggerMsg TimeStamp: 15:17:54.886 ClientName: EmaConfig Severity: Error Text: no configuration exists for consumer logger [LoggerGroup|LoggerList |Logger.Logger_1|]; will use logger defaults loggerMsgEnd
Best Answer
-
If I paste an EmaConfig.xml file which contains only empty "Logger_1" and "Dictionary_1" node, the error message will not be logged. I believe that the errors are generated when EMA try to load the nodes from the EmaConfig.xml file which doesn't exist. The programmatic configuration should still work correctly, even though these error are generated.
The EmaConfig.xml file I use is below. If you would like to try the file in your application, the additional nodes should be added for "Logger_2" and "Dictionary_2".
<?xml version="1.0" encoding="UTF-8"?>
<EmaConfig>
<LoggerGroup>
<LoggerList>
<Logger>
<Name value="Logger_1"/>
</Logger>
</LoggerList>
</LoggerGroup>
<DictionaryGroup>
<DictionaryList>
<Dictionary>
<Name value="Dictionary_1"/>
</Dictionary>
</DictionaryList>
</DictionaryGroup>
</EmaConfig>0
Answers
-
Even I use the same code in 4.4.3
Example: Programmatic Configuration
still get the same error message.Would someone help to repeat that? thanks.
0 -
There is a forum for Elektron. If you move this question there using the cog icon top right, it will be answered faster.
0 -
421__MarketPrice__ProgrammaticConfig
have the same problems.
0 -
I have found the same errors in logger with the 421__MarketPrice__ProgrammaticConfig application, even though the Logger and Dictionary configurations are configured properly. I will investigate the issue further and let you know the result.
0 -
Thanks for explaining that. that message should be a warning message with more details what happening. hopefully that will be in next realease.
btw, I am assuming EmaConfig.xml overwrite programmaticConfig, is that right?
0 -
The programmatic config should override the parameters configured in EmaConfig.xml file. Please see the screenshot of the EMA Configuration Guide document for reference.
0
Categories
- All Categories
- 6 AHS
- 37 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 367 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 59 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛