Greetings! I am using latest RTSDK C/CPP 2.1.3.G1 aka EMA/ETA 3.7.3.G1 aka 3.7.3.3 and having dictionary timeout issues similar to https://community.developers.refinitiv.com/questions/95787/emadictionary-retrieval-failed-timed-out-after-wai.html
I increased timeout up to 120 seconds, and it helped only once, while most of the time I am having timeout anyway, so I tried to modify config to use local dictionary files. I am preparing config programmatically, so in the code it looks like the following:
void createProgramaticConfig(Map& configDb, const EmaString& aHost, const EmaString& aPort) {
Map elementMap;
ElementList elementList;
elementMap.addKeyAscii("Consumer_1", MapEntry::AddEnum,
ElementList()
.addAscii("Channel", "Channel_1")
.addAscii("Logger", "Logger_1")
.addAscii("Dictionary", "Dictionary_1")
.complete()).complete();
elementList.addMap("ConsumerList", elementMap);
elementList.complete();
elementMap.clear();
configDb.addKeyAscii("ConsumerGroup", MapEntry::AddEnum, elementList);
elementList.clear();
//----------------
Map dictMap;
dictMap.addKeyAscii("Dictionary_1", MapEntry::AddEnum,
ElementList()
.addAscii("Name", "Dictionary_1")
.addAscii("DictionaryType", "DictionaryType::FileDictionary")
.addAscii("RdmFieldDictionaryFileName", "./elektron/RDMFieldDictionary")
.addAscii("EnumTypeDefFileName", "./elektron/enumtype.def").complete()).complete();
ElementList dictList;
dictList.addMap("DictionaryList", dictMap);
dictList.complete();
configDb.addKeyAscii("DictionaryGroup", MapEntry::AddEnum, dictList);
//----------------
elementMap.addKeyAscii("Logger_1", MapEntry::AddEnum,
ElementList()
.addEnum("LoggerType", 0)
.addAscii("FileName", "logFile")
.addEnum("LoggerSeverity", 0).complete()).complete();
elementList.addMap("LoggerList", elementMap);
elementList.complete();
elementMap.clear();
configDb.addKeyAscii("LoggerGroup", MapEntry::AddEnum, elementList);
elementList.clear();
//----------------
ElementList channelElementList;
channelElementList
.addEnum("ChannelType", 1) // Use the RSSL_CONN_TYPE_ENCRYPTED connection
.addAscii("Host", aHost)
.addAscii("Port", aPort)
.addUInt("EnableSessionManagement", 1);
channelElementList.addEnum("EncryptedProtocolType", 1); //RSSL_CONN_TYPE_ENCRYPTED
channelElementList.complete();
elementMap.addKeyAscii("Channel_1", MapEntry::AddEnum, channelElementList);
elementMap.complete();
elementList.addMap("ChannelList", elementMap);
elementList.complete();
configDb.addKeyAscii("ChannelGroup", MapEntry::AddEnum, elementList);
configDb.complete();
}
Once config is made, I am printing it to the log, to ensure it has valid structure:
MapEntry action="Add" key dataType="Ascii" value="ConsumerGroup" dataType="ElementList"
ElementList
ElementEntry name="ConsumerList" dataType="Map"
Map
MapEntry action="Add" key dataType="Ascii" value="Consumer_1" dataType="ElementList"
ElementList
ElementEntry name="Channel" dataType="Ascii" value="Channel_1"
ElementEntry name="Logger" dataType="Ascii" value="Logger_1"
ElementEntry name="Dictionary" dataType="Ascii" value="Dictionary_1"
ElementEntry name="DictionaryRequestTimeOut" dataType="UInt" value="120000"
ElementListEnd
MapEntryEnd
MapEnd
ElementEntryEnd
ElementListEnd
MapEntryEnd
MapEntry action="Add" key dataType="Ascii" value="DictionaryGroup" dataType="ElementList"
ElementList
ElementEntry name="DictionaryList" dataType="Map"
Map
MapEntry action="Add" key dataType="Ascii" value="Dictionary_1" dataType="ElementList"
ElementList
ElementEntry name="Name" dataType="Ascii" value="Dictionary_1"
ElementEntry name="DictionaryType" dataType="Ascii" value="DictionaryType::FileDictionary"
ElementEntry name="RdmFieldDictionaryFileName" dataType="Ascii" value="./elektron/RDMFieldDictionary"
ElementEntry name="EnumTypeDefFileName" dataType="Ascii" value="./elektron/enumtype.def"
ElementListEnd
MapEntryEnd
MapEnd
ElementEntryEnd
ElementListEnd
MapEntryEnd
MapEntry action="Add" key dataType="Ascii" value="LoggerGroup" dataType="ElementList"
ElementList
ElementEntry name="LoggerList" dataType="Map"
Map
MapEntry action="Add" key dataType="Ascii" value="Logger_1" dataType="ElementList"
ElementList
ElementEntry name="LoggerType" dataType="Enum" value="0"
ElementEntry name="FileName" dataType="Ascii" value="logFile"
ElementEntry name="LoggerSeverity" dataType="Enum" value="0"
ElementListEnd
MapEntryEnd
MapEnd
ElementEntryEnd
ElementListEnd
MapEntryEnd
MapEntry action="Add" key dataType="Ascii" value="ChannelGroup" dataType="ElementList"
ElementList
ElementEntry name="ChannelList" dataType="Map"
Map
MapEntry action="Add" key dataType="Ascii" value="Channel_1" dataType="ElementList"
ElementList
ElementEntry name="ChannelType" dataType="Enum" value="1"
ElementEntry name="Host" dataType="Ascii" value="us-east-1-aws-3-med.optimized-pricing-api.refinitiv.net"
ElementEntry name="Port" dataType="Ascii" value="14002"
ElementEntry name="EnableSessionManagement" dataType="UInt" value="1"
ElementEntry name="EncryptedProtocolType" dataType="Enum" value="1"
ElementListEnd
MapEntryEnd
MapEnd
ElementEntryEnd
ElementListEnd
MapEntryEnd
However, this dictionary config is being ignored, and app is trying to request dictionary anyway. Log file attached: logFile_11052.txt
Probably, config is a bit wrong? However, I made it according to examples, and not able to find mistakes there. Could anybody assits, please?
Also, is it normal to experience such a big timeouts for dictionary requests from server?