// Assignments:
commEngine->setMaxConnectionDelay(tcpConnectDelayMs);
commEngine->setWatchdogPeriod(watchdogPeriodMs);
+ a_workingNode->setRequestRetransmissions(retransmissions);
// Realm information:
commEngine->setOriginHost(originHost->getValue());
// Register one entity for this engine:
a_workingNode->createEntity(entity->getValue(), ceaTimeoutMs, answersTimeoutMs);
- a_workingNode->setRequestRetransmissions(retransmissions);
a_workingNode->getEntity()->setSessionBasedModelsType(sessionBasedModelsType);
a_workingNode->getEntity()->setBalance(balance ? (balance->getValue() == "yes") : false); // for sendings
if (eventOperation) a_workingNode->getEntity()->bind();
result += "\n sendxml2e|<source_file>[|<step number>]";
result += "\n Sends xml source file (pathfile) to entity (it would be a";
result += "\n 'forward' event if it came through local server endpoint).";
+ result += "\n Take into account that the xml message is encoded just on";
+ result += "\n call. The xml file is not longer needed neither interpreted";
+ result += "\n in case of modification, after calling this command.";
result += "\n The step number should be provided for answers to indicate";
result += "\n the 'wait for request' corresponding step. If you miss this";
result += "\n reference, the sequence information (hop-by-hop, end-to-end)";
void Launcher::eventOperation(const std::string &operation, std::string &response_content) throw(anna::RuntimeException) {
LOGMETHOD(anna::TraceMethod tm("Launcher", "eventOperation", ANNA_FILE_LOCATION));
if (operation == "") return; // ignore
- LOGDEBUG(anna::Logger::debug(operation, ANNA_FILE_LOCATION));
+ LOGDEBUG(anna::Logger::debug(anna::functions::asString("Operation: %s", operation.c_str()), ANNA_FILE_LOCATION));
// Default response:
response_content = "Operation processed with exception: ";
throw anna::RuntimeException("Wrong body content format on HTTP Request. Use 'help' management command to see more information.", ANNA_FILE_LOCATION);
if(param3 == "") throw anna::RuntimeException(anna::functions::asString("Missing xml file for '%s' command in test id operation", param2.c_str()), ANNA_FILE_LOCATION);
codecMsg.loadXML(param3);
- if (codecMsg.isRequest()) {
- if (param4 != "")
- throw anna::RuntimeException("Step number is provided with answers (to resolve the corresponding 'wait for request' step), but NOT with requests", ANNA_FILE_LOCATION);
- }
- else {
- if (param4 == "") LOGWARNING(anna::Logger::warning("Step number has not been provided. Take into account that this answer message will be sent 'as is' and sequence information could be wrong at the remote peer", ANNA_FILE_LOCATION));
- }
+ LOGWARNING(
+ if (!codecMsg.isRequest() && (param4 == ""))
+ anna::Logger::warning("Step number has not been provided. Take into account that this answer message will be sent 'as is' and sequence information could be wrong at the remote peer", ANNA_FILE_LOCATION);
+ );
+
updateOperatedOriginHostWithMessage(codecMsg);
int stepNumber = ((param4 != "") ? atoi(param4.c_str()):-1);