anna::diameter::comm::ApplicationMessageOamModule & appMsgOamModule = anna::diameter::comm::ApplicationMessageOamModule::instantiate();
appMsgOamModule.enableCounters(); // this special module is disabled by default (the only)
static int scope_id = 3;
- bool id_0_registered = false;
unsigned int id_value;
std::string codecEngineName;
throw ex;
}
- if (id_value == 0) {
- id_0_registered = true;
- bpd = d;
- }
+ bpd = d; // base protocol dictionary in case of monostack. If multistack, will be calculated later
// Create codec engine and register it in the codec engine manager:
codecEngineName = anna::functions::asString("CodecEngineForStackId_%llu", id_value);
// Basic checking for multistack:
bool multistack = (stackEngine.stack_size() > 1);
if (multistack) {
- if(!id_0_registered)
+ bpd = stackEngine.getDictionary(0);
+ if(!bpd)
throw anna::RuntimeException("In multistack applications is mandatory register a stack id = 0 using a dictionary which contains the needed elements to build base protocol messages (CER/A, DWR/A, DPR/A, STR/A, etc.)", ANNA_FILE_LOCATION);
}
- else { // monostack
- if (!bpd)
- bpd = ce->getDictionary(); // in mono-stack applications, we understand the existing stack as the used
- // for base protocol, regardless if it is registered with stack id 0 or not
- }
// REALMS:
for(anna::xml::Node::const_child_iterator it = servicesNode->child_begin(); it != servicesNode->child_end(); it++) {
}
catch(anna::RuntimeException &ex) {
ex.trace();
- response_content = anna::functions::asString("Loaded services from file '%s' with some problems (ignored ones)", servicesFile.c_str());
+ response_content = anna::functions::asString("Loaded services from file '%s' with errors", servicesFile.c_str());
return;
}
response_content = anna::functions::asString("Loaded services from file '%s'", servicesFile.c_str());