X-Git-Url: https://git.teslayout.com/public/public/public/?a=blobdiff_plain;f=example%2Fdiameter%2Flauncher%2FLauncher.hpp;h=3ce4a207f0f75956775ca641c100cf0c131812f6;hb=603b76b5dc02acdfd87c58c51b6d48ae1858f58d;hp=21c3d25c41b3298ada7eb2663ded7d4162177b0a;hpb=4c3f0a4d7e4db76996404d80c6f939548fca656f;p=anna.git diff --git a/example/diameter/launcher/Launcher.hpp b/example/diameter/launcher/Launcher.hpp index 21c3d25..3ce4a20 100644 --- a/example/diameter/launcher/Launcher.hpp +++ b/example/diameter/launcher/Launcher.hpp @@ -18,6 +18,7 @@ #include #include #include +#include // Process #include @@ -25,6 +26,11 @@ #include +#define SH_COMMAND_TAG_FOR_REPLACE__CYCLE_ID "##cycleid##" +#define SH_COMMAND_TAG_FOR_REPLACE__TESTCASE_ID "##testcaseid##" +#define SH_COMMAND_TAG_FOR_REPLACE__TESTSTEP_ID "##teststepid##" + + namespace anna { namespace timex { class Engine; @@ -37,6 +43,10 @@ namespace anna { } class TestManager; +class RealmNode; +class MyDiameterEntity; +class MyLocalServer; +class MyDiameterEngine; // RealmNode resources class RealmNode; @@ -52,7 +62,6 @@ class Launcher : public anna::comm::Application { // Core engines: MyCommunicator *a_communicator; - anna::diameter::codec::Engine *a_codecEngine; anna::timex::Engine* a_timeEngine; MyCounterRecorder *a_counterRecorder; anna::Millisecond a_admlMinResolution; @@ -61,6 +70,7 @@ class Launcher : public anna::comm::Application { // Nodes deployment: realm_nodes_t a_nodes; RealmNode *a_workingNode; + RealmNode *a_operatedRealm; // auxiliary for eventOperation // comm resources: anna::comm::ServerSocket* a_httpServerSocket; // HTTP @@ -74,16 +84,23 @@ class Launcher : public anna::comm::Application { public: Launcher(); + //~Launcher(); TODO void loadServices(const std::string & xmlPathFile, bool eventOperation = false) throw(anna::RuntimeException); void startServices() throw(anna::RuntimeException); - anna::diameter::codec::Engine *getCodecEngine() const throw() { return a_codecEngine; } - RealmNode *getWorkingNode() const throw(anna::RuntimeException); // management operations working node - bool setWorkingNode(const std::string &name) throw(); // we could update ignoreFlagsOnValidation/integrationAndDebugging over the global codec engine - // but finally, that configuration issues will be global to the process. - - RealmNode *getRealmNode(const std::string &realmName) const throw(); + bool setWorkingNode(const std::string &name) throw(); + RealmNode *getRealmNode(const std::string &realmName) const throw(anna::RuntimeException); + RealmNode *getRealmNode(const anna::diameter::codec::Message &message) const throw(anna::RuntimeException); + bool uniqueRealm() const throw() { return (a_nodes.size() == 1); } + + // Operated realm for communication resources smart assignment //////////////////////////////////////////////////////////// + void updateOperatedRealmNodeWithMessage(const anna::diameter::codec::Message &message) throw(anna::RuntimeException); + RealmNode *getOperatedRealm() const throw(anna::RuntimeException); + MyDiameterEntity *getOperatedEntity() const throw(anna::RuntimeException); + MyLocalServer *getOperatedServer() const throw(anna::RuntimeException); + MyDiameterEngine *getOperatedEngine() const throw(anna::RuntimeException); + /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// MyCommunicator *getCommunicator() throw() { return a_communicator; }