From afd0edd68315606ee1a4a964a7b720edce7f1734 Mon Sep 17 00:00:00 2001 From: "William R. Otte" Date: Mon, 24 Nov 2008 00:03:19 +0000 Subject: ChangeLogTag: Sun Nov 23 23:59:50 UTC 2008 William R. Otte --- flat/CIAO/ChangeLog | 97 +++++ flat/CIAO/DAnCE/Deployment/DAnCE_Properties.idl | 29 +- .../DomainApplicationManager/Node_Locator.cpp | 5 +- .../DAnCE/DomainApplicationManager/Node_Locator.h | 2 +- .../ExecutionManager/ExecutionManager_Module.cpp | 54 ++- .../ExecutionManager/ExecutionManager_Module.h | 6 +- .../CIAO/DAnCE/NodeApplication/NodeApplication.mpc | 2 + .../DAnCE/NodeApplication/NodeApplication_Impl.cpp | 115 ++++-- .../DAnCE/NodeApplication/NodeApplication_Impl.h | 6 +- .../CIAO/DAnCE/NodeManager/Node_Manager_Module.cpp | 94 +++-- flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.h | 8 +- .../Plan_Launcher/Plan_Launcher_Base_Impl.cpp | 219 +++++++----- .../DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp | 34 +- .../DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp | 14 +- flat/CIAO/examples/Hello/ReDaC-Usage.html | 308 ---------------- flat/CIAO/examples/Hello/Sender/Sender_exec.cpp | 32 +- .../examples/Hello/descriptors/DeploymentPlan.cdp | 118 ++++++ flat/CIAO/examples/Hello/descriptors/Hello.cid | 93 ----- flat/CIAO/examples/Hello/descriptors/Hello.cpd | 13 - flat/CIAO/examples/Hello/descriptors/Libraries.iad | 8 - flat/CIAO/examples/Hello/descriptors/Receiver.ccd | 34 -- flat/CIAO/examples/Hello/descriptors/Receiver.cid | 24 -- flat/CIAO/examples/Hello/descriptors/Receiver.cpd | 14 - .../examples/Hello/descriptors/Receiver_Exec.iad | 29 -- .../examples/Hello/descriptors/Receiver_Stub.iad | 14 - .../examples/Hello/descriptors/Receiver_Svnt.iad | 29 -- flat/CIAO/examples/Hello/descriptors/Sender.ccd | 48 --- flat/CIAO/examples/Hello/descriptors/Sender.cid | 24 -- flat/CIAO/examples/Hello/descriptors/Sender.cpd | 14 - .../examples/Hello/descriptors/Sender_Exec.iad | 29 -- .../examples/Hello/descriptors/Sender_Stub.iad | 14 - .../examples/Hello/descriptors/Sender_Svnt.iad | 29 -- flat/CIAO/examples/Hello/descriptors/run_test.pl | 17 +- .../Hello/descriptors_ReDaC/deploymentplan.cdp | 222 ------------ .../Hello/descriptors_ReDaC/deploymentplan_add.cdp | 267 -------------- .../descriptors_ReDaC/deploymentplan_remove.cdp | 223 ------------ .../Hello/descriptors_events/NodeManagerMap.dat | 2 - .../descriptors_events/NodeManagerMapTwoHosts.dat | 2 - .../NodeManagerMap_collocated.dat | 1 - flat/CIAO/examples/Hello/descriptors_events/README | 145 -------- .../Hello/descriptors_events/RunEventTest.pm | 212 ----------- .../ciao-events-example-collocated.ced | 14 - .../ciao-events-example-with-federation.ced | 48 --- .../ciao-events-example-with-filters.ced | 51 --- .../descriptors_events/ciao-events-example.ced | 14 - .../ciao-events-federation-mcast.ced | 58 --- .../ciao-events-federation-udp-collocated.ced | 47 --- .../ciao-events-federation-udp-two-hosts.ced | 50 --- .../ciao-events-federation-udp.ced | 49 --- .../descriptors_events/deploymentplan_events.cdp | 260 -------------- .../deploymentplan_events_collocated.cdp | 260 -------------- .../deploymentplan_federation.cdp | 233 ------------ .../deploymentplan_federation_mcast.cdp | 231 ------------ .../deploymentplan_federation_udp.cdp | 246 ------------- .../deploymentplan_federation_udp_collocated.cdp | 246 ------------- .../deploymentplan_federation_udp_two_hosts.cdp | 246 ------------- .../deploymentplan_multiple_senders.cdp | 395 --------------------- .../deploymentplan_with_filters.cdp | 278 --------------- .../examples/Hello/descriptors_events/rtec.conf | 1 - .../Hello/descriptors_events/run_NodeDaemons.pl | 40 --- .../descriptors_events/run_NodeDaemons_svc_conf.pl | 42 --- .../descriptors_events/run_NodeDaemons_with_ip.pl | 40 --- .../examples/Hello/descriptors_events/run_test.pl | 49 --- .../descriptors_events/run_test_collocated.pl | 12 - .../Hello/descriptors_events/run_test_federated.pl | 12 - .../Hello/descriptors_events/run_test_filtered.pl | 12 - .../Hello/descriptors_events/run_test_multicast.pl | 12 - .../run_test_multiple_senders.pl | 199 ----------- .../Hello/descriptors_events/run_test_simple.pl | 12 - .../Hello/descriptors_events/run_test_udp.pl | 12 - .../descriptors_events/run_test_udp_collocated.pl | 12 - .../deploymentplan.cdp | 224 ------------ .../deploymentplan_shared_components.cdp | 229 ------------ flat/CIAO/tools/Config_Handlers/XSCRT/Elements.hpp | 1 + flat/CIAO/tools/XML/XML_Helper.h | 2 + 75 files changed, 649 insertions(+), 5638 deletions(-) delete mode 100644 flat/CIAO/examples/Hello/ReDaC-Usage.html delete mode 100644 flat/CIAO/examples/Hello/descriptors/Hello.cid delete mode 100644 flat/CIAO/examples/Hello/descriptors/Hello.cpd delete mode 100644 flat/CIAO/examples/Hello/descriptors/Libraries.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver.ccd delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver.cid delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver.cpd delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver_Exec.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver_Stub.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Receiver_Svnt.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender.ccd delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender.cid delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender.cpd delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender_Exec.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender_Stub.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors/Sender_Svnt.iad delete mode 100644 flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_add.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_remove.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap.dat delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/NodeManagerMapTwoHosts.dat delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap_collocated.dat delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/README delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/RunEventTest.pm delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-collocated.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-federation.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-filters.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-example.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-mcast.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-collocated.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-two-hosts.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp.ced delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events_collocated.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_mcast.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_collocated.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_two_hosts.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_multiple_senders.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/deploymentplan_with_filters.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/rtec.conf delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_svc_conf.pl delete mode 100644 flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_with_ip.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_collocated.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_federated.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_filtered.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_multicast.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_multiple_senders.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_simple.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_udp.pl delete mode 100755 flat/CIAO/examples/Hello/descriptors_events/run_test_udp_collocated.pl delete mode 100644 flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan.cdp delete mode 100644 flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan_shared_components.cdp diff --git a/flat/CIAO/ChangeLog b/flat/CIAO/ChangeLog index de91a82817a..fea1902498c 100644 --- a/flat/CIAO/ChangeLog +++ b/flat/CIAO/ChangeLog @@ -1,3 +1,100 @@ +Sun Nov 23 23:59:50 UTC 2008 William R. Otte + + * DAnCE/Deployment/DAnCE_Properties.idl: + + Rearranged, organized + + * DAnCE/DomainApplicationManager/Node_Locator.h: + * DAnCE/DomainApplicationManager/Node_Locator.cpp: + * DAnCE/ExecutionManager/ExecutionManager_Module.h: + * DAnCE/ExecutionManager/ExecutionManager_Module.cpp: + * DAnCE/NodeApplication/NodeApplication.mpc: + * DAnCE/NodeApplication/NodeApplication_Impl.h: + * DAnCE/NodeApplication/NodeApplication_Impl.cpp: + * DAnCE/NodeManager/Node_Manager_Module.h: + * DAnCE/NodeManager/Node_Manager_Module.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp: + + Improved NameService support. + + * examples/Hello/Sender/Sender_exec.cpp: + * examples/Hello/descriptors/DeploymentPlan.cdp: + * examples/Hello/descriptors/run_test.pl: + + Updates to work with new DAnCE. + + * tools/Config_Handlers/XSCRT/Elements.hpp: + * tools/XML/XML_Helper.h: + + Compile fixes. + + * examples/Hello/ReDaC-Usage.html: + * examples/Hello/descriptors/Hello.cid: + * examples/Hello/descriptors/Hello.cpd: + * examples/Hello/descriptors/Libraries.iad: + * examples/Hello/descriptors/Receiver.ccd: + * examples/Hello/descriptors/Receiver.cid: + * examples/Hello/descriptors/Receiver.cpd: + * examples/Hello/descriptors/Receiver_Exec.iad: + * examples/Hello/descriptors/Receiver_Stub.iad: + * examples/Hello/descriptors/Receiver_Svnt.iad: + * examples/Hello/descriptors/Sender.ccd: + * examples/Hello/descriptors/Sender.cid: + * examples/Hello/descriptors/Sender.cpd: + * examples/Hello/descriptors/Sender_Exec.iad: + * examples/Hello/descriptors/Sender_Stub.iad: + * examples/Hello/descriptors/Sender_Svnt.iad: + * examples/Hello/descriptors_ReDaC: + * examples/Hello/descriptors_events: + * examples/Hello/descriptors_shared_components: + + Removed these files. + +Fri Nov 21 16:58:00 UTC 2008 William R. Otte + + * DAnCE/DomainApplicationManager/Node_Locator.cpp: + * DAnCE/ExecutionManager/ExecutionManager_Module.h: + * DAnCE/ExecutionManager/ExecutionManager_Module.cpp: + * DAnCE/NodeManager/Node_Manager_Module.h: + * DAnCE/NodeManager/Node_Manager_Module.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp: + * DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp: + + Better support for the naming service. + + * examples/Hello/descriptors/DeploymentPlan.cdp: + * examples/Hello/descriptors/run_test.pl: + + ported to new DAnCE. + + * examples/Hello/descriptors/Hello.cid: + * examples/Hello/descriptors/Hello.cpd: + * examples/Hello/descriptors/Libraries.iad: + * examples/Hello/descriptors/Receiver.ccd: + * examples/Hello/descriptors/Receiver.cid: + * examples/Hello/descriptors/Receiver.cpd: + * examples/Hello/descriptors/Receiver_Exec.iad: + * examples/Hello/descriptors/Receiver_Stub.iad: + * examples/Hello/descriptors/Receiver_Svnt.iad: + * examples/Hello/descriptors/Sender.ccd: + * examples/Hello/descriptors/Sender.cid: + * examples/Hello/descriptors/Sender.cpd: + * examples/Hello/descriptors/Sender_Exec.iad: + * examples/Hello/descriptors/Sender_Stub.iad: + * examples/Hello/descriptors/Sender_Svnt.iad: + + Removed superfluous files. + + * examples/Hello/descriptors_ReDaC: + * examples/Hello/descriptors_events: + * examples/Hello/descriptors_shared_components: + * examples/Hello/ReDaC-Usage.html: + + Removed these files, as these features are no longer supported. + Tue Nov 18 15:40:23 UTC 2008 Johnny Willemsen * CIDLC/Literals.cpp: diff --git a/flat/CIAO/DAnCE/Deployment/DAnCE_Properties.idl b/flat/CIAO/DAnCE/Deployment/DAnCE_Properties.idl index 72d702ea55a..a93fcdc40af 100644 --- a/flat/CIAO/DAnCE/Deployment/DAnCE_Properties.idl +++ b/flat/CIAO/DAnCE/Deployment/DAnCE_Properties.idl @@ -9,12 +9,35 @@ module DAnCE { + // Home Configuration Properties + /// Describes the entrypoint for the home executor. Property value is string. const string HOME_FACTORY = "home factory"; + + // Component Configuration Properties + /// Describes the entrypoint for the component executor. Property value is string. const string COMPONENT_FACTORY = "component factory"; + /// Indicates that the component instance should be deployed using specified home ID. + /// Property value is string. const string EXPLICIT_HOME = "edu.vanderbilt.dre.DAnCE.ExplicitHome"; - const string STANDALONE_NM = "edu.vanderbilt.dre.DAnCE.StandaloneNM"; + + // Instance (i.e., Home or Component) Properties + /// Indicates that the instance object reference should be registered in the + /// Instance naming context using a specified name. Property value is string. const string REGISTER_NAMING = "edu.vanderbilt.dre.DAnCE.RegisterNaming"; - const string COMPONENT_IOR_FILE = "edu.vanderbilt.dre.DAnCE.ComponentIOR"; - const string REGISTER_PORT_NAMING = "edu.vanderbilt.dre.DAnCE.RegisterPortNaming"; + /// Indicates that the instance object reference should be printed to a specifid + /// file. Property value is string. + const string INSTANCE_IOR_FILE = "edu.vanderbilt.dre.DAnCE.InstanceIOR"; + // const string REGISTER_PORT_NAMING = "edu.vanderbilt.dre.DAnCE.RegisterPortNaming"; + + // Node Infrastructure Configuration + /// Indicates that the NodeManager is running as a standalone entity. + const string STANDALONE_NM = "edu.vanderbilt.dre.DAnCE.StandaloneNM"; + /// Indicates the naming context for domain objects, which includes infrastructure + /// and redirection. + const string DOMAIN_NC = "edu.vanderbilt.dre.DAnCE.DomainNC"; + /// Indicates the naming context used for instance objects. + const string INSTANCE_NC = "edu.vanderbilt.dre.DAnCE.InstanceNC"; + + }; diff --git a/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.cpp b/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.cpp index 1d423c42508..2f01f5f92d6 100644 --- a/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.cpp +++ b/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.cpp @@ -8,7 +8,7 @@ namespace DAnCE { Node_Locator::Node_Locator (CORBA::ORB_ptr orb, - CosNaming::NamingContext_var nc) + CosNaming::NamingContext_ptr nc) : orb_ (CORBA::ORB::_duplicate (orb)), nc_ (CosNaming::NamingContext::_duplicate (nc)) { @@ -139,7 +139,8 @@ namespace DAnCE name.length (1); name[0].id = nodename; - + name[0].kind = ACE_TEXT("NodeManager"); + CORBA::Object_var obj = this->nc_->resolve (name); ::Deployment::NodeManager_var nm = ::Deployment::NodeManager::_narrow (obj.in ()); diff --git a/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.h b/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.h index cce7edc96be..f3255d0c230 100644 --- a/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.h +++ b/flat/CIAO/DAnCE/DomainApplicationManager/Node_Locator.h @@ -27,7 +27,7 @@ namespace DAnCE { public: Node_Locator (CORBA::ORB_ptr orb, - CosNaming::NamingContext_var nc); + CosNaming::NamingContext_ptr nc); ::Deployment::NodeManager_ptr locate_node (const ACE_TCHAR *name); diff --git a/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.cpp b/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.cpp index 4aa31b4a4a4..5bd905c117f 100644 --- a/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.cpp +++ b/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.cpp @@ -33,17 +33,17 @@ namespace DAnCE if (ior_output_file_) { ACE_OS::fprintf (ior_output_file_, - "%s", + "%C", ior); ACE_OS::fclose (ior_output_file_); - DANCE_DEBUG ( (LM_TRACE, "[%M] EM's ior was written into file \"%s\"\n", ior_file_name)); + DANCE_DEBUG ( (LM_TRACE, "[%M] EM's ior was written into file \"%C\"\n", ior_file_name)); return true; } else { DANCE_ERROR ( (LM_ERROR, "[%M] DAnCE_ExecutionManager::write_ior-file - " - "Unable to open ExecutionManager IOR output file %s : %m\n", + "Unable to open ExecutionManager IOR output file %C : %m\n", ior_file_name)); return false; } @@ -83,6 +83,7 @@ DAnCE_ExecutionManager_Module::parse_args (int argc, char *argv[]) get_opts.long_option ("ignore-failure", 'f', ACE_Get_Opt::NO_ARG); get_opts.long_option ("help", 'h', ACE_Get_Opt::NO_ARG); get_opts.long_option ("node-map", ACE_Get_Opt::ARG_REQUIRED); + get_opts.long_option ("domain-nc", ACE_Get_Opt::ARG_REQUIRED); //get_opts.long_option ("help", '?'); @@ -93,7 +94,7 @@ DAnCE_ExecutionManager_Module::parse_args (int argc, char *argv[]) { case 'e': DANCE_DEBUG ((LM_TRACE, DLINFO "DAnCE_ExecutionManager_Module::parse_args - " - "Output filename is %s\n", + "Output filename is %C\n", get_opts.opt_arg ())); this->options_.exec_mgr_file_ = get_opts.opt_arg (); break; @@ -141,20 +142,31 @@ DAnCE_ExecutionManager_Module::parse_args (int argc, char *argv[]) "node-map") == 0) { DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Found Node map filename %s.\n", + "Found Node map filename %C.\n", get_opts.opt_arg ())); this->options_.node_map_ = get_opts.opt_arg (); break; } + else if (ACE_OS::strcmp (get_opts.long_option (), + "domain-nc") == 0) + { + DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " + "Binding to domain naming context %C.\n", + get_opts.opt_arg ())); + this->options_.domain_nc_ = get_opts.opt_arg (); + break; + } + case 'h': //case '?': // Display help for use of the server. //default: DANCE_ERROR_RETURN ((LM_ERROR, - "usage: %s\n" + "usage: %C\n" "\t--exec-mgr,-e [execution manager ior file name]\n" "\t--node-mgr,-n [=node manager ior file name]\n" "\t--node-map \t\tFile containing a node manager map\n" + "\t--domain-nc \t\tIOR for the Domain Naming Context\n" //"--process-ns,-p [file name] \t\tcreate process name service and store its ior to file name\n" //"--create-plan-ns,-c [NC] \t\tcreate plan objects (components and ports) representation in name context with ior NC\n" //"--rebind-plan-ns,-r [NC] \t\tbind plan representation name context to NC\n" @@ -228,20 +240,24 @@ DAnCE_ExecutionManager_Module::create_object (CORBA::ORB_ptr orb, } CosNaming::NamingContext_var domain_nc; - /* + // Resolve DomainNC - DANCE_DEBUG ((LM_TRACE, DLINFO "DAnCE_ExecutionManager_Module::create_object - before resolving \"DomainNC\".\n")); try { - CORBA::Object_var domain_obj = orb->resolve_initial_references ("DomainNC"); - if (!CORBA::is_nil (domain_obj.in ())) + if (this->options_.domain_nc_) { - domain_nc = CosNaming::NamingContext::_narrow (domain_obj.in()); - if (CORBA::is_nil (domain_nc.in ())) + DANCE_DEBUG ((LM_TRACE, DLINFO "DAnCE_ExecutionManager_Module::create_object - " + "before resolving \"DomainNC\".\n")); + CORBA::Object_var domain_obj = orb->string_to_object (this->options_.domain_nc_); + if (!CORBA::is_nil (domain_obj.in ())) { - DANCE_ERROR ( (LM_ERROR, - DLINFO "Narrow to NamingContext return nil for DomainNC.\n")); - return CORBA::Object::_nil (); + domain_nc = CosNaming::NamingContext::_narrow (domain_obj.in()); + if (CORBA::is_nil (domain_nc.in ())) + { + DANCE_ERROR ( (LM_ERROR, + DLINFO "Narrow to NamingContext return nil for DomainNC.\n")); + return CORBA::Object::_nil (); + } } } } @@ -250,7 +266,7 @@ DAnCE_ExecutionManager_Module::create_object (CORBA::ORB_ptr orb, DANCE_DEBUG ((LM_DEBUG, DLINFO "DomainNC context not found!\n")); } - */ + // Initialize IOR table CORBA::Object_var table_object = orb->resolve_initial_references ("IORTable"); @@ -331,19 +347,19 @@ DAnCE_ExecutionManager_Module::create_object (CORBA::ORB_ptr orb, if (CORBA::is_nil (nm_obj)) { DANCE_ERROR ((LM_ERROR, DLINFO "DAnCE_ExecutionManager::create_object - " - "Failed to narrow the object to node manager : %s\n", + "Failed to narrow the object to node manager : %C\n", this->options_.node_managers_[i].c_str())); continue; } */ - DANCE_DEBUG ((LM_TRACE, DLINFO "Placing node \"%s\" to EM's map.\n", node_name.c_str())); + DANCE_DEBUG ((LM_TRACE, DLINFO "Placing node \"%C\" to EM's map.\n", node_name.c_str())); this->em_impl_->add_node_manager (node_name.c_str(), nm_ior.c_str ()); } if (this->options_.node_map_ != 0) { DANCE_DEBUG ((LM_TRACE, DLINFO "DAnCE_ExecutionManager_Module::create_object - " - "Parsing node map %s\n", + "Parsing node map %C\n", this->options_.node_map_)); this->em_impl_->load_node_map (this->options_.node_map_); } diff --git a/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.h b/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.h index 61bd4173a04..afcc24b0027 100644 --- a/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.h +++ b/flat/CIAO/DAnCE/ExecutionManager/ExecutionManager_Module.h @@ -57,7 +57,8 @@ class DAnCE_ExecutionManager_Module_Export DAnCE_ExecutionManager_Module ACE_Vector node_managers_; bool ignore_failure_; const char *node_map_; - + const char *domain_nc_; + SOptions() : exec_mgr_file_ (0), process_ns_ (false), @@ -67,7 +68,8 @@ class DAnCE_ExecutionManager_Module_Export DAnCE_ExecutionManager_Module rebind_plan_ns_ (false), rebind_plan_ns_ior_ (0), ignore_failure_ (false), - node_map_(0) + node_map_(0), + domain_nc_ (0) { } }; diff --git a/flat/CIAO/DAnCE/NodeApplication/NodeApplication.mpc b/flat/CIAO/DAnCE/NodeApplication/NodeApplication.mpc index 54bf30b1a3f..434fde90a61 100644 --- a/flat/CIAO/DAnCE/NodeApplication/NodeApplication.mpc +++ b/flat/CIAO/DAnCE/NodeApplication/NodeApplication.mpc @@ -13,12 +13,14 @@ project(NodeApplication): dance_lib, dynamicinterface, dance_component_server_sv // ServerActivator_Impl.cpp NodeApplication_Impl.cpp ComponentAttributesSetter.cpp + Name_Utilities.cpp } Header_Files { // ComponentInstallation_Impl.h // ServerActivator_Impl.h NodeApplication_Impl.h ComponentAttributesSetter.h + Name_Utilities.h } } diff --git a/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.cpp b/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.cpp index 8aeea7d7f96..1e83c30934d 100644 --- a/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.cpp +++ b/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.cpp @@ -18,6 +18,8 @@ #include "Deployment/Deployment_common.h" #include "Deployment/DAnCE_PropertiesC.h" #include "ComponentAttributesSetter.h" +#include "Name_Utilities.h" + //#include "ComponentInstallation_Impl.h" #ifdef GEN_OSTREAM_OPS @@ -39,14 +41,17 @@ namespace name)); if (properties.find (name, any) == 0) - if (any >>= val) - return true; - else - { - DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " - "Failed to extract property value for %s\n", name)); - return false; - } + { + if (any >>= val) + return true; + else + { + DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " + "Failed to extract property value for %s\n", name)); + return false; + } + } + DANCE_DEBUG ((LM_TRACE, DLINFO "NodeApplicion::::get_property_value - " "Property value for name '%s' has no value\n", name)); @@ -64,15 +69,17 @@ namespace name)); if (properties.find (name, any) == 0) - if (any >>= CORBA::Any::to_boolean(val)) - return true; - else - { - DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " - "Failed to extract property value for %s\n", name)); - return false; - } - + { + if (any >>= CORBA::Any::to_boolean(val)) + return true; + else + { + DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " + "Failed to extract property value for %s\n", name)); + return false; + } + } + DANCE_DEBUG ((LM_TRACE, DLINFO "NodeApplicion::::get_property_value - " "Property value for name '%s' has no value\n", name)); @@ -90,14 +97,16 @@ namespace name)); if (properties.find (name, any) == 0) - if (any >>= CORBA::Any::to_string(val, 0)) - return true; - else - { - DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " - "Failed to extract property value for %s\n", name)); - return false; - } + { + if (any >>= CORBA::Any::to_string(val, 0)) + return true; + else + { + DANCE_ERROR ((LM_WARNING, DLINFO "NodeApplicion::::get_property_value - " + "Failed to extract property value for %s\n", name)); + return false; + } + } DANCE_DEBUG ((LM_TRACE, DLINFO "NodeApplicion::::get_property_value - " "Property value for name '%s' has no value\n", name)); @@ -321,7 +330,7 @@ NodeApplication_Impl::init() get_property_value (CIAO::Deployment::SERVER_MULTITHREAD, this->properties_, multithread); DANCE_DEBUG ((LM_DEBUG, DLINFO "NodeApplication_Impl::init - " "Threading: %s\n", multithread ? "Multi" : "Single")); - + DANCE_DEBUG ((LM_TRACE, DLINFO "NodeApplication_Impl::init - " "Spawning server activator\n")); @@ -341,6 +350,28 @@ NodeApplication_Impl::init() this->poa_->activate_object (this->activator_.get ()); DANCE_DEBUG((LM_TRACE, DLINFO "NodeApplication_impl::init - ServerActivator object created\n")); + + const ACE_TCHAR *ior; + + if (get_property_value (DAnCE::INSTANCE_NC, this->properties_, ior) || + get_property_value (DAnCE::DOMAIN_NC, this->properties_, ior)) + { + try + { + CORBA::Object_var obj = this->orb_->string_to_object (ior); + this->instance_nc_ = CosNaming::NamingContext::_narrow (obj); + } + catch (CORBA::Exception &e) + { + DANCE_ERROR ((LM_ERROR, DLINFO "NodeApplication_impl::init - " + "Unable to resolve the instance naming context:%C\n", + e._info ().c_str ())); + } + DANCE_DEBUG ((LM_DEBUG, DLINFO "NodeApplication_impl::init - " + "Successfully resolved the instance naming context.\n")); + } + else DANCE_DEBUG ((LM_DEBUG, DLINFO "NodeApplication_impl::init - " + "No instance NC was provided\n")); } void @@ -821,10 +852,38 @@ NodeApplication_Impl::create_component_server (size_t index) } } +void +NodeApplication_Impl::store_instance_ior (Instance &inst) +{ + DANCE_TRACE ("NodeApplication_impl::store_instance_ior"); + + const char *name = 0; + + if (get_property_value (DAnCE::REGISTER_NAMING, + this->plan_.instance[inst.idd_idx].configProperty, + name)) + { + DANCE_DEBUG ((LM_DEBUG, DLINFO "NodeApplication_impl::store_instance_ior - " + "Storing instance '%C' object reference in Naming Service as %C", + this->plan_.instance[inst.idd_idx].name.in (), + name)); + + Name_Utilities::bind_object (name, inst.ref.in (), this->instance_nc_.in ()); + } + + if (get_property_value (DAnCE::INSTANCE_IOR_FILE, + this->plan_.instance[inst.idd_idx].configProperty, + name)) + { + CORBA::String_var ior = this->orb_->object_to_string (inst.ref.in ()); + Name_Utilities::write_ior (name, ior.in ()); + } +} + void NodeApplication_Impl::create_container (size_t server, size_t cont_idx) { - DANCE_TRACE ("NodeApplication_impl::create_container - started"); + DANCE_TRACE ("NodeApplication_impl::create_container"); Container &container = this->servers_[server].containers[cont_idx]; @@ -844,6 +903,7 @@ NodeApplication_Impl::create_container (size_t server, size_t cont_idx) for (size_t i = 0; i < container.homes.size (); ++i) { this->install_home (container, container.homes[i]); + this->store_instance_ior (container.homes[i]); } DANCE_DEBUG ((LM_TRACE, DLINFO "NodeApplication_impl::create_container - " @@ -865,6 +925,7 @@ NodeApplication_Impl::create_container (size_t server, size_t cont_idx) default: break; } + this->store_instance_ior (container.components[i]); } } diff --git a/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.h b/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.h index 2b89b501928..32199a4d9e8 100644 --- a/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.h +++ b/flat/CIAO/DAnCE/NodeApplication/NodeApplication_Impl.h @@ -164,7 +164,9 @@ namespace DAnCE void install_component (Container &cont, Instance &inst); void install_homed_component (Container &cont, Instance &inst); - + + void store_instance_ior (Instance &inst); + Components::Cookie* connect_receptacle (Components::CCMObject_ptr inst, const ACE_CString& port_name, CORBA::Object_ptr facet); @@ -203,6 +205,8 @@ namespace DAnCE COMPONENTSERVERS servers_; INSTANCE_PTRS instances_; + + CosNaming::NamingContext_var instance_nc_; }; }; #endif /*NODEAPPLICATION_IMPL_H_*/ diff --git a/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.cpp b/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.cpp index 8d6e458dd9e..b57a94faf1f 100644 --- a/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.cpp +++ b/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.cpp @@ -36,7 +36,7 @@ namespace DAnCE if (ior_output_file_) { ACE_OS::fprintf (ior_output_file_, - "%s", + "%C", ior); ACE_OS::fclose (ior_output_file_); return true; @@ -73,15 +73,17 @@ DAnCE_NodeManager_Module::usage (void) return "Node Manager Options:\n" "\t-e,--exec-mgr\t\t\t [execution manager ior file name]\n" "\t-n,--node-mgr\t\t\t [=node manager ior file name]\n" - "\t-p,--process-ns\t\t\t [file name] create process name service and store its ior to file name\n" - "\t-c,--create-plan-ns\t\t [NC] create plan objects (components and ports) representation in name context with ior NC\n" - "\t-r,--rebind-plan-ns\t\t [NC] bind plan representation name context to NC\n" + // "\t-p,--process-ns\t\t\t [file name] create process name service and store its ior to file name\n" + "\t-c,--create-plan-ns [NC]\t\t create plan objects (components and ports) representation in name context with ior NC\n" + "\t-r,--rebind-plan-ns [NC]\t\t bind plan representation name context to NC\n" "\t-i,--port-indirection\t\t enable plan objects indirection via servant locator\n" - "\t-f,--ignore-failure\t\t ignore deployment failures\n" + //"\t-f,--ignore-failure\t\t ignore deployment failures\n" "\t-s,--server-executable\t\t default component server executable\n" "\t--server-args\t\t additional arguments to supply to the component server\n" "\t--standalone-nm\t\t Indicates that this NodeManager is not managed by an ExecutionManager\n" "\t-t,--timeout\t\t\t default timeout in seconds to wait for component server spawn\n" + "\t-d,--domain-nc [NC]\t\t\t Default naming context for domain objects.\n" + "\t--instance-nc [NC]\t\t\t Default naming context for instance registration directives. No argument indicates Domain NC.\n" "\t-h,help\t\t\t\t print this help message\n"; } @@ -106,7 +108,10 @@ DAnCE_NodeManager_Module::parse_args (int argc, ACE_TCHAR * argv[]) get_opts.long_option (ACE_TEXT("server-args"), ACE_Get_Opt::ARG_REQUIRED); get_opts.long_option (ACE_TEXT("standalone-nm"), ACE_Get_Opt::NO_ARG); get_opts.long_option (ACE_TEXT("timeout"), 't', ACE_Get_Opt::ARG_REQUIRED); + get_opts.long_option (ACE_TEXT("domain-nc"), 'd', ACE_Get_Opt::ARG_REQUIRED); get_opts.long_option (ACE_TEXT("help"), 'h', ACE_Get_Opt::NO_ARG); + get_opts.long_option (ACE_TEXT("instance-nc"), ACE_Get_Opt::ARG_OPTIONAL); + //get_opts.long_option ("help", '?'); char c; @@ -116,27 +121,27 @@ DAnCE_NodeManager_Module::parse_args (int argc, ACE_TCHAR * argv[]) { case 'n': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Provided Node Manager name: %s\n", get_opts.opt_arg ())); + "Provided Node Manager name: %C\n", get_opts.opt_arg ())); this->options_.node_managers_.push_back (get_opts.opt_arg ()); break; case 'p': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Instructed to create process ns with file %s\n", get_opts.opt_arg ())); + "Instructed to create process ns with file %C\n", get_opts.opt_arg ())); this->options_.process_ns_ = true; this->options_.process_ns_file_ = get_opts.opt_arg (); break; case 'c': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Instructed to create plan NS in context: %s\n", get_opts.opt_arg ())); + "Instructed to create plan NS in context: %C\n", get_opts.opt_arg ())); this->options_.create_plan_ns_ = true; this->options_.create_plan_ns_ior_ = get_opts.opt_arg (); break; case 'r': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Instructed to rebind plan NS in context: %s\n", get_opts.opt_arg ())); + "Instructed to rebind plan NS in context: %C\n", get_opts.opt_arg ())); this->options_.rebind_plan_ns_ = true; this->options_.rebind_plan_ns_ior_ = get_opts.opt_arg (); break; @@ -155,18 +160,25 @@ DAnCE_NodeManager_Module::parse_args (int argc, ACE_TCHAR * argv[]) case 's': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Using provided component server executable:%s\n", + "Using provided component server executable:%C\n", get_opts.opt_arg ())); this->options_.cs_path_ = get_opts.opt_arg (); break; case 't': DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Using provided component server spawn timeout:%s\n", + "Using provided component server spawn timeout:%C\n", get_opts.opt_arg ())); this->options_.timeout_ = ACE_OS::atoi (get_opts.opt_arg ()); break; - + + case 'd': + DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " + "Binding to provided Domain Naming Context: '%C'\n", + get_opts.opt_arg ())); + this->options_.domain_nc_ = get_opts.opt_arg (); + break; + case 'h': //case '?': // Display help for use of the server. //default: @@ -187,14 +199,44 @@ DAnCE_NodeManager_Module::parse_args (int argc, ACE_TCHAR * argv[]) "server-args") == 0) { DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " - "Using provided compoent server arguments: '%s'\n", + "Using provided compoent server arguments: '%C'\n", get_opts.opt_arg ())); this->options_.server_args_ = get_opts.opt_arg (); } + else if (ACE_OS::strcmp (get_opts.long_option (), + "instance-nc")) + { + if (get_opts.opt_arg () == 0) + { + if (this->options_.domain_nc_ == 0) + { + DANCE_ERROR ((LM_ERROR, DLINFO "Node_Manager_Module::parse_args - " + "ERROR: instance-nc provided no argument, but domain-nc did not appear before.\n")); + DANCE_ERROR_RETURN ((LM_ERROR, this->usage (), argv[0], c), false); + } + DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " + "Instance NC defaulting to Domain NC\n")); + this->options_.instance_nc_ = this->options_.domain_nc_; + } + else + { + DANCE_DEBUG ((LM_DEBUG, DLINFO "Node_Manager_Module::parse_args - " + "Using provided instance NC: %C\n", + get_opts.opt_arg ())); + this->options_.instance_nc_ = get_opts.opt_arg (); + } + } + else + { + DANCE_ERROR ((LM_ERROR, DLINFO "Node_Manager_Module::parse_args - " + "ERROR: unknown long option %C\n", + get_opts.long_option ())); + } + break; default: - DANCE_DEBUG ((LM_TRACE, DLINFO "Node_Manager_Module::parse_args - ignoring unknown option %c\n", + DANCE_DEBUG ((LM_TRACE, DLINFO "Node_Manager_Module::parse_args - ignoring unknown option %i\n", c)); } } @@ -274,15 +316,13 @@ DAnCE_NodeManager_Module::create_object (CORBA::ORB_ptr orb, this->register_value_factories (); this->create_poas (); - // Resolve DomainNC - if (CORBA::is_nil(this->orb_.in())) + if (this->options_.domain_nc_) { try { DANCE_DEBUG((LM_TRACE, DLINFO "DAnCE_NodeManager_Module::create_object - " - "Setting NM's orb and resolving DomainNC.\n")); - this->orb_ = CORBA::ORB::_duplicate(orb); - CORBA::Object_var domain_obj = orb->resolve_initial_references ("DomainNC"); + "Resolving DomainNC.\n")); + CORBA::Object_var domain_obj = this->orb_->string_to_object (this->options_.domain_nc_); if (!CORBA::is_nil (domain_obj.in ())) { this->domain_nc_ = CosNaming::NamingContext::_narrow (domain_obj.in()); @@ -440,7 +480,7 @@ DAnCE_NodeManager_Module::create_object (CORBA::ORB_ptr orb, } DANCE_DEBUG ((LM_INFO, DLINFO "DAnCE_NodeManager_Module::create_object - " - "Creating node named '%s' and outputting ior to file '%s'\n", + "Creating node named '%C' and outputting ior to file '%C'\n", node_name.c_str (), node_file.c_str ())); @@ -484,7 +524,7 @@ DAnCE_NodeManager_Module::create_object (CORBA::ORB_ptr orb, if (!CORBA::is_nil (this->domain_nc_.in ())) { DANCE_DEBUG((LM_TRACE, DLINFO "DAnCE_NodeManager_Module::create_object - " - "Registering NM in NC as \"%s.NodeManager\".\n", node_name.c_str ())); + "Registering NM in NC as \"%C.NodeManager\".\n", node_name.c_str ())); CosNaming::Name name (1); name.length (1); name[0].id = CORBA::string_dup (node_name.c_str ()); @@ -590,6 +630,18 @@ DAnCE_NodeManager_Module::create_nm_properties (DAnCE::PROPERTY_MAP &props) val <<= CORBA::Any::from_string (CORBA::string_dup (this->options_.server_args_),0); props.bind (CIAO::Deployment::SERVER_ARGUMENTS, val); } + if (this->options_.instance_nc_) + { + CORBA::Any val; + val <<= CORBA::Any::from_string (CORBA::string_dup (this->options_.instance_nc_), 0); + props.bind (DAnCE::INSTANCE_NC, val); + } + if (this->options_.domain_nc_) + { + CORBA::Any val; + val <<= CORBA::Any::from_string (CORBA::string_dup (this->options_.domain_nc_), 0); + props.bind (DAnCE::DOMAIN_NC, val); + } } #ifndef BUILD_NODE_MANAGER_EXE diff --git a/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.h b/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.h index 17d23077ee9..97487f15328 100644 --- a/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.h +++ b/flat/CIAO/DAnCE/NodeManager/Node_Manager_Module.h @@ -68,7 +68,9 @@ class DAnCE_NodeManager_Module_Export DAnCE_NodeManager_Module unsigned int timeout_; CORBA::Boolean standalone_; const char * server_args_; - + const char * domain_nc_; + const char * instance_nc_; + SOptions() : process_ns_ (false), process_ns_file_ (0), @@ -80,7 +82,9 @@ class DAnCE_NodeManager_Module_Export DAnCE_NodeManager_Module cs_path_ (0), timeout_ (5), standalone_ (false), - server_args_ (0) + server_args_ (0), + domain_nc_ (0), + instance_nc_ (0) { } }; diff --git a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp index 78d46e8416c..589546bf0fd 100644 --- a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp +++ b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl.cpp @@ -20,16 +20,17 @@ Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl(CORBA::ORB_ptr orb, int argc, em_(DAnCE::ExecutionManagerDaemon::_nil()), em_ior_("file://em.ior") //default , mode_(0x0) { - DANCE_DEBUG ( (LM_TRACE, "[%M] Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - Starting.\n")); + DANCE_TRACE ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl"); if (CORBA::is_nil (this->orb_)) { - DANCE_DEBUG ( (LM_INFO, "[%M] Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - Creating internal ORB.\n")); + DANCE_DEBUG ((LM_INFO, DLINFO "Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "Creating internal ORB.\n")); this->orb_ = CORBA::ORB_init (argc, argv, ""); } this->parse_args(argc, argv); - DANCE_DEBUG ( (LM_TRACE, "[%M] Plan_Launcher_i::init - em_ior = \"%s\"\n" - , is_empty (this->em_ior_) ? "NULL" : this->em_ior_.c_str())); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_i::init - em_ior = \"%s\"\n" + , is_empty (this->em_ior_) ? "NULL" : this->em_ior_.c_str())); if (this->mode_ & (MODE_START_PLAN | MODE_STOP_PLAN)) { @@ -39,8 +40,10 @@ Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl(CORBA::ORB_ptr orb, int argc, obj = this->orb_->string_to_object(this->em_ior_.c_str()); if (CORBA::is_nil(obj)) { - DANCE_ERROR((LM_ERROR, "[%M] Failed to retrieve EM object from \"%s\"\n", this->em_ior_.c_str())); - throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - failed to retrieve EM object"); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "Failed to retrieve EM object from \"%s\"\n", this->em_ior_.c_str())); + throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "failed to retrieve EM object"); } } try @@ -49,19 +52,22 @@ Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl(CORBA::ORB_ptr orb, int argc, } catch(CORBA::Exception&) { - DANCE_ERROR((LM_ERROR, "[%M] Failed to retrieve EM object from \"%s\"\n", this->em_ior_.c_str())); - throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - failed to retrieve EM object"); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "Failed to retrieve EM object from \"%s\"\n", this->em_ior_.c_str())); + throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "failed to retrieve EM object"); } if (CORBA::is_nil (this->em_.in())) { - DANCE_ERROR ( (LM_ERROR, "[%M] Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - failed to get an execution manager.\n")); - throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - failed to get an execution manager"); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "failed to get an execution manager.\n")); + throw Deployment_Failure ("Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "failed to get an execution manager"); } } - DANCE_DEBUG ( (LM_TRACE, "[%M] Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - Obtained Execution Manager ref \n")); - - DANCE_DEBUG ( (LM_TRACE, "[%M] Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - Completed.\n")); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::Plan_Launcher_Base_Impl - " + "Obtained Execution Manager ref \n")); } Plan_Launcher_Base_Impl::~Plan_Launcher_Base_Impl() @@ -70,21 +76,26 @@ Plan_Launcher_Base_Impl::~Plan_Launcher_Base_Impl() void Plan_Launcher_Base_Impl::execute() { + DANCE_TRACE ("Plan_Launcher_Base_Impl::execute - "); + if (this->mode_ & MODE_START_PLAN) { size_t sz = this->cdr_plan_urls_.size(); for (size_t i= 0; i < sz; ++i) { - DANCE_DEBUG ( (LM_TRACE, "[%M] execute - launching plan \"%s\"...\n", this->cdr_plan_urls_[i].c_str())); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::execute - " + "launching plan \"%s\"...\n", this->cdr_plan_urls_[i].c_str())); ::Deployment::DeploymentPlan_var plan = this->read_cdr_plan_file(this->cdr_plan_urls_[i].c_str()); try { CORBA::String_var uuid = this->launch_plan (plan.in()); if (0 == uuid.in ()) { - throw Deployment_Failure ("execute - Error launching plan\n"); + throw Deployment_Failure ("Plan_Launcher_Base_Impl::execute - " + "Error launching plan\n"); } - DANCE_DEBUG ( (LM_DEBUG, "[%M] execute - returned plan UUID is \"%s\"\n", uuid.in ())); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::execute - " + "returned plan UUID is \"%s\"\n", uuid.in ())); } catch (...) { @@ -99,21 +110,23 @@ void Plan_Launcher_Base_Impl::execute() } } -const char *Plan_Launcher_Base_Impl::launch_plan( - const ::Deployment::DeploymentPlan &plan) +const char * +Plan_Launcher_Base_Impl::launch_plan(const ::Deployment::DeploymentPlan &plan) { + DANCE_TRACE ("Plan_Launcher_Base_Impl::launch_plan"); + try { - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - Starting...\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - Starting...\n")); if (CORBA::is_nil (this->em_.in ())) { - DANCE_ERROR ( (LM_ERROR, ACE_TEXT ("launch_plan - ") + DANCE_ERROR ( (LM_ERROR, DLINFO ACE_TEXT ("Plan_Launcher_Base_Impl::launch_plan - ") ACE_TEXT ("launch_plan called witn an uninitialized EM.\n"))); return 0; } - DANCE_DEBUG ( (LM_DEBUG, - ACE_TEXT ("[%M] launch_plan - ") + DANCE_DEBUG ( (LM_DEBUG, DLINFO + ACE_TEXT ("Plan_Launcher_Base_Impl::launch_plan - ") ACE_TEXT ("about to call this->em_->preparePlan\n"))); ::Deployment::DomainApplicationManager_var dam; @@ -123,35 +136,40 @@ const char *Plan_Launcher_Base_Impl::launch_plan( } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] launch_plan - An exception was thrown during EM->preparePlan.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "An exception was thrown during EM->preparePlan.\n")); throw; } - DANCE_DEBUG ( (LM_DEBUG, - ACE_TEXT ("[%M] launch_plan - ") + DANCE_DEBUG ( (LM_DEBUG, DLINFO + ACE_TEXT ("Plan_Launcher_Base_Impl::launch_plan - ") ACE_TEXT ("after to call this->em_->preparePlan\n"))); if (CORBA::is_nil (dam.in ())) { - DANCE_ERROR ( (LM_ERROR, "[%M] launch_plan - CIAO_PlanLauncher:preparePlan call failed: " - "nil DomainApplicationManager reference\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "CIAO_PlanLauncher:preparePlan call failed: " + "nil DomainApplicationManager reference\n")); return 0; } else { - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - DAM was received from preparePlan.\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "DAM was received from preparePlan.\n")); } this->write_dam_ior (dam.in()); - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - Obtained DAM ref \n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "Obtained DAM ref \n")); ::Deployment::Properties_var properties; ACE_NEW_RETURN (properties, Deployment::Properties, 0); - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - before startLaunch...\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "before startLaunch...\n")); ::Deployment::Connections_var conns; Deployment::Application_var da; @@ -161,42 +179,50 @@ const char *Plan_Launcher_Base_Impl::launch_plan( } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] launch_plan - An exception was thrown during DAM->startLaunch.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "An exception was thrown during DAM->startLaunch.\n")); throw; } //Deployment::DomainApplication_var da = Deployment::DomainApplication::_narrow(obj) if (CORBA::is_nil (da.in())) { - DANCE_ERROR ( (LM_ERROR, "[%M] launch_plan - CIAO_PlanLauncher:startLaunch call failed: " + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "CIAO_PlanLauncher:startLaunch call failed: " "nil DomainApplication reference\n")); return 0; } else { - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - DomainApplication was received from startLaunch\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "DomainApplication was received from startLaunch\n")); } //this is temporal workaround while cdmw checks object type in connect call - DANCE_DEBUG ( (LM_DEBUG, "[%M] Press any key after deployment on other node finished\n")); + /* + DANCE_DEBUG ((LM_DEBUG, DLINFO "Press any key after deployment on other node finished\n")); getchar(); - + */ this->create_external_connections (plan, conns.inout()); // Call finish Launch to complete the connections - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - before finishLaunch\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "before finishLaunch\n")); try { da->finishLaunch (conns.in(), false); // is_ReDAC by default is } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] launch_plan - An exception was thrown during DA->finishLaunch.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "An exception was thrown during DA->finishLaunch.\n")); throw; } - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - after finishLaunch\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "after finishLaunch\n")); // Call start to activate components - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - before start activating components...\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "before start activating components...\n")); try { @@ -204,20 +230,21 @@ const char *Plan_Launcher_Base_Impl::launch_plan( } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] launch_plan - An exception was thrown during DA->start.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::launch_plan - " + "An exception was thrown during DA->start.\n")); throw; } - DANCE_DEBUG ( (LM_DEBUG, "[%M] launch_plan - [success]\n")); - DANCE_DEBUG ( (LM_DEBUG, - ACE_TEXT ("[%M] Plan_Launcher_i::launch_plan - ") + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::launch_plan - [success]\n")); + DANCE_DEBUG ( (LM_DEBUG, DLINFO + ACE_TEXT ("[%M] Plan_Launcher_Base_Impl::launch_plan - ") ACE_TEXT ("Application Deployed successfully\n"))); } catch (const Deployment::ResourceNotAvailable& ex) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - EXCEPTION: ResourceNotAvaiable exception caught: %s,\n" + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - EXCEPTION: ResourceNotAvaiable exception caught: %s,\n" "Type: %s\n" "Property: %s\n" "Element: %s\n" @@ -227,49 +254,49 @@ const char *Plan_Launcher_Base_Impl::launch_plan( ex.propertyName.in (), ex.elementName.in (), ex.resourceName.in ()); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } catch (const Deployment::StartError& ex) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - EXCEPTION: StartError exception caught: %s, %s\n", + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - EXCEPTION: StartError exception caught: %s, %s\n", ex.name.in (), ex.reason.in ()); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } catch (const Deployment::InvalidProperty& ex) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - EXCEPTION: InvalidProperty exception caught: %s, %s\n", + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - EXCEPTION: InvalidProperty exception caught: %s, %s\n", ex.name.in (), ex.reason.in ()); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } catch (const Deployment::InvalidConnection& ex) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - EXCEPTION: InvalidConnection exception caught: %s, %s\n", + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - EXCEPTION: InvalidConnection exception caught: %s, %s\n", ex.name.in (), ex.reason.in ()); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } catch (const CORBA::Exception& ex) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - CORBA EXCEPTION: %s\n", + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - CORBA EXCEPTION: %s\n", ex._info().fast_rep()); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } catch (...) { char buf[1024]; - ACE_OS::sprintf (buf, "Plan_Launcher_i::launch_plan - EXCEPTION: non-CORBA exception\n"); - DANCE_ERROR ( (LM_ERROR, "[%M] %s", buf)); + ACE_OS::sprintf (buf, "Plan_Launcher_Base_Impl::launch_plan - EXCEPTION: non-CORBA exception\n"); + DANCE_ERROR ((LM_ERROR, DLINFO "%s", buf)); throw Deployment_Failure (buf); } @@ -278,15 +305,18 @@ const char *Plan_Launcher_Base_Impl::launch_plan( bool Plan_Launcher_Base_Impl::teardown_plan(const char *uuid) { + DANCE_TRACE ("Plan_Launcher_Base_Impl::teardown_plan"); + try { - DANCE_DEBUG ( (LM_DEBUG, "[%M] teardown_plan - looking for uuid=\"%s\"\n", uuid)); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::teardown_plan - looking for uuid=\"%s\"\n", uuid)); ::Deployment::DomainApplicationManagers_var mgrs = this->em_->getManagers(); ::Deployment::DomainApplicationManager_var dapp_mgr; for (size_t i = 0; i < mgrs->length(); ++i) { ACE_CString s = (*mgrs) [i]->getPlan()->UUID.in(); - DANCE_DEBUG ( (LM_DEBUG, "[%M] teardown_plan - comparing with existing uuid=\"%s\"\n", s.c_str())); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::teardown_plan - " + "comparing with existing uuid=\"%s\"\n", s.c_str())); if (s == uuid) { dapp_mgr = ::Deployment::DomainApplicationManager::_duplicate ( (*mgrs) [i].in()); @@ -307,23 +337,25 @@ bool Plan_Launcher_Base_Impl::teardown_plan(const char *uuid) { // @todo the destroy_dam_by_plan could give a stoperror exception // we should handle - DANCE_ERROR ( (LM_ERROR, "[%M] Unable to find DomainApplicationManager " - "for plan with uuid: %s\n", uuid)); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::teardown_plan - " + "Unable to find DomainApplicationManager " + "for plan with uuid: %s\n", uuid)); return false; } return true; } -void Plan_Launcher_Base_Impl::teardown_plan( - ::Deployment::DomainApplicationManager_ptr dam) +void +Plan_Launcher_Base_Impl::teardown_plan(::Deployment::DomainApplicationManager_ptr dam) { - DANCE_DEBUG ( (LM_DEBUG, - "[%M] Plan_Launcher_Base_Impl::teardown_plan - destroy the application.....\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO + "Plan_Launcher_Base_Impl::teardown_plan - destroy the application.....\n")); ::Deployment::Applications_var apps = dam->getApplications(); if (0 == apps->length()) { - DANCE_DEBUG((LM_ERROR, "[%M] Plan_Launcher_Base_Impl::teardown_plan - DAM has no application.\n")); + DANCE_DEBUG((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::teardown_plan - " + "DAM has no application.\n")); } for (size_t i = 0; i < apps->length(); ++i) { @@ -331,17 +363,17 @@ void Plan_Launcher_Base_Impl::teardown_plan( } this->destroy_dam(dam); - DANCE_DEBUG ( (LM_DEBUG, "[%M] Plan_Launcher_Base_Impl::teardown_plan - [success]\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::teardown_plan - [success]\n")); } void Plan_Launcher_Base_Impl::destroy_dam( ::Deployment::DomainApplicationManager_ptr dam) { - DANCE_DEBUG ( (LM_DEBUG, - "[%M] Plan_Launcher_Base_Impl::destroy_dam - destroy the manager.....\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO + "Plan_Launcher_Base_Impl::destroy_dam - destroy the manager.....\n")); this->em_->destroyManager(dam); - DANCE_DEBUG ( (LM_DEBUG, "[%M] Plan_Launcher_Base_Impl::destroy_dam - [success]\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "Plan_Launcher_Base_Impl::destroy_dam - [success]\n")); } void Plan_Launcher_Base_Impl::usage(const ACE_TCHAR* program) @@ -366,7 +398,7 @@ void Plan_Launcher_Base_Impl::usage(const ACE_TCHAR* program) void Plan_Launcher_Base_Impl::parse_args(int argc, ACE_TCHAR *argv[]) { - DANCE_DEBUG ( (LM_TRACE, "[%M] PL options : \"")); + DANCE_DEBUG ((LM_TRACE, DLINFO "PL options : \"")); for (int i = 0; i < argc; ++i) { DANCE_DEBUG ( (LM_TRACE, " %s", argv[i])); @@ -409,7 +441,7 @@ void Plan_Launcher_Base_Impl::parse_args(int argc, ACE_TCHAR *argv[]) case 'w': if (0 < this->cdr_dest_url_.length()) { - DANCE_ERROR((LM_ERROR, "[%M] Ambiguity: more then one --write-cdr-plan option.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Ambiguity: more then one --write-cdr-plan option.\n")); throw Deployment_Failure("Ambiguity: more then one --write-cdr-plan option."); } this->cdr_dest_url_ = expand_env_vars (get_opt.opt_arg()); @@ -468,36 +500,42 @@ void Plan_Launcher_Base_Impl::write_dam_ior( } else { - DANCE_ERROR ( (LM_ERROR, "[%M] PlanLauncher.cpp::write_dap_ior - Error in opening file %s to write DAM IOR: %m", + DANCE_ERROR ((LM_ERROR, DLINFO "PlanLauncher.cpp::write_dap_ior - Error in opening file %s to write DAM IOR: %m", this->dam_ior_.c_str())); throw Deployment_Failure (ACE_CString ("write_dap_ior - Error in opening file %s to write DAM IOR: %m") + this->dam_ior_); } } -void Plan_Launcher_Base_Impl::stop_plan() +void +Plan_Launcher_Base_Impl::stop_plan() { bool stopped = false; if (!is_empty (this->plan_uuid_)) { stopped = true; - ACE_TRACE((LM_TRACE, "[%M] Stopping plan \"%s\"\n", this->plan_uuid_.c_str())); + DANCE_DEBUG((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "Stopping plan \"%s\"\n", this->plan_uuid_.c_str())); + if (!this->teardown_plan(this->plan_uuid_.c_str())) { - DANCE_ERROR ( (LM_ERROR, "[%M] stop_plan - tear down assembly failed: unknown plan uuid.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "tear down assembly failed: unknown plan uuid.\n")); } } if (!is_empty (this->dam_ior_)) { stopped = true; - ACE_TRACE((LM_TRACE, "[%M] Stopping plan by DAM IOR.\n")); + DANCE_DEBUG((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "Stopping plan by DAM IOR.\n")); CORBA::Object_var obj = this->orb_->string_to_object(this->dam_ior_.c_str()); if (CORBA::is_nil (obj.in ())) { - DANCE_ERROR ((LM_ERROR, - "[%M] stop_plan - tear down assembly failed: DAM IOR is invalid.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO + "Plan_Launcher_Base_Impl::stop_plan - " + "tear down assembly failed: DAM IOR is invalid.\n")); } else { @@ -513,18 +551,21 @@ void Plan_Launcher_Base_Impl::stop_plan() size_t sz = this->cdr_plan_urls_.size(); for (size_t i = 0; i < sz; ++i) { - ACE_TRACE((LM_TRACE, "[%M] Stopping plan by plan file : %s\n", this->cdr_plan_urls_[i].c_str())); + DANCE_DEBUG((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "Stopping plan by plan file : %s\n", this->cdr_plan_urls_[i].c_str())); ::Deployment::DeploymentPlan_var plan = this->read_cdr_plan_file(this->cdr_plan_urls_[i].c_str()); if (!this->teardown_plan(plan->UUID.in())) { - DANCE_ERROR ( (LM_ERROR, "[%M] stop_plan - tear down assembly failed: unknown plan uuid.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "tear down assembly failed: unknown plan uuid.\n")); } } } if (!stopped && 0 == this->xml_plan_urls_.size()) { - ACE_TRACE((LM_TRACE, "[%M] Stopping plan all running plans.\n")); + DANCE_DEBUG((LM_TRACE, DLINFO "Plan_Launcher_Base_Impl::stop_plan - " + "Stopping plan all running plans.\n")); ::Deployment::DomainApplicationManagers_var mgrs = this->em_->getManagers(); ::Deployment::DomainApplicationManager_var dapp_mgr; @@ -538,7 +579,7 @@ void Plan_Launcher_Base_Impl::stop_plan() void Plan_Launcher_Base_Impl::create_external_connections( const ::Deployment::DeploymentPlan &plan, Deployment::Connections& conn) { - DANCE_DEBUG ( (LM_DEBUG, "[%M] create_external_connections - start\n")); + DANCE_DEBUG ((LM_DEBUG, DLINFO "create_external_connections - start\n")); /* CORBA::Object_var obj = this->orb_->resolve_initial_references("NameService"); CosNaming::NamingContext_var naming = CosNaming::NamingContext::_narrow(obj.in()); CosNaming::BindingList_var bl; @@ -640,13 +681,14 @@ Deployment::DeploymentPlan*Plan_Launcher_Base_Impl::read_cdr_plan_file( } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] Failed to read CDR plan file.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Failed to read CDR plan file.\n")); throw Deployment_Failure("Failed to read CDR plan file."); } return res; } -void Plan_Launcher_Base_Impl::write_cdr_plan_file(const char * filename, +void +Plan_Launcher_Base_Impl::write_cdr_plan_file(const char * filename, const Deployment::DeploymentPlan & plan) { try @@ -670,7 +712,8 @@ void Plan_Launcher_Base_Impl::write_cdr_plan_file(const char * filename, } catch(...) { - DANCE_ERROR((LM_ERROR, "[%M] Failed to write CDR plan file.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Base_Impl::write_cdr_plan_file - " + "Failed to write CDR plan file.\n")); throw Deployment_Failure("Failed to write CDR plan file."); } } @@ -759,10 +802,10 @@ Plan_Launcher_Base_Impl::expand_env_vars (const char * s) } else { - DANCE_DEBUG ( (LM_WARNING - , "Envvar can not be parsed out at %i in \"%s\"" - , pos_start - , src.c_str())); + DANCE_DEBUG ((LM_WARNING, DLINFO "Plan_Launcher_Base_Impl::expand_env_vars - " + "Envvar can not be parsed out at %i in \"%s\"", + pos_start, + src.c_str())); } } } diff --git a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp index 4b73fc9c3a6..bd1c5f49425 100644 --- a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp +++ b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Impl.cpp @@ -18,10 +18,11 @@ namespace DAnCE namespace Plan_Launcher { -::Deployment::DeploymentPlan *Plan_Launcher_Impl::load_xml_plan( - const char *deployment_plan_uri) +::Deployment::DeploymentPlan * +Plan_Launcher_Impl::load_xml_plan(const char *deployment_plan_uri) { - DANCE_DEBUG ( (LM_TRACE, "[%M] load_xml_plan - Parsing plan \"%s\"...\n", deployment_plan_uri)); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Impl::load_xml_plan - " + "Parsing plan \"%s\"...\n", deployment_plan_uri)); ::Deployment::DeploymentPlan * plan = 0; try @@ -32,7 +33,8 @@ namespace Plan_Launcher plan = intf.release_plan (); if (0 == plan) { - DANCE_ERROR((LM_ERROR, "[%M] Failed to parse plan \"%s\".\n", deployment_plan_uri)); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Impl::load_xml_plan - " + "Failed to parse plan \"%C\".\n", deployment_plan_uri)); throw Deployment_Failure("Failed to parse plan."); } } @@ -41,24 +43,27 @@ namespace Plan_Launcher ACE_CString s = "failed to parse deployment plan \""; s += deployment_plan_uri; s += "\""; - DANCE_DEBUG ((LM_ERROR, "[%M] %s\n", s.c_str())); + DANCE_DEBUG ((LM_ERROR, DLINFO "Plan_Launcher_Impl::load_xml_plan - %C\n", s.c_str())); throw Deployment_Failure (s.c_str()); } - // Deployment::DnC_Dump::dump (*plan); - DANCE_DEBUG ( (LM_TRACE, "[%M] load_xml_plan - Parsing complete....\n")); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Impl::load_xml_plan - Parsing complete....\n")); return plan; } void Plan_Launcher_Impl::execute() { + DANCE_TRACE ("Plan_Launcher_Impl::execute()"); + if (this->mode_ & MODE_START_PLAN) { size_t sz = this->xml_plan_urls_.size(); for (size_t i= 0; i < sz; ++i) { - DANCE_DEBUG ( (LM_TRACE, "[%M] execute - launching plan \"%s\"...\n", this->xml_plan_urls_[i].c_str())); - ::Deployment::DeploymentPlan_var plan = this->load_xml_plan(this->xml_plan_urls_[i].c_str()); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Impl::execute - " + "launching plan \"%C\"...\n", this->xml_plan_urls_[i].c_str())); + ::Deployment::DeploymentPlan_var plan = + this->load_xml_plan(this->xml_plan_urls_[i].c_str()); try { CORBA::String_var uuid = this->launch_plan (plan.in()); @@ -66,7 +71,8 @@ void Plan_Launcher_Impl::execute() { throw Deployment_Failure ("execute - Error launching plan\n"); } - DANCE_DEBUG ( (LM_TRACE, "[%M] execute - returned plan UUID is \"%s\"\n", uuid.in ())); + DANCE_DEBUG ((LM_TRACE, DLINFO "Plan_Launcher_Impl::execute - " + "returned plan UUID is \"%s\"\n", uuid.in ())); } catch (...) { @@ -90,16 +96,20 @@ void Plan_Launcher_Impl::execute() } void Plan_Launcher_Impl::stop_plan() { + DANCE_TRACE ("Plan_Launcher_Impl::stop_plan"); + if (0 < this->xml_plan_urls_.size()) { size_t sz = this->xml_plan_urls_.size(); for (size_t i= 0; i < sz; ++i) { - ACE_TRACE((LM_TRACE, "[%M] Stopping plan by plan file : %s\n", this->xml_plan_urls_[i].c_str())); + DANCE_DEBUG((LM_TRACE, DLINFO "Plan_Launcher_Impl::stop_plan - " + "Stopping plan by plan file: %C\n", this->xml_plan_urls_[i].c_str())); ::Deployment::DeploymentPlan_var plan = this->load_xml_plan(this->xml_plan_urls_[i].c_str()); if (!this->teardown_plan(plan->UUID.in())) { - DANCE_ERROR ( (LM_ERROR, "[%M] stop_plan - tear down assembly failed: unknown plan uuid.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "Plan_Launcher_Impl::stop_plan - " + "tear down assembly failed: unknown plan uuid.\n")); } } } diff --git a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp index 629c860a6e1..0312707a66c 100644 --- a/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp +++ b/flat/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Module.cpp @@ -25,21 +25,27 @@ DAnCE_Plan_Launcher_Module::create_object (CORBA::ORB_ptr orb, { try { - DANCE_ERROR ( (LM_TRACE, "[%M] Plan_Launcher_Module init starting.\n")); + DANCE_DEBUG ((LM_TRACE, DLINFO "DAnCE_Plan_Launcher_Module::create_object - " + "Creating Plan Launcher object.")); + Plan_Launcher_Impl pl (orb, argc, argv); pl.execute(); } catch (const Plan_Launcher_Base_Impl::Deployment_Failure& e) { - DANCE_ERROR ( (LM_ERROR, "[%M] PlanLauncher error : %s.\n", e.error_.c_str())); + DANCE_ERROR ((LM_ERROR, DLINFO "DAnCE_Plan_Launcher_Module::create_object - " + "Eerror : %s.\n", e.error_.c_str())); } catch (const CORBA::Exception& ex) { - ex._tao_print_exception ("Plan_Launcher_Module.cpp::init "); + DANCE_ERROR ((LM_ERROR, DLINFO "DAnCE_Plan_Launcher_Module::create_object - " + "Caught CORBA Exception %C", + ex._info ().c_str ())); } catch (...) { - DANCE_ERROR ( (LM_ERROR, "[%M] Plan_Launcher_Module.cpp::init Unknown exception.\n")); + DANCE_ERROR ((LM_ERROR, DLINFO "DAnCE_Plan_Launcher_Module::create_object - " + "Unknown exception.\n")); } return CORBA::Object::_nil (); } diff --git a/flat/CIAO/examples/Hello/ReDaC-Usage.html b/flat/CIAO/examples/Hello/ReDaC-Usage.html deleted file mode 100644 index eb9b8c729b7..00000000000 --- a/flat/CIAO/examples/Hello/ReDaC-Usage.html +++ /dev/null @@ -1,308 +0,0 @@ - - - - - - - - ReDaC Service Usage - - - - - - -
-

Simple Tutorial for using ReDaC (Redeployment and Reconfiguration)

- - -Prerequisite:
- - -
- - -
Before you proceed further, please read the step-by-step tutorial -page first.
- - -
- - -
Note: -
- - -
    - - -
  • ReDaC is a middleware service provided by the DAnCE -framework.
  • - - -
  • ReDaC service is used for redeployment and/or -reconfiguration of your running component-based application on -the fly without shutting down your application. 
  • - - -
  • ReDaC currently works for CIAO QoS-enabled component -middleware only.
  • - - -
- - -
-

Example Description

- - -We will use the Hello example to illustrate how one could use ReDaC -service to perform redeployment and reconfiguration. -
-

Initial Deployment

- - -Below steps are required for the initial deployment of your application, -which is performed by DAnCE. The below steps are different from those -presented in the step-by-step -tutorial page in the sense that we pass different command line options -to the Plan_Launcher -client:
- - -
    - - -
  • Go into the descriptors directory -Start NodeManagers (NodeDameons) by running -run_NodeDaemons.pl
  • - - - -
      - - -
    • This step is the same as the one presented in the - step-by-step -tutorial page.
    • - - - -
    - - -
  • Start the execution manager: $CIAO_ROOT/DAnCE/ExecutionManager/Execution_Manager --o EM.ior -i NodeManagerMap.dat
  • - - - -
      - - -
    • As one can see, we use the -"NodeManagerMap.dat" file to instruct the Execution_Manager how to find -the endpoint of each individual NodeManager (i.e., Node Daemon) where -component(s) will be deployed.
    • - - - -
    - - - -
      - - -
    • This step is the same as the one presented in the - step-by-step -tutorial page.
    • - - - -
    - - -
  • Start the plan launcher: -$CIAO_ROOT/DAnCE/Plan_Launcher/plan_launcher -p -flattened_deploymentplan_without_ns.cdp -k file://EM.ior -o DAM.ior 
  • - - - -
      - - -
    • After this, components should be deployed -successfully.
    • - - -
    • This step is different  from the one presented -in the - step-by-step -tutorial page in the way that we added an additional "-o" -option when running Plan_Launcher, which -dumps an IOR file of DAnCE's DomainApplicationManager.  With -this option added, the plan_launcher will -exit immediately after the application is deployed, instead of staying -in the interactive mode. (As a normal user, you don't need to worry -about the details of what exactly a DomainApplicationManager is.)
    • - - - -
    - - -
- - -
-

Redeployment and Reconfiguration

- - -Basically, you could use ReDaC service in two ways.
- - -
    - - -
  1. Use ReDaC service directly -through DAnCE's Plan_Launcher -client
  2. - - -
  3. Use ReDaC -service programmatically -by writing your own client
  4. - - -
- - -This tutorial illustrates how exactly you could use ReDaC.
- - -
- - -Use ReDaC service through -Plan_Launcher  of DAnCE:
- - -
    - - -
  • As we've already mentioned, you should first deploy your -Hello application with DAnCE, which is described in the above "Initial -Deployment" section of this tutorial. -
  • - - -
  • - -

    Use ReDaC service through Plan_Launcher's -"-r" command line option to perform redeployment and reconfiguration.
    - - -Run the command - $CIAO_ROOT/DAnCE/Plan_Launcher/plan_launcher -r -flattened_deploymentplan_without_ns_add.cdp will add -additional components to the existing running assembly.

    - - -
  • - - -
  • - -

    Run the command - $CIAO_ROOT/DAnCE/Plan_Launcher/plan_launcher -r -flattened_deploymentplan_without_ns_remove.cdp will -remove components from the existing running assembly.

    - - -
  • - - -
  • Run the command - $CIAO_ROOT/DAnCE/Plan_Launcher/plan_launcher --i file://DAM.ior will tear down your entire application -completely.
  • - - -
- - -
- - -
NOTE:  By -using ReDaC through Plan_Launcher, as a user you must provide a new -DeploymentPlan (.cdp) XML file, which captures the new deployment and -configuration settings of your application, and the Plan_UUID of the -new DeploymentPlan should be the same as the one of the old -(running) DeploymentPlan. Otherwise, DAnCE will think you want to -deploy a totally different deployment plan, instead of applying some -changes to the existing plan. One could use CoSMIC MDD tool to create such a deployment plan XML file.
- -
- - -
- - -Use ReDaC service programmatically: -
    - - - -

    You could also use ReDaC service programmatically by writing your -own client to invoke ReDaC service. Basically, to accomplish this, your -client program needs to:

    - - -
      - -
    1. Obtain the ExecutionManager object reference, either through naming service or through IOR file.
    2. - -
    3. Invoke the operation perform_redeployment on this interface by passing a single argument type called DeploymentPlan.
    4. - - -
    - - -
- - -
The IDL signature of this operation is as follows:
- -
- -    void perform_redeployment (in DeploymentPlan new_plan)
- -      raises (PlanError,
- -              InstallationFailure,
- -              UnknownImplId,
- -              ImplEntryPointNotFound,
- -              InvalidConnection,
- -              InvalidProperty,
- -              ::Components::RemoveFailure);

- -
- - -
-
In order to simplify the creation of a the "new_plan", we are implementing a utility class which allows a developer to easily manipulate a deployment plan data structure.
- - -
-Email: -
ciao-users@cse.wustl.edu
- - - - diff --git a/flat/CIAO/examples/Hello/Sender/Sender_exec.cpp b/flat/CIAO/examples/Hello/Sender/Sender_exec.cpp index ab8cee97e04..d8b7115e34e 100644 --- a/flat/CIAO/examples/Hello/Sender/Sender_exec.cpp +++ b/flat/CIAO/examples/Hello/Sender/Sender_exec.cpp @@ -26,7 +26,7 @@ namespace CIDL_Sender_Impl char* Message_Impl::get_message () { - ACE_DEBUG ((LM_DEBUG, "Sender sending out message: [%s]\n", component_.message_.in ())); + ACE_DEBUG ((LM_EMERGENCY, "Sender sending out message: [%s]\n", component_.message_.in ())); return CORBA::string_dup (component_.message_.in ()); } @@ -50,7 +50,7 @@ namespace CIDL_Sender_Impl Sender_exec_i::hertz (CORBA::Long hertz) { this->hertz_ = hertz; - ACE_DEBUG ((LM_DEBUG, "Sender_exec_i::Hertz:%d\n", this->hertz_)); + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::Hertz:%d\n", this->hertz_)); } CORBA::Long @@ -75,7 +75,7 @@ namespace CIDL_Sender_Impl Hello::CCM_ReadMessage_ptr Sender_exec_i::get_push_message () { - ACE_DEBUG ((LM_DEBUG, + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec.i::get_push_message called\n ")); return ( new Message_Impl (*this) ); } @@ -85,31 +85,31 @@ namespace CIDL_Sender_Impl { Hello::TimeOut_var event = new OBV_Hello::TimeOut; event->data ("ACE/TAO/CIAO"); - ACE_DEBUG ((LM_DEBUG, "Sender initiates the process.\n")); + ACE_DEBUG ((LM_EMERGENCY, "Sender initiates the process.\n")); this->context_->push_click_out (event.in ()); - ACE_DEBUG ((LM_DEBUG, "My current color is:")); + ACE_DEBUG ((LM_EMERGENCY, "My current color is:")); switch (this->color_) { case ::Hello::empty: - ACE_DEBUG ((LM_DEBUG, "ERROR: Enum attribute initialization failed.\n")); + ACE_DEBUG ((LM_EMERGENCY, "ERROR: Enum attribute initialization failed.\n")); break; case ::Hello::white: - ACE_DEBUG ((LM_DEBUG, "white\n")); + ACE_DEBUG ((LM_EMERGENCY, "white\n")); break; case ::Hello::red: - ACE_DEBUG ((LM_DEBUG, "red\n")); + ACE_DEBUG ((LM_EMERGENCY, "red\n")); break; case ::Hello::yellow: - ACE_DEBUG ((LM_DEBUG, "yellow\n")); + ACE_DEBUG ((LM_EMERGENCY, "yellow\n")); break; default: - ACE_DEBUG ((LM_DEBUG, "Unknown color!\n")); + ACE_DEBUG ((LM_EMERGENCY, "Unknown color!\n")); } } @@ -117,7 +117,7 @@ namespace CIDL_Sender_Impl void Sender_exec_i::set_session_context (::Components::SessionContext_ptr ctx) { - ACE_DEBUG ((LM_DEBUG, "Sender_exec_i::set_session_context\n")); + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::set_session_context\n")); this->context_ = ::Hello::CCM_Sender_Context::_narrow (ctx); @@ -131,27 +131,27 @@ namespace CIDL_Sender_Impl void Sender_exec_i::configuration_complete () { - ACE_DEBUG ((LM_DEBUG, + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::configuration_complete\n")); } void Sender_exec_i::ccm_activate () { - ACE_DEBUG ((LM_DEBUG, + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::ccm_activate\n")); } void Sender_exec_i::ccm_passivate () { - ACE_DEBUG ((LM_DEBUG, "Sender_exec_i::ccm_passivate\n")); + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::ccm_passivate\n")); } void Sender_exec_i::ccm_remove () { - ACE_DEBUG ((LM_DEBUG, "Sender_exec_i::ccm_remove\n")); + ACE_DEBUG ((LM_EMERGENCY, "Sender_exec_i::ccm_remove\n")); } SenderHome_exec_i::SenderHome_exec_i () @@ -165,7 +165,7 @@ namespace CIDL_Sender_Impl ::Components::EnterpriseComponent_ptr SenderHome_exec_i::create () { - ACE_DEBUG ((LM_DEBUG, "(%P|%t) creating SenderHome \n")); + ACE_DEBUG ((LM_EMERGENCY, "(%P|%t) creating SenderHome \n")); ::Components::EnterpriseComponent_ptr retval = ::Components::EnterpriseComponent::_nil (); diff --git a/flat/CIAO/examples/Hello/descriptors/DeploymentPlan.cdp b/flat/CIAO/examples/Hello/descriptors/DeploymentPlan.cdp index 97cc6982813..8d22e0ea906 100644 --- a/flat/CIAO/examples/Hello/descriptors/DeploymentPlan.cdp +++ b/flat/CIAO/examples/Hello/descriptors/DeploymentPlan.cdp @@ -133,6 +133,28 @@ + + edu.vanderbilt.dre.DAnCE.InstanceIOR + + + tk_string + + + ReceiverHome.ior + + + + + edu.vanderbilt.dre.DAnCE.RegisterNaming + + + tk_string + + + ReceiverHome + + + @@ -152,6 +174,28 @@ + + edu.vanderbilt.dre.DAnCE.InstanceIOR + + + tk_string + + + Receiver.ior + + + + + edu.vanderbilt.dre.DAnCE.RegisterNaming + + + tk_string + + + Receiver + + + @@ -160,6 +204,28 @@ + + edu.vanderbilt.dre.DAnCE.InstanceIOR + + + tk_string + + + SenderHome.ior + + + + + edu.vanderbilt.dre.DAnCE.RegisterNaming + + + tk_string + + + SenderHome + + + @@ -179,6 +245,58 @@ + + local_message + + + tk_string + + + hello, world! + + + + + color + + + tk_enum + + COLOR_SELECTION + IDL:Hello/COLOR_SELECTION:1.0 + empty + white + red + yellow + + + + yellow + + + + + edu.vanderbilt.dre.DAnCE.InstanceIOR + + + tk_string + + + Sender.ior + + + + + edu.vanderbilt.dre.DAnCE.RegisterNaming + + + tk_string + + + Sender + + + diff --git a/flat/CIAO/examples/Hello/descriptors/Hello.cid b/flat/CIAO/examples/Hello/descriptors/Hello.cid deleted file mode 100644 index f7abad71ded..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Hello.cid +++ /dev/null @@ -1,93 +0,0 @@ - - - - effd4bd0-6db0-4c50-9bb7-db9decebae1c - - - Sender_Instance - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - hertz - - - tk_long - - - 50 - - - - - - - - - Receiver_Instance - - - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - Messages - - read_message - - - - push_message - - - - - Events - - click_in - - - - click_out - - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Hello.cpd b/flat/CIAO/examples/Hello/descriptors/Hello.cpd deleted file mode 100644 index 52b0e9a6c1d..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Hello.cpd +++ /dev/null @@ -1,13 +0,0 @@ - - - - 823e4287-f53c-4caa-8619-f3dfda4c4998 - - Hello - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Libraries.iad b/flat/CIAO/examples/Hello/descriptors/Libraries.iad deleted file mode 100644 index 6112a23ca3b..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Libraries.iad +++ /dev/null @@ -1,8 +0,0 @@ - - - - 6bae4fcd-c71c-44b4-a0d4-0e4199ce1a49 - $ACE_ROOT/lib/libACE - $ACE_ROOT/lib/libTAO - $ACE_ROOT/lib/libCIAO_DnC_Client - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver.ccd b/flat/CIAO/examples/Hello/descriptors/Receiver.ccd deleted file mode 100644 index a5167d03e7a..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver.ccd +++ /dev/null @@ -1,34 +0,0 @@ - - - - 589462ed-e88f-4f96-a7a7-359cdc333d63 - IDL:Hello/Receiver:1.0 - IDL:Hello/Receiver:1.0 - Receiver.idl - - click_in - false - false - false - false - IDL:Hello/TimeOut:1.0 - IDL:Hello/TimeOut:1.0 - EventConsumer - - - - read_message - false - false - false - false - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - SimplexReceptacle - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver.cid b/flat/CIAO/examples/Hello/descriptors/Receiver.cid deleted file mode 100644 index 18d379e7eba..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver.cid +++ /dev/null @@ -1,24 +0,0 @@ - - - - 0a52c9de-7852-42e4-aac7-bf478169a21a - - - - Receiver_Stub - - - - Receiver_Svnt - - - - Receiver_Exec - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver.cpd b/flat/CIAO/examples/Hello/descriptors/Receiver.cpd deleted file mode 100644 index 3cddb924834..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver.cpd +++ /dev/null @@ -1,14 +0,0 @@ - - - - a5923ef4-9c62-4458-9fa4-869b53d834ca - - - Receiver - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver_Exec.iad b/flat/CIAO/examples/Hello/descriptors/Receiver_Exec.iad deleted file mode 100644 index f039e8cd68b..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver_Exec.iad +++ /dev/null @@ -1,29 +0,0 @@ - - - - 412f8156-7913-4651-9110-f7a3f98c7a83 - Hello_Receiver_exec - - ACE - - - - Receiver_Stub - - - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver_Stub.iad b/flat/CIAO/examples/Hello/descriptors/Receiver_Stub.iad deleted file mode 100644 index f226d9b0d92..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver_Stub.iad +++ /dev/null @@ -1,14 +0,0 @@ - - - - 4d02c22b-768e-4d1a-bf07-76da2f5d1fbf - Hello_Receiver_stub - - ACE - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Receiver_Svnt.iad b/flat/CIAO/examples/Hello/descriptors/Receiver_Svnt.iad deleted file mode 100644 index 535ccf10d8d..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Receiver_Svnt.iad +++ /dev/null @@ -1,29 +0,0 @@ - - - - ad052b10-0806-43c7-9ccc-2dfeda0e0e03 - Hello_Receiver_svnt - - ACE - - - - Receiver_Stub - - - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender.ccd b/flat/CIAO/examples/Hello/descriptors/Sender.ccd deleted file mode 100644 index cf07fe0ef75..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender.ccd +++ /dev/null @@ -1,48 +0,0 @@ - - - - - 803f8fc7-55de-4a20-81eb-ae951d85b7f4 - IDL:Hello/Sender:1.0 - IDL:Hello/Sender:1.0 - - local_message - - tk_string - - - - supports - false - false - false - true - IDL:Hello/trigger:1.0 - Facet - - - click_out - false - false - false - true - IDL:Hello/TimeOut:1.0 - IDL:Hello/TimeOut:1.0 - EventPublisher - - - push_message - false - false - false - true - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - Facet - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender.cid b/flat/CIAO/examples/Hello/descriptors/Sender.cid deleted file mode 100644 index c6e02fc2d25..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender.cid +++ /dev/null @@ -1,24 +0,0 @@ - - - - 789e1be2-703f-4bd3-af50-b400eef91fd0 - - - - Sender_Stub - - - - Sender_Svnt - - - - Sender_Exec - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender.cpd b/flat/CIAO/examples/Hello/descriptors/Sender.cpd deleted file mode 100644 index df2c441be3f..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender.cpd +++ /dev/null @@ -1,14 +0,0 @@ - - - - 07ebf947-2174-4a3b-bd37-bcb92986eaf4 - - - Sender - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender_Exec.iad b/flat/CIAO/examples/Hello/descriptors/Sender_Exec.iad deleted file mode 100644 index a5d70fe8504..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender_Exec.iad +++ /dev/null @@ -1,29 +0,0 @@ - - - - 5e4f2366-3810-4d4c-a269-5788a525cbe1 - Hello_Sender_exec - - ACE - - - - Sender_Stub - - - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender_Stub.iad b/flat/CIAO/examples/Hello/descriptors/Sender_Stub.iad deleted file mode 100644 index 13c28534aaf..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender_Stub.iad +++ /dev/null @@ -1,14 +0,0 @@ - - - - 93bbdf7d-d3f7-4227-bb75-b0562ac15b92 - Hello_Sender_stub - - ACE - - - diff --git a/flat/CIAO/examples/Hello/descriptors/Sender_Svnt.iad b/flat/CIAO/examples/Hello/descriptors/Sender_Svnt.iad deleted file mode 100644 index dd4a6f02027..00000000000 --- a/flat/CIAO/examples/Hello/descriptors/Sender_Svnt.iad +++ /dev/null @@ -1,29 +0,0 @@ - - - - 04e4d246-e6eb-4b0e-8e32-60b996497cea - Hello_Receiver_svnt - - ACE - - - - Sender_Stub - - - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - diff --git a/flat/CIAO/examples/Hello/descriptors/run_test.pl b/flat/CIAO/examples/Hello/descriptors/run_test.pl index a3df657cab1..54c916a973e 100755 --- a/flat/CIAO/examples/Hello/descriptors/run_test.pl +++ b/flat/CIAO/examples/Hello/descriptors/run_test.pl @@ -17,6 +17,7 @@ $ns_running = 0; $daemons = 2; @ports = ( 60001, 60002 ); @iorfiles = ( "NodeApp1.ior", "NodeApp2.ior" ); +@nodenames = ( "SenderNode", "ReceiverNode" ); $status = 0; $dat_file = "NodeManagerMap.dat"; $cdp_file = "DeploymentPlan.cdp"; @@ -69,12 +70,12 @@ sub run_node_daemons { { $iorfile = $iorfiles[$i]; $port = $ports[$i]; - + $nodename = $nodenames[$i]; $iiop = "iiop://localhost:$port"; - $node_app = "$CIAO_ROOT/bin/NodeApplication"; + $node_app = "$CIAO_ROOT/bin/ciao_component_server"; - $d_cmd = "$CIAO_ROOT/bin/NodeManager"; - $d_param = "-ORBEndpoint $iiop -s $node_app -o $iorfile -d 30"; + $d_cmd = "$CIAO_ROOT/bin/dance_node_manager"; + $d_param = "-ORBEndpoint $iiop -s $node_app -n $nodename=$iorfile -d 30"; $Daemons[$i] = new PerlACE::Process ($d_cmd, $d_param); $result = $Daemons[$i]->Spawn (); @@ -130,12 +131,12 @@ $daemons_running = 1; # Invoke execution manager. print "Invoking execution manager\n"; -$EM = new PerlACE::Process ("$CIAO_ROOT/bin/Execution_Manager", - "-o EM.ior -i $dat_file"); +$EM = new PerlACE::Process ("$DANCE_ROOT/bin/dance_execution_manager", + "-o EM.ior --node-map $dat_file"); $EM->Spawn (); if (PerlACE::waitforfile_timed ("EM.ior", - $PerlACE::wait_interval_for_process_creation) == -1) { + $PerlACE::wait_interval_for_process_creation) == -1) { print STDERR "ERROR: The ior file of execution manager could not be found\n"; kill_open_processes (); @@ -147,7 +148,7 @@ $em_running = 1; # Invoke executor - start the application -. print "Invoking executor - start the application -\n"; $E = - new PerlACE::Process ("$CIAO_ROOT/bin/plan_launcher", + new PerlACE::Process ("$DANCE_ROOT/bin/dance_plan_launcher", "-p DeploymentPlan.cdp -k file://EM.ior -o DAM.ior"); $E->SpawnWaitKill (5000); diff --git a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan.cdp b/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan.cdp deleted file mode 100644 index 083484ca185..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan.cdp +++ /dev/null @@ -1,222 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_event_connection - - click_out - EventPublisher - Hello-Sender-idd - - - click_in - EventConsumer - Hello-Receiver-idd - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_add.cdp b/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_add.cdp deleted file mode 100644 index af8f50026e8..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_add.cdp +++ /dev/null @@ -1,267 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - Hello-Receiver-idd-UPDATE-XXXXXXXXX - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver_2.ior - - - - - - - hello_event_connection - - click_out - EventPublisher - Hello-Sender-idd - - - click_in - EventConsumer - Hello-Receiver-idd - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - hello_event_connection_new - - click_out - EventPublisher - Hello-Sender-idd - - - click_in - EventConsumer - Hello-Receiver-idd-UPDATE-XXXXXXXX - - - - - hello_facet_connection_new - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd-UPDATE-XXXXXXXX - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_remove.cdp b/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_remove.cdp deleted file mode 100644 index 79cc923d154..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_ReDaC/deploymentplan_remove.cdp +++ /dev/null @@ -1,223 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - - Hello-Receiver-idd-UPDATE-XXXXXXXXX - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver_2.ior - - - - - - - - hello_event_connection_new - - click_out - EventPublisher - Hello-Sender-idd - - - click_in - EventConsumer - Hello-Receiver-idd-UPDATE-XXXXXXXX - - - - - hello_facet_connection_new - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd-UPDATE-XXXXXXXX - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap.dat b/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap.dat deleted file mode 100644 index 9880f37997e..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap.dat +++ /dev/null @@ -1,2 +0,0 @@ -SenderNode corbaloc:iiop:localhost:60001/NodeManager -ReceiverNode corbaloc:iiop:localhost:60002/NodeManager \ No newline at end of file diff --git a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMapTwoHosts.dat b/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMapTwoHosts.dat deleted file mode 100644 index 54066c67ce0..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMapTwoHosts.dat +++ /dev/null @@ -1,2 +0,0 @@ -SenderNode corbaloc:iiop:localhost:60001/NodeManager -ReceiverNode corbaloc:iiop:129.59.129.181:60002/NodeManager \ No newline at end of file diff --git a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap_collocated.dat b/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap_collocated.dat deleted file mode 100644 index 3aa4d0922e0..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/NodeManagerMap_collocated.dat +++ /dev/null @@ -1 +0,0 @@ -SenderNode corbaloc:iiop:localhost:60001/NodeManager diff --git a/flat/CIAO/examples/Hello/descriptors_events/README b/flat/CIAO/examples/Hello/descriptors_events/README deleted file mode 100644 index 924893bbf2c..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/README +++ /dev/null @@ -1,145 +0,0 @@ -Event Descriptors for Hello Example -=================================== - -This folder contains several deployemnts to demonstrate and test the -functionality of rt event channel integration into CIAO/DAnCE. -Please see $CIAO_ROOT/docs/schema/CIAOEvents.txt for a detailed description -how to configure descriptor files accordingly. - -The rest of this file describes the rule of the files in this directory. - -single files and their role: ----------------------------- - -./run_test.pl : script that executes all available tests - -./run_NodeDaemons.pl : script to launch two empty NodeApplications -./run_NodeDaemons_svc_conf.pl : starts two node NodeApplications on the - localhost interface and loads rtec.conf on - startup -./run_NodeDaemons_with_ip.pl : starts two node NodeApplications under the - IP address and not on the localhost interface - -./NodeManagerMap.dat : contains ip addresses for SenderNode and - ReceiverNode (both on localhost) -./NodeManagerMap_collocated.dat : contains an ip address for a single - SenderNode (on localhost) -./NodeManagerMapTwoHosts.dat : contains ip addresses for SenderNode - (on localhost) and ReceiverNode - (on real ip address) - -./rtec.conf : example for a service configurator file - for the event service - - -existing test cases: --------------------- - -./ciao-events-example.ced -./deploymentplan_events.cdp -./run_test_simple.pl - - Uses the standard event service and connects one sender to one - receiver. In the standard configuration, used here, the EventChannel - is running collocated within the NodeApplication "SenderNode", where - the sender component is located: - SenderNode[Sender --> ES] --> ReceiverNode[Receiver] - -./ciao-events-example-collocated.ced -./deploymentplan_events_collocated.cdp -./run_test_collocated.pl: - - This example modifies the standard example by deploying all components - within one node: - SenderNode[Sender --> ES --> Receiver] - -./ciao-events-example-with-federation.ced -./deploymentplan_federation.cdp -./run_test_federated.pl: - - In this example, two Event Services ES_01 and ES_02 are federated. - The Sender Event Port is then connected to the first service, while - the Receiver gets its events from the second service. - All entities are collocated in one node process: - SenderNode[Sender --> ES_01 --> ES_02 --> Receiver] - - (problem: - Receiver - Informed by the Sender with message [ACE/TAO/CIAO] - CORBA EXCEPTION caught - (27698|3072210624) EXCEPTION, RTEventServiceConsumer_impl::push() - - system exception, ID 'IDL:omg.org/CORBA/BAD_INV_ORDER:1.0' - Unknown vendor minor code id (0), minor code = 0, completed = NO - ) - -./ciao-events-example-with-filters.ced -./deploymentplan_with_filters.cdp -./run_test_filtered.pl: - - This example applies a filter to the EventService connection on the - receiver side. In this case the filter contains a disjunction group - of two sender component sources. - SenderNode[Sender --> ES -{Filter}-> Receiver] - -./ciao-events-federation-mcast.ced -./deploymentplan_federation_mcast.cdp -./run_test_multicast.pl: - - To test collocated use of multicast federation of event channels - use this example. It deploys sender and receiver in the same - node and connects them through two eventchannels, using udp - multicast to communicate: - SenderNode[Sender --> ES_01 --> udp_sender -UDP{224.9.9.2:1234}-> - udp_mcast_receiver --> ES_02 --> Receiver] - - - (unresolved failure: - Create a receiver object with addr_serv_id: addr_serv_1 - (20850|3072210624) EXCEPTION, NodeApplication_Impl::finishLaunch - - system exception, ID 'IDL:omg.org/CORBA/UNKNOWN:1.0' - OMG minor code (1), described as 'Unlisted user exception received by c - lient.', completed = MAYBE - ) - -./ciao-events-federation-udp.ced -./deploymentplan_federation_udp.cdp -./run_test_udp.pl: - - In this example, udp communication is used to send the event - from one sender node to a receiver node: - SenderNode[Sender --> ES --> udp_sender] -UDP{localhost:1234}-> - ReceiverNode[udp_receiver --> ES_02 --> Receiver] - -./ciao-events-federation-udp-collocated.ced -./deploymentplan_federation_udp_collocated.cdp -./run_test_udp_collocated.pl: - - Same example, as the above udp example, but deployed on a - single node application and therefore collocated: - SenderNode[Sender --> ES_01 --> udp_sender -UDP{localhost:1234}-> - udp_receiver --> ES_02 --> Receiver] - -./ciao-events-federation-udp-two-hosts.ced -./deploymentplan_federation_udp_two_hosts.cdp - - this test is not yet automated, because the nodes are - supposed to be deployed on two different host machines: - SenderNode[Sender --> ES_01 --> udp_sender] - -UDP{129.59.129.181:1234}-> - ReceiverNode[udp_receiver --> ES_02 --> ReceiverNode] - -./ciao-events-example.ced -./deploymentplan_multiple_senders.cdp -./run_test_multiple_senders.pl: - - This example extends the standard example by adding two more sender - components to the SenderNode: - [Sender01 --> ] - SenderNode[Sender02 --> ES ] --> ReceiverNode[Receiver] - [Sender03 --> ] - - ------- - -author: Friedhelm Wolf (fwolf@dre.vanderbilt.edu) diff --git a/flat/CIAO/examples/Hello/descriptors_events/RunEventTest.pm b/flat/CIAO/examples/Hello/descriptors_events/RunEventTest.pm deleted file mode 100755 index 615cc0ee317..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/RunEventTest.pm +++ /dev/null @@ -1,212 +0,0 @@ -# $Id$ -# -*- perl -*- - -package RunEventTest; - -use lib "$ENV{'ACE_ROOT'}/bin"; -use PerlACE::Run_Test; - -$CIAO_ROOT = "$ENV{'CIAO_ROOT'}"; -$TAO_ROOT = "$ENV{'TAO_ROOT'}"; -$DAnCE = "$ENV{'CIAO_ROOT'}/DAnCE"; -$daemons_running = 0; -$em_running = 0; -$ns_running = 0; -$status = 0; -$dat_file = "NodeManagerMap.dat"; -$cdp_file = "flattened_deploymentplan_events.cdp"; -$controller_exec = "$CIAO_ROOT/examples/Hello/Sender/starter"; -$sender_ior = "Sender.ior"; -$receiver_ior = "Receiver.ior"; -$nodes; -$E = 0; -$EM = 0; - -$nsior = PerlACE::LocalFile ("ns.ior"); -unlink $nsior; - -sub parse_dat_file { - my $node_list; # array of hashes, containing node info - my $lines = 0; - - # read .dat file and parse it for node name, ip and port - open (my $fh, @_[0]) or die "could not open @_[0]"; - while(<$fh>) { - if (m{(\w+)\s+corbaloc:iiop:(\w*):([0-9]*)/NodeManager}) { - # store the three values in the according row - # of the array of hashest - $node_list->[$lines]->{"node"} = $1; - $node_list->[$lines]->{"ip"} = $2; - $node_list->[$lines++]->{"port"} = $3; - } - } - close ($fh) or die "could not close @_[0]"; - - return $node_list; -} - -# Delete if there are any .ior files. -sub delete_ior_files { - for ($i = 0; $i < scalar(@$nodes); ++$i) { - unlink $nodes->[$i]->{"node"} . ".ior"; - } - unlink PerlACE::LocalFile ("EM.ior"); - unlink PerlACE::LocalFile ($receiver_ior); - unlink PerlACE::LocalFile ($sender_ior); - unlink PerlACE::LocalFile ("DAM.ior"); - unlink PerlACE::LocalFile ("ns.ior"); -} - -sub kill_node_daemons { - for ($i = 0; $i < scalar(@$nodes); ++$i) { - $Daemons[$i]->Kill (); $Daemons[$i]->TimedWait (1); - } -} - -sub kill_open_processes { - if ($daemons_running == 1) { - kill_node_daemons (); - } - - if ($em_running == 1) { - $EM->Kill (); - $EM->TimedWait (1); - } - - if ($ns_running == 1) { - $NS->Kill (); - $NS->TimedWait (1); - } - -} - -sub run_node_daemons { - for ($i = 0; $i < scalar(@$nodes); ++$i) - { - $iorfile = $nodes->[$i]->{"node"} . ".ior"; - $iiop = "iiop://" . $nodes->[$i]->{"ip"} . ":" . $nodes->[$i]->{"port"}; - $node_app = "$CIAO_ROOT/bin/NodeApplication"; - - $d_cmd = "$CIAO_ROOT/bin/NodeManager"; - $d_param = "-ORBEndpoint $iiop -s $node_app -o $iorfile -d 30"; - - print $d_cmd . " " . $d_param . "\n"; - $Daemons[$i] = new PerlACE::Process ($d_cmd, $d_param); - $result = $Daemons[$i]->Spawn (); - push(@processes, $Daemons[$i]); - - if (PerlACE::waitforfile_timed ($iorfile, - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR - "ERROR: The ior file of node daemon $i could not be found\n"; - for (; $i >= 0; --$i) { - $Daemons[$i]->Kill (); $Daemons[$i]->TimedWait (1); - } - return -1; - } - } - return 0; -} - - -sub run_test { - # first argument will be interpreted as .cdp file - $cdp_file = shift; - # second argument will be interpreted as .dat file - $dat_file = shift; - - $nodes = parse_dat_file ($dat_file); - - delete_ior_files (); - - # Invoke naming service - $NS = new PerlACE::Process ("$TAO_ROOT/orbsvcs/Naming_Service/Naming_Service", "-m 0 -ORBEndpoint iiop://localhost:60003 -o ns.ior"); - $NS->Spawn (); - - print STDERR "Starting Naming Service\n"; - - if (PerlACE::waitforfile_timed ($nsior, $PerlACE::wait_interval_for_process_creation) == -1){ - print STDERR "ERROR: cannot find naming service IOR file\n"; - $NS->Kill (); - return 1; - } - - $ns_running = 1; - - # Invoke node daemons. - print "Invoking node daemons\n"; - $status = run_node_daemons (); - - if ($status != 0) { - print STDERR "ERROR: Unable to execute the node daemons\n"; - kill_open_processes (); - return 1; - } - - $daemons_running = 1; - - # Invoke execution manager. - print "Invoking execution manager\n"; - $EM = new PerlACE::Process ("$CIAO_ROOT/bin/Execution_Manager", - "-o EM.ior -i $dat_file"); - $EM->Spawn (); - - if (PerlACE::waitforfile_timed ("EM.ior", - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR - "ERROR: The ior file of execution manager could not be found\n"; - kill_open_processes (); - return 1; - } - - $em_running = 1; - - # Invoke executor - start the application -. - print "Invoking executor - start the application -\n"; - $E = - new PerlACE::Process ("$CIAO_ROOT/bin/plan_launcher", - "-p $cdp_file -k file://EM.ior -o DAM.ior"); - - $E->SpawnWaitKill (5000); - - if (PerlACE::waitforfile_timed ( - $receiver_ior, - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR "ERROR: The ior file of receiver could not be found\n"; - kill_open_processes (); - return 1; - } - - if (PerlACE::waitforfile_timed ($sender_ior, - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR "ERROR: The ior file of sender could not be found\n"; - kill_open_processes (); - return 1; - } - - print "Invoking the controller\n"; - $controller = new PerlACE::Process ("$controller_exec", "-k file://$sender_ior"); - $result = $controller->SpawnWaitKill (3000); - - if ($result != 0) { - print STDERR "ERROR: The controller returned $result\n"; - $status = 1; - } - - # Invoke executor - stop the application -. - print "Invoking executor - stop the application -\n"; - $E = - new PerlACE::Process ("$CIAO_ROOT/bin/plan_launcher", - "-k file://EM.ior -i file://DAM.ior"); - $E->SpawnWaitKill (3000); - - print "Executor returned.\n"; - print "Shutting down rest of the processes.\n"; - - delete_ior_files (); - kill_open_processes (); - - return $status; -} - -1; diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-collocated.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-collocated.ced deleted file mode 100644 index 1166a034caf..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-collocated.ced +++ /dev/null @@ -1,14 +0,0 @@ - - - - ES_01 - SenderNode - RTEC - svc.conf - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-federation.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-federation.ced deleted file mode 100644 index 930439f44d5..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-federation.ced +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - ES_01 - SenderNode - RTEC - dummy.conf - - - - addr_serv_0 - 1234 -
localhost
-
- - - upd_sender_1 - addr_serv_0 - -
- - - - ES_02 - SenderNode - RTEC - dummy.conf - - - addr_serv_1 - 1234 -
localhost
-
- - upd_receiver_1 - addr_serv_1 - false - 1234 - -
- -
diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-filters.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-filters.ced deleted file mode 100644 index affc0e49dc7..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example-with-filters.ced +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - ES_01 - SenderNode - RTEC - svc.conf - - - my_filter_01 - DISJUNCTION - Hello-Sender-idd_click_out - Hello-Sender-idd-02_click_out - - - - my_filter_02 - DISJUNCTION - Hello-Sender-idd_click_out - - - - my_filter_03 - CONJUNCTION - Hello-Sender-idd_click_out - Hello-Sender-idd-02_click_out - - - - my_filter_04 - CONJUNCTION - Hello-Sender-idd_click_out - - - - - - - ES_02 - SenderNode - RTEC - svc.conf - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example.ced deleted file mode 100644 index 1166a034caf..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-example.ced +++ /dev/null @@ -1,14 +0,0 @@ - - - - ES_01 - SenderNode - RTEC - svc.conf - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-mcast.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-mcast.ced deleted file mode 100644 index 9fa450602ba..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-mcast.ced +++ /dev/null @@ -1,58 +0,0 @@ - - - - - - ES_01 - SenderNode - RTEC - dummy.conf - - - my_filter - DISJUNCTION - Hello-Sender-idd_click_out - - - - - addr_serv_0 - 1234 -
224.9.9.2
-
- - - upd_sender_1 - addr_serv_0 - -
- - - - - ES_02 - SenderNode - RTEC - dummy.conf - - - addr_serv_1 - 1234 -
224.9.9.2
-
- - upd_receiver_1 - addr_serv_1 - true - - - 1234 - -
- - -
diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-collocated.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-collocated.ced deleted file mode 100644 index 89e85b5b21d..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-collocated.ced +++ /dev/null @@ -1,47 +0,0 @@ - - - - - - ES_01 - SenderNode - RTEC - dummy.conf - - - - addr_serv_0 - 1234 -
localhost
-
- - - upd_sender_1 - addr_serv_0 - -
- - - ES_02 - SenderNode - RTEC - dummy.conf - - - addr_serv_1 - 1234 -
localhost
-
- - upd_receiver_1 - addr_serv_1 - false - 1234 - -
- -
diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-two-hosts.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-two-hosts.ced deleted file mode 100644 index 5f65ab8375f..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp-two-hosts.ced +++ /dev/null @@ -1,50 +0,0 @@ - - - - - - - ES_01 - SenderNode - RTEC - dummy.conf - - - - addr_serv_0 - 1234 -
129.59.129.181
-
- - - upd_sender_1 - addr_serv_0 - -
- - - - - ES_02 - ReceiverNode - RTEC - dummy.conf - - - addr_serv_1 - 1234 -
129.59.129.181
-
- - upd_receiver_1 - addr_serv_1 - false - 1234 - -
- -
\ No newline at end of file diff --git a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp.ced b/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp.ced deleted file mode 100644 index 3d2a9d3fbb4..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/ciao-events-federation-udp.ced +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - ES_01 - SenderNode - RTEC - dummy.conf - - - - addr_serv_0 - 1234 -
localhost
-
- - - upd_sender_1 - addr_serv_0 - -
- - - - - ES_02 - ReceiverNode - RTEC - dummy.conf - - - addr_serv_1 - 1234 -
localhost
-
- - upd_receiver_1 - addr_serv_1 - false - 1234 - -
- -
diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events.cdp deleted file mode 100644 index a64e501402f..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events.cdp +++ /dev/null @@ -1,260 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_01 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Hello_Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Hello_Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-example.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events_collocated.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events_collocated.cdp deleted file mode 100644 index 79796d9177b..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_events_collocated.cdp +++ /dev/null @@ -1,260 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_01 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-example-collocated.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation.cdp deleted file mode 100644 index 423f9f65a2f..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation.cdp +++ /dev/null @@ -1,233 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_02 - - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-example-with-federation.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_mcast.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_mcast.cdp deleted file mode 100644 index 4bfddce8258..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_mcast.cdp +++ /dev/null @@ -1,231 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_02 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-federation-mcast.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp.cdp deleted file mode 100644 index 7ee891285a8..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp.cdp +++ /dev/null @@ -1,246 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_02 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Hello_Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Hello_Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Hello_Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-federation-udp.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_collocated.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_collocated.cdp deleted file mode 100644 index 0d254e2214e..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_collocated.cdp +++ /dev/null @@ -1,246 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_02 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Hello_Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-federation-udp-collocated.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_two_hosts.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_two_hosts.cdp deleted file mode 100644 index d7a0c7fcf00..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_federation_udp_two_hosts.cdp +++ /dev/null @@ -1,246 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - - hello_event_ec_consumer_connection - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_02 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-federation-udp-two-hosts.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_multiple_senders.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_multiple_senders.cdp deleted file mode 100644 index ff2ac89bf8f..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_multiple_senders.cdp +++ /dev/null @@ -1,395 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd-01 - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender01.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Sender-idd-02 - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender02.ior - - - - - - - local_message - - - tk_string - - - This is a test message from Sender 02 passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - red - - - - - - - - Hello-Sender-idd-03 - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender03.ior - - - - - - - local_message - - - tk_string - - - This is a test message from Sender 03 passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - white - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd-01 - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - - hello_event_ec_publisher_connection_01 - - click_out - EventPublisher - Hello-Sender-idd-01 - - - ES_01 - - - - - hello_event_ec_publisher_connection_02 - - click_out - EventPublisher - Hello-Sender-idd-02 - - - ES_01 - - - - - hello_event_ec_publisher_connection_03 - - click_out - EventPublisher - Hello-Sender-idd-03 - - - ES_01 - - - - - hello_event_ec_consumer_connection_01 - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_01 - - - - - - - - Hello_Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Hello_Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Hello_Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-example.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_with_filters.cdp b/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_with_filters.cdp deleted file mode 100644 index 7f776924945..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/deploymentplan_with_filters.cdp +++ /dev/null @@ -1,278 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - SenderNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - - hello_event_ec_publisher_connection - - click_out - EventPublisher - Hello-Sender-idd - - - ES_01 - - - - - hello_event_ec_consumer_connection - - - - EventFilter - my_filter_01 - - EventFilter - - - tk_string - - - my_filter_01 - - - - - - - click_in - EventConsumer - Hello-Receiver-idd - - - ES_01 - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Hello_Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - - - CIAOEvents - - - tk_string - - - ciao-events-example-with-filters.ced - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_events/rtec.conf b/flat/CIAO/examples/Hello/descriptors_events/rtec.conf deleted file mode 100644 index fbbadf78b0c..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/rtec.conf +++ /dev/null @@ -1 +0,0 @@ -static EC_Factory "-ECobserver basic" diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons.pl b/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons.pl deleted file mode 100755 index 8d76c400579..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons.pl +++ /dev/null @@ -1,40 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use lib "$ENV{ACE_ROOT}/bin"; -use PerlACE::Run_Test; - -$status = 0; -$iorfile1 = PerlACE::LocalFile ("NodeApp1.ior"); -$iorfile2 = PerlACE::LocalFile ("NodeApp2.ior"); - -#for ($iter = 0; $iter <= $#ARGV; $iter++) { -# if ($ARGV[$iter] eq "-h" || $ARGV[$iter] eq "-?") { -# print "Run_Test Perl script for NodeApplicationTest \n\n"; -# print "run_test \n"; -# print "\n"; -# print "-h -- prints this information\n"; -# exit 0; -# } -#} - - -unlink $iorfile1; -unlink $iorfile2; - -$CIAO_ROOT=$ENV{'CIAO_ROOT'}; - -$SV1 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://localhost:60001 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 500"); - -$SV2 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://localhost:60002 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 500"); - -$SV1->Spawn (); -$SV2->Spawn (); - -sleep (99999999999); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_svc_conf.pl b/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_svc_conf.pl deleted file mode 100755 index 8cdc79b11bd..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_svc_conf.pl +++ /dev/null @@ -1,42 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -$ACE_ROOT=$ENV{'ACE_ROOT'}; - -use lib "$ENV{'ACE_ROOT'}/bin"; -use PerlACE::Run_Test; - -$status = 0; -$iorfile1 = PerlACE::LocalFile ("NodeApp1.ior"); -$iorfile2 = PerlACE::LocalFile ("NodeApp2.ior"); - -#for ($iter = 0; $iter <= $#ARGV; $iter++) { -# if ($ARGV[$iter] eq "-h" || $ARGV[$iter] eq "-?") { -# print "Run_Test Perl script for NodeApplicationTest \n\n"; -# print "run_test \n"; -# print "\n"; -# print "-h -- prints this information\n"; -# exit 0; -# } -#} - - -unlink $iorfile1; -unlink $iorfile2; - -$CIAO_ROOT=$ENV{'CIAO_ROOT'}; - -$SV1 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://localhost:60001 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -c rtec.conf"); - -$SV2 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://localhost:60002 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -c rtec.conf"); - -$SV1->Spawn (); -$SV2->Spawn (); - -sleep (99999999999); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_with_ip.pl b/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_with_ip.pl deleted file mode 100644 index 24d630d66f6..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_NodeDaemons_with_ip.pl +++ /dev/null @@ -1,40 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use lib "$ENV{ACE_ROOT}/bin"; -use PerlACE::Run_Test; - -$status = 0; -$iorfile1 = PerlACE::LocalFile ("NodeApp1.ior"); -$iorfile2 = PerlACE::LocalFile ("NodeApp2.ior"); - -#for ($iter = 0; $iter <= $#ARGV; $iter++) { -# if ($ARGV[$iter] eq "-h" || $ARGV[$iter] eq "-?") { -# print "Run_Test Perl script for NodeApplicationTest \n\n"; -# print "run_test \n"; -# print "\n"; -# print "-h -- prints this information\n"; -# exit 0; -# } -#} - - -unlink $iorfile1; -unlink $iorfile2; - -$CIAO_ROOT=$ENV{'CIAO_ROOT'}; - -$SV1 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://129.59.129.181:60001 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 500"); - -$SV2 = new PerlACE::Process ("$CIAO_ROOT/bin/NodeManager", - "-ORBEndpoint iiop://129.59.129.181:60002 -s $CIAO_ROOT/DAnCE/NodeApplication/NodeApplication -d 500"); - -$SV1->Spawn (); -$SV2->Spawn (); - -sleep (99999999999); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test.pl deleted file mode 100755 index f01bafa0505..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test.pl +++ /dev/null @@ -1,49 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -# run_test_simple -$result = RunEventTest::run_test ( - "deploymentplan_events.cdp", - "NodeManagerMap.dat"); - -# run_test_collocated -$result += RunEventTest::run_test ( - "deploymentplan_events_collocated.cdp", - "NodeManagerMap_collocated.dat"); - -# run_test_federated -$result += RunEventTest::run_test ( - "deploymentplan_federation.cdp", - "NodeManagerMap_collocated.dat"); - -# run_test_filtered -$result += RunEventTest::run_test ( - "deploymentplan_with_filters.cdp", - "NodeManagerMap_collocated.dat"); - -# run_test_multicast -# this test is not running successfully and is therefore skipped here -#$result += RunEventTest::run_test ( -# "deploymentplan_federation_mcast.cdp", -# "NodeManagerMap_collocated.dat"); - -# run_test_udp -$result += RunEventTest::run_test ( - "deploymentplan_federation_udp.cdp", - "NodeManagerMap.dat"); - -# run_test_udp_collocated -$result += RunEventTest::run_test ( - "deploymentplan_federation_udp_collocated.cdp", - "NodeManagerMap_collocated.dat"); - -# run_test_multiple_senders is not yet integrated - -exit $result - diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_collocated.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_collocated.pl deleted file mode 100755 index c7d3e7c3dc4..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_collocated.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_events_collocated.cdp", - "NodeManagerMap_collocated.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_federated.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_federated.pl deleted file mode 100755 index 9d08455ce2e..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_federated.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_federation.cdp", - "NodeManagerMap_collocated.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_filtered.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_filtered.pl deleted file mode 100755 index d1371af7219..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_filtered.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_with_filters.cdp", - "NodeManagerMap_collocated.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_multicast.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_multicast.pl deleted file mode 100755 index 6d06589e3d2..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_multicast.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_federation_mcast.cdp", - "NodeManagerMap_collocated.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_multiple_senders.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_multiple_senders.pl deleted file mode 100755 index adac10d680c..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_multiple_senders.pl +++ /dev/null @@ -1,199 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use lib "$ENV{'ACE_ROOT'}/bin"; -use PerlACE::Run_Test; - -$CIAO_ROOT = "$ENV{'CIAO_ROOT'}"; -$TAO_ROOT = "$ENV{'TAO_ROOT'}"; -$DAnCE = "$ENV{'CIAO_ROOT'}/DAnCE"; -$daemons_running = 0; -$em_running = 0; -$ns_running = 0; -$daemons = 2; -@ports = ( 60001, 60002 ); -@iorfiles = ( "NodeApp1.ior", "NodeApp2.ior" ); -@senderiors = ( "Sender01.ior", "Sender02.ior", "Sender03.ior"); -$status = 0; -$dat_file = "NodeManagerMap.dat"; -$cdp_file = "deploymentplan_multiple_senders.cdp"; -$controller_exec = "$CIAO_ROOT/examples/Hello/Sender/starter"; - -$nsior = PerlACE::LocalFile ("ns.ior"); - -unlink $nsior; - -$E = 0; -$EM = 0; - -# Delete if there are any .ior files. -sub delete_ior_files { - for ($i = 0; $i < $daemons; ++$i) { - unlink $iorfiles[$i]; - } - unlink PerlACE::LocalFile ("EM.ior"); - unlink PerlACE::LocalFile ("Receiver.ior"); - - for ($r = 0; $r < @senderiors; ++$r) { - unlink PerlACE::LocalFile ($senderiors[$r]); - } - - unlink PerlACE::LocalFile ("DAM.ior"); - unlink PerlACE::LocalFile ("ns.ior"); -} - -sub kill_node_daemons { - for ($i = 0; $i < $daemons; ++$i) { - $Daemons[$i]->Kill (); $Daemons[$i]->TimedWait (1); - } -} - -sub kill_open_processes { - if ($daemons_running == 1) { - kill_node_daemons (); - } - - if ($em_running == 1) { - $EM->Kill (); - $EM->TimedWait (1); - } - - if ($ns_running == 1) { - $NS->Kill (); - $NS->TimedWait (1); - } -} - -sub run_node_daemons { - for ($i = 0; $i < $daemons; ++$i) - { - $iorfile = $iorfiles[$i]; - $port = $ports[$i]; - - $iiop = "iiop://localhost:$port"; - $node_app = "$CIAO_ROOT/bin/NodeApplication"; - - $d_cmd = "$CIAO_ROOT/bin/NodeManager"; - $d_param = "-ORBEndpoint $iiop -s $node_app -o $iorfile -d 30"; - - $Daemons[$i] = new PerlACE::Process ($d_cmd, $d_param); - $result = $Daemons[$i]->Spawn (); - push(@processes, $Daemons[$i]); - - if (PerlACE::waitforfile_timed ($iorfile, - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR - "ERROR: The ior file of node daemon $i could not be found\n"; - for (; $i >= 0; --$i) { - $Daemons[$i]->Kill (); $Daemons[$i]->TimedWait (1); - } - return -1; - } - } - return 0; -} - -delete_ior_files (); - -# Invoke naming service - -$NS = new PerlACE::Process ("$TAO_ROOT/orbsvcs/Naming_Service/Naming_Service", "-m 0 -ORBEndpoint iiop://localhost:60003 -o ns.ior"); - -$NS->Spawn (); - -print STDERR "Starting Naming Service\n"; - -if (PerlACE::waitforfile_timed ($nsior, $PerlACE::wait_interval_for_process_creation) == -1) -{ - print STDERR "ERROR: cannot find naming service IOR file\n"; - $NS->Kill (); - exit 1; -} - -$ns_running = 1; - -# Set up NamingService environment -$ENV{"NameServiceIOR"} = "corbaloc:iiop:localhost:60003/NameService"; - -# Invoke node daemons. -print "Invoking node daemons\n"; -$status = run_node_daemons (); - -if ($status != 0) { - print STDERR "ERROR: Unable to execute the node daemons\n"; - kill_open_processes (); - exit 1; -} - -$daemons_running = 1; - -# Invoke execution manager. -print "Invoking execution manager\n"; -$EM = new PerlACE::Process ("$CIAO_ROOT/bin/Execution_Manager", - "-o EM.ior -i $dat_file"); -$EM->Spawn (); - -if (PerlACE::waitforfile_timed ("EM.ior", - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR - "ERROR: The ior file of execution manager could not be found\n"; - kill_open_processes (); - exit 1; -} - -$em_running = 1; - -# Invoke executor - start the application -. -print "Invoking executor - start the application -\n"; -$E = - new PerlACE::Process ("$CIAO_ROOT/bin/plan_launcher", - "-p $cdp_file -k file://EM.ior -o DAM.ior"); - -$E->SpawnWaitKill (5000); - -if (PerlACE::waitforfile_timed ( - "Receiver.ior", - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR "ERROR: The ior file of receiver could not be found\n"; - kill_open_processes (); - exit 1; -} - -for ($si = 0; $si < @senderiors; ++$si) { - if (PerlACE::waitforfile_timed ($senderiors[$si], - $PerlACE::wait_interval_for_process_creation) == -1) { - print STDERR "ERROR: The file " . $senderiors[$si] . " could not be found\n"; - kill_open_processes (); - exit 1; - } -} - -for ($si = 0; $si < @senderiors; ++$si) { - print "Invoking the controller for sender $si\n"; - $controller = new PerlACE::Process ("$controller_exec", "-k file://" . $senderiors[$si]); - $result = $controller->SpawnWaitKill (3000); - - if ($result != 0) { - print STDERR "ERROR: The controller returned $result\n"; - $status = 1; - } -} - -# Invoke executor - stop the application -. -print "Invoking executor - stop the application -\n"; -$E = - new PerlACE::Process ("$CIAO_ROOT/bin/plan_launcher", - "-k file://EM.ior -i file://DAM.ior"); -$E->SpawnWaitKill (3000); - -print "Executor returned.\n"; -print "Shutting down rest of the processes.\n"; - -delete_ior_files (); -kill_open_processes (); - -exit $status; diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_simple.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_simple.pl deleted file mode 100755 index c678aa29545..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_simple.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_events.cdp", - "NodeManagerMap.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_udp.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_udp.pl deleted file mode 100755 index c84f30dcd30..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_udp.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_federation_udp.cdp", - "NodeManagerMap.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_events/run_test_udp_collocated.pl b/flat/CIAO/examples/Hello/descriptors_events/run_test_udp_collocated.pl deleted file mode 100755 index d45d68c238e..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_events/run_test_udp_collocated.pl +++ /dev/null @@ -1,12 +0,0 @@ -eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' - & eval 'exec perl -S $0 $argv:q' - if 0; - -# $Id$ -# -*- perl -*- - -use RunEventTest; - -exit RunEventTest::run_test ( - "deploymentplan_federation_udp_collocated.cdp", - "NodeManagerMap_collocated.dat"); diff --git a/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan.cdp b/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan.cdp deleted file mode 100644 index f2e55b93539..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan.cdp +++ /dev/null @@ -1,224 +0,0 @@ - - - - Hello_Plan_UUID_0001 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - Receiver.ior - - - - - - - - hello_event_connection - - click_out - EventPublisher - Hello-Sender-idd - - - click_in - EventConsumer - Hello-Receiver-idd - - - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - diff --git a/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan_shared_components.cdp b/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan_shared_components.cdp deleted file mode 100644 index 912bab194c5..00000000000 --- a/flat/CIAO/examples/Hello/descriptors_shared_components/deploymentplan_shared_components.cdp +++ /dev/null @@ -1,229 +0,0 @@ - - - - Hello_Plan_UUID_0002 - - - - c0965470-7b83-11d9-9669-0800200c9a66 - - IDL:BasicSP/EC:1.0 - - read_message - IDL:Hello/ReadMessage:1.0 - IDL:Hello/ReadMessage:1.0 - false - false - true - false - SimplexReceptacle - - - - - Hello-Sender-mdd - - Hello-Sender_exec - Hello-Sender_svnt - - - - - Hello-Receiver-mdd - - Hello-Receiver_exec - Hello-Receiver_svnt - - - - - Hello-Sender-idd-new-component - SenderNode - - Hello-Sender-mdd - - - - ComponentIOR - - - tk_string - - - Sender_new_component.ior - - - - - - - local_message - - - tk_string - - - This is a test message passed in through XML. - - - - - - - color - - - tk_enum - - COLOR_SELECTION - IDL:Hello/COLOR_SELECTION:1.0 - empty - white - red - yellow - - - - yellow - - - - - - - Hello-Receiver-idd - ReceiverNode - - Hello-Receiver-mdd - - ComponentIOR - - - tk_string - - - - Receiver_new_component.ior - - - - - - - - hello_event_connection - - click_out - EventPublisher - Hello-Sender-idd-new-component - - - click_in - EventConsumer - Hello-Receiver-idd - - - - - - hello_facet_connection - - push_message - Facet - Hello-Sender-idd-new-component - - - read_message - SimplexReceptacle - Hello-Receiver-idd - - - - - - - Sender_exec - - - Hello_Sender_exec - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Impl - - - - - - - Sender_svnt - - - Hello_Sender_svnt - - entryPoint - - - tk_string - - - create_Hello_SenderHome_Servant - - - - - - - Receiver_exec - - - Hello_Receiver_exec - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Impl - - - - - - - Receiver_svnt - - - Hello_Receiver_svnt - - entryPoint - - - tk_string - - - create_Hello_ReceiverHome_Servant - - - - - diff --git a/flat/CIAO/tools/Config_Handlers/XSCRT/Elements.hpp b/flat/CIAO/tools/Config_Handlers/XSCRT/Elements.hpp index 7c2b1c58d34..e6fed66171e 100644 --- a/flat/CIAO/tools/Config_Handlers/XSCRT/Elements.hpp +++ b/flat/CIAO/tools/Config_Handlers/XSCRT/Elements.hpp @@ -8,6 +8,7 @@ #include #include #include +#include // #include //@@ tmp #include "XSCRT/Parser.hpp" diff --git a/flat/CIAO/tools/XML/XML_Helper.h b/flat/CIAO/tools/XML/XML_Helper.h index 9ec3d0348cb..69f887cbe40 100644 --- a/flat/CIAO/tools/XML/XML_Helper.h +++ b/flat/CIAO/tools/XML/XML_Helper.h @@ -23,6 +23,8 @@ #include "xercesc/util/XercesDefs.hpp" #include "xercesc/parsers/XercesDOMParser.hpp" +#include + namespace XERCES_CPP_NAMESPACE { class DOMDocument; -- cgit v1.2.1