summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/tests/EC_Multiple
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/orbsvcs/tests/EC_Multiple')
-rw-r--r--TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.cpp714
-rw-r--r--TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.h184
-rw-r--r--TAO/orbsvcs/tests/EC_Multiple/Makefile63
-rw-r--r--TAO/orbsvcs/tests/EC_Multiple/README29
4 files changed, 0 insertions, 990 deletions
diff --git a/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.cpp b/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.cpp
deleted file mode 100644
index 07e3c0b8f2a..00000000000
--- a/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.cpp
+++ /dev/null
@@ -1,714 +0,0 @@
-//
-// $Id$
-//
-
-#include "ace/Get_Opt.h"
-
-#include "tao/Timeprobe.h"
-#include "orbsvcs/Event_Utilities.h"
-#include "orbsvcs/Event_Service_Constants.h"
-#include "orbsvcs/Scheduler_Factory.h"
-#include "orbsvcs/Time_Utilities.h"
-#include "orbsvcs/RtecEventChannelAdminC.h"
-#include "orbsvcs/Event/Event_Channel.h"
-#include "EC_Multiple.h"
-
-// ************************************************************
-
-EC_Proxy::EC_Proxy (void)
- : consumer_ (this),
- supplier_ (this)
-{
-}
-
-EC_Proxy::~EC_Proxy (void)
-{
-}
-
-int
-EC_Proxy::open (RtecEventChannelAdmin::EventChannel_ptr remote_ec,
- RtecEventChannelAdmin::EventChannel_ptr local_ec,
- const RtecEventChannelAdmin::ConsumerQOS& subscriptions,
- const RtecEventChannelAdmin::SupplierQOS& publications,
- CORBA::Environment &_env)
-{
- ACE_UNUSED_ARG (_env);
-
- TAO_TRY
- {
- // = Connect as a supplier to the local EC
- RtecEventChannelAdmin::SupplierAdmin_var supplier_admin =
- local_ec->for_suppliers (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->consumer_proxy_ =
- supplier_admin->obtain_push_consumer (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- RtecEventComm::PushSupplier_var supplier_ref =
- this->supplier_._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->consumer_proxy_->connect_push_supplier (supplier_ref.in (),
- publications,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- RtecEventChannelAdmin::ConsumerAdmin_var consumer_admin =
- remote_ec->for_consumers (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->supplier_proxy_ =
- consumer_admin->obtain_push_supplier (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- RtecEventComm::PushConsumer_var consumer_ref =
- this->consumer_._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->supplier_proxy_->connect_push_consumer (consumer_ref.in (),
- subscriptions,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
- }
- TAO_CATCHANY
- {
- TAO_TRY_ENV.print_exception ("EC_Proxy::open");
- return -1;
- }
- TAO_ENDTRY;
-
- return 0;
-}
-
-void
-EC_Proxy::disconnect_push_consumer (CORBA::Environment &)
-{
- ACE_DEBUG ((LM_DEBUG,
- "Supplier-consumer received disconnect from channel.\n"));
-}
-
-void
-EC_Proxy::disconnect_push_supplier (CORBA::Environment &)
-{
- ACE_DEBUG ((LM_DEBUG,
- "Supplier received disconnect from channel.\n"));
-}
-
-void
-EC_Proxy::push (const RtecEventComm::EventSet &events,
- CORBA::Environment & _env)
-{
- // ACE_DEBUG ((LM_DEBUG, "EC_Proxy::push - "));
-
- if (events.length () == 0)
- {
- // ACE_DEBUG ((LM_DEBUG, "no events\n"));
- return;
- }
-
- // ACE_DEBUG ((LM_DEBUG, "ECP: %d event(s)\n", events.length ()));
-
- // @@ TODO, there is an extra data copy here, we should do the event
- // modification without it and only compact the necessary events.
- int count = 0;
- RtecEventComm::EventSet out (events.length ());
- for (u_int i = 0; i < events.length (); ++i)
- {
- if (events[i].ttl_ > 0)
- {
- count++;
- out.length (count);
- out[count - 1] = events[i];
- out[count - 1].ttl_--;
- }
- }
-
- if (count > 0)
- {
- this->consumer_proxy_->push (out, _env);
- }
-}
-
-int
-EC_Proxy::shutdown (CORBA::Environment& _env)
-{
- TAO_TRY
- {
- this->consumer_proxy_->disconnect_push_consumer (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- // Disconnect from the push supplier.
- this->supplier_proxy_->disconnect_push_supplier (TAO_TRY_ENV);
- TAO_CHECK_ENV;
- }
- TAO_CATCHANY
- {
- TAO_RETHROW_RETURN(-1);
- }
- TAO_ENDTRY;
-
- return 0;
-}
-
-// ****************************************************************
-
-Test_ECP::Test_ECP (void)
- : consumer_ (this),
- supplier_ (this),
- event_a_ (0),
- event_b_ (0),
- event_c_ (0),
- interval_ (250),
- message_count_ (100)
-{
-}
-
-int
-Test_ECP::run (int argc, char* argv[])
-{
- TAO_TRY
- {
- CORBA::ORB_var orb =
- CORBA::ORB_init (argc, argv, "internet", TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- CORBA::Object_var poa_object =
- orb->resolve_initial_references("RootPOA");
- if (CORBA::is_nil (poa_object.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to initialize the POA.\n"),
- 1);
-
- PortableServer::POA_var root_poa =
- PortableServer::POA::_narrow (poa_object.in (), TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- PortableServer::POAManager_var poa_manager =
- root_poa->the_POAManager (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- if (this->parse_args (argc, argv))
- return 1;
-
- CORBA::Object_var naming_obj =
- orb->resolve_initial_references ("NameService");
- if (CORBA::is_nil (naming_obj.in ()))
- ACE_ERROR_RETURN ((LM_ERROR,
- " (%P|%t) Unable to get the Naming Service.\n"),
- 1);
-
- CosNaming::NamingContext_var naming_context =
- CosNaming::NamingContext::_narrow (naming_obj.in (), TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_Scheduler_Factory::use_config (naming_context.in ());
-
- // Register Event_Service with Naming Service.
- ACE_EventChannel ec_impl;
-
- RtecEventChannelAdmin::EventChannel_var ec =
- ec_impl._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- CORBA::String_var str =
- orb->object_to_string (ec.in (), TAO_TRY_ENV);
-
- ACE_DEBUG ((LM_DEBUG, "The (local) EC IOR is <%s>\n", str.in ()));
-
- CosNaming::Name channel_name (1);
- channel_name.length (1);
- channel_name[0].id = CORBA::string_dup (this->lcl_ec_name_);
- naming_context->bind (channel_name, ec.in (), TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_DEBUG ((LM_DEBUG, "waiting to start\n"));
- ACE_Time_Value tv (15, 0);
-
- poa_manager->activate (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- if (orb->run (&tv) == -1)
- ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "orb->run"), 1);
-
- ACE_DEBUG ((LM_DEBUG, "starting....\n"));
-
- RtecEventChannelAdmin::EventChannel_var remote_ec =
- this->get_ec (naming_context.in (),
- this->rmt_ec_name_,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_DEBUG ((LM_DEBUG, "located remote EC\n"));
-
- RtecEventChannelAdmin::EventChannel_var local_ec =
- this->get_ec (naming_context.in (),
- this->lcl_ec_name_,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_DEBUG ((LM_DEBUG, "located local EC\n"));
-
- if (this->connect_supplier (local_ec.in (),
- TAO_TRY_ENV) == -1)
- return 1;
-
- ACE_DEBUG ((LM_DEBUG, "connected supplier\n"));
-
- if (this->connect_consumer (local_ec.in (),
- TAO_TRY_ENV) == -1)
- return 1;
-
- ACE_DEBUG ((LM_DEBUG, "connected consumer\n"));
-
- if (this->connect_ecp (local_ec.in (),
- remote_ec.in (),
- TAO_TRY_ENV) == -1)
- return 1;
-
- ACE_DEBUG ((LM_DEBUG, "connected proxy\n"));
-
- ACE_DEBUG ((LM_DEBUG, "running multiple EC test\n"));
- if (orb->run () == -1)
- ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "orb->run"), 1);
- }
- TAO_CATCH (CORBA::SystemException, sys_ex)
- {
- TAO_TRY_ENV.print_exception ("SYS_EX");
- }
- TAO_ENDTRY;
- return 0;
-}
-
-RtecEventChannelAdmin::EventChannel_ptr
-Test_ECP::get_ec (CosNaming::NamingContext_ptr naming_context,
- const char* ec_name,
- CORBA::Environment &_env)
-{
- CosNaming::Name channel_name (1);
- channel_name.length (1);
- channel_name[0].id = CORBA::string_dup (ec_name);
-
- CORBA::Object_ptr ec_ptr =
- naming_context->resolve (channel_name, _env);
- if (_env.exception () != 0 || CORBA::is_nil (ec_ptr))
- return RtecEventChannelAdmin::EventChannel::_nil ();
-
- return RtecEventChannelAdmin::EventChannel::_narrow (ec_ptr, _env);
-}
-
-int
-Test_ECP::connect_supplier (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- CORBA::Environment &_env)
-{
- TAO_TRY
- {
- char buf[BUFSIZ];
- ACE_OS::strcpy (buf, "supplier@");
- ACE_OS::strcat (buf, this->lcl_ec_name_);
-
- RtecScheduler::Scheduler_ptr server =
- ACE_Scheduler_Factory::server ();
-
- RtecScheduler::handle_t rt_info =
- server->create (buf, TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- server->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- this->interval_ * 10000, // @@ Make it parametric
- RtecScheduler::VERY_LOW_IMPORTANCE,
- ORBSVCS_Time::zero,
- 1,
- RtecScheduler::OPERATION,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->supplier_id_ = ACE::crc32 (buf);
-
- ACE_SupplierQOS_Factory qos;
- qos.insert (this->supplier_id_,
- this->event_a_,
- rt_info, 1);
- qos.insert (this->supplier_id_,
- this->event_b_,
- rt_info, 1);
- qos.insert (this->supplier_id_,
- ACE_ES_EVENT_SHUTDOWN,
- rt_info, 1);
-
- RtecEventChannelAdmin::SupplierAdmin_var supplier_admin =
- local_ec->for_suppliers (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->consumer_proxy_ =
- supplier_admin->obtain_push_consumer (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- RtecEventComm::PushSupplier_var objref =
- this->supplier_._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->consumer_proxy_->connect_push_supplier (objref.in (),
- qos.get_SupplierQOS (),
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
- }
- TAO_CATCHANY
- {
- TAO_RETHROW_RETURN (-1);
- }
- TAO_ENDTRY;
- return 0;
-}
-
-int
-Test_ECP::connect_consumer (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- CORBA::Environment &_env)
-{
- TAO_TRY
- {
- RtecScheduler::Scheduler_ptr server =
- ACE_Scheduler_Factory::server ();
-
- char buf[BUFSIZ];
- ACE_OS::strcpy (buf, "consumer@");
- ACE_OS::strcat (buf, this->lcl_ec_name_);
-
- RtecScheduler::handle_t rt_info =
- server->create (buf, TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- server->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- this->interval_ * 10000, // @@ Make it parametric
- RtecScheduler::VERY_LOW_IMPORTANCE,
- ORBSVCS_Time::zero,
- 1,
- RtecScheduler::OPERATION,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_Time_Value tv_timeout (0, this->interval_ * 1000);
- TimeBase::TimeT timeout;
- ORBSVCS_Time::Time_Value_to_TimeT (timeout, tv_timeout);
-
- ACE_ConsumerQOS_Factory qos;
- qos.start_disjunction_group ();
- qos.insert_type (ACE_ES_EVENT_SHUTDOWN,
- rt_info);
- qos.insert_time (ACE_ES_EVENT_INTERVAL_TIMEOUT,
- timeout,
- rt_info);
- qos.insert_type (this->event_a_, rt_info);
- qos.insert_type (this->event_c_, rt_info);
-
- // = Connect as a consumer.
- RtecEventChannelAdmin::ConsumerAdmin_var consumer_admin =
- local_ec->for_consumers (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->supplier_proxy_ =
- consumer_admin->obtain_push_supplier (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- RtecEventComm::PushConsumer_var objref =
- this->consumer_._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- this->supplier_proxy_->connect_push_consumer (objref.in (),
- qos.get_ConsumerQOS (),
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
- }
- TAO_CATCHANY
- {
- TAO_RETHROW_RETURN (-1);
- }
- TAO_ENDTRY;
-
- return 0;
-}
-
-int
-Test_ECP::connect_ecp (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- RtecEventChannelAdmin::EventChannel_ptr remote_ec,
- CORBA::Environment &_env)
-{
- TAO_TRY
- {
- RtecScheduler::Scheduler_ptr server =
- ACE_Scheduler_Factory::server ();
-
- // Generate its ConsumerQOS
- char rmt[BUFSIZ];
- ACE_OS::strcpy (rmt, "ecp@");
- ACE_OS::strcat (rmt, this->rmt_ec_name_);
-
- RtecScheduler::handle_t rmt_info =
- server->create (rmt, TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- server->set (rmt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- this->interval_ * 10000,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- ORBSVCS_Time::zero,
- 1,
- RtecScheduler::OPERATION,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- ACE_ConsumerQOS_Factory consumer_qos;
- consumer_qos.start_disjunction_group ();
- consumer_qos.insert_type (this->event_a_, rmt_info);
- consumer_qos.insert_type (this->event_c_, rmt_info);
- consumer_qos.insert_type (ACE_ES_EVENT_SHUTDOWN, rmt_info);
-
- // Generate its SupplierQOS
- char lcl[BUFSIZ];
- ACE_OS::strcpy (lcl, "ecp@");
- ACE_OS::strcat (lcl, this->lcl_ec_name_);
-
- RtecScheduler::handle_t lcl_info =
- server->create (lcl, TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- server->set (lcl_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- ORBSVCS_Time::zero,
- this->interval_ * 10000,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- ORBSVCS_Time::zero,
- 1,
- RtecScheduler::OPERATION,
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- CORBA::ULong supplier_id = ACE::crc32 (lcl);
-
- ACE_SupplierQOS_Factory supplier_qos;
- supplier_qos.insert (supplier_id,
- this->event_a_,
- lcl_info, 1);
- supplier_qos.insert (supplier_id,
- this->event_c_,
- lcl_info, 1);
- supplier_qos.insert (supplier_id,
- ACE_ES_EVENT_SHUTDOWN,
- lcl_info, 1);
-
- this->ecp_.open (remote_ec, local_ec,
- consumer_qos.get_ConsumerQOS (),
- supplier_qos.get_SupplierQOS (),
- TAO_TRY_ENV);
- TAO_CHECK_ENV;
- }
- TAO_CATCHANY
- {
- TAO_RETHROW_RETURN (-1);
- }
- TAO_ENDTRY;
-
- return 0;
-}
-
-void
-Test_ECP::disconnect_push_consumer (CORBA::Environment &)
-{
- ACE_DEBUG ((LM_DEBUG,
- "Supplier-consumer received disconnect from channel.\n"));
-}
-
-void
-Test_ECP::disconnect_push_supplier (CORBA::Environment &)
-{
- ACE_DEBUG ((LM_DEBUG,
- "Supplier received disconnect from channel.\n"));
-}
-
-void
-Test_ECP::push (const RtecEventComm::EventSet &events,
- CORBA::Environment & _env)
-{
- // ACE_DEBUG ((LM_DEBUG, "EC_Proxy::push - "));
-
- if (events.length () == 0)
- {
- // ACE_DEBUG ((LM_DEBUG, "no events\n"));
- return;
- }
-
- // ACE_DEBUG ((LM_DEBUG, "%d event(s)\n", events.length ()));
-
- for (u_int i = 0; i < events.length (); ++i)
- {
- const RtecEventComm::Event& e = events[i];
- if (e.type_ == ACE_ES_EVENT_INTERVAL_TIMEOUT)
- {
- this->message_count_--;
-
- RtecEventComm::EventSet sent (1);
- sent.length (1);
-
- RtecEventComm::Event& s = sent[0];
- s.source_ = this->supplier_id_;
- s.ttl_ = 1;
-
- ACE_hrtime_t t = ACE_OS::gethrtime ();
- ORBSVCS_Time::hrtime_to_TimeT (s.creation_time_, t);
- s.ec_recv_time_ = ORBSVCS_Time::zero;
- s.ec_send_time_ = ORBSVCS_Time::zero;
-
- s.data_.x = 0;
- s.data_.y = 0;
-
- if (this->message_count_ == 0)
- {
- s.type_ = ACE_ES_EVENT_SHUTDOWN;
- }
- else if (this->message_count_ % 2 == 0)
- {
- // Generate an A event...
- s.type_ = this->event_a_;
- }
- else
- {
- s.type_ = this->event_b_;
- }
-
- this->consumer_proxy_->push (sent, _env);
- //ACE_DEBUG ((LM_DEBUG, "Sent %d events\n", n));
- }
- else if (e.type_ == ACE_ES_EVENT_SHUTDOWN)
- {
- this->shutdown (_env);
- }
- else
- {
- // Print out the events received...
- // ACE_DEBUG ((LM_DEBUG, "Received event %d from %04.4x\n",
- // e.type_, e.source_));
-
- // @@ TODO Keep statistics....
- ACE_hrtime_t r = ACE_OS::gethrtime ();
- ACE_hrtime_t s;
- ORBSVCS_Time::TimeT_to_hrtime (s, e.creation_time_);
- int nsec = r - s;
- ACE_DEBUG ((LM_DEBUG, "Latency[%d]: %d (from %d)\n",
- this->supplier_id_, nsec, e.source_));
- }
- }
-}
-
-int
-Test_ECP::shutdown (CORBA::Environment& _env)
-{
- this->consumer_proxy_->disconnect_push_consumer (_env);
- if (_env.exception () != 0) return -1;
-
- this->supplier_proxy_->disconnect_push_supplier (_env);
- if (_env.exception () != 0) return -1;
-
- this->ecp_.shutdown (_env);
- if (_env.exception () != 0) return -1;
-
- TAO_ORB_Core_instance ()->orb ()->shutdown ();
- return 0;
-}
-
-int
-Test_ECP::parse_args (int argc, char *argv [])
-{
- ACE_Get_Opt get_opt (argc, argv, "l:r:a:b:c:t:m:");
- int opt;
-
- while ((opt = get_opt ()) != EOF)
- {
- switch (opt)
- {
- case 'l':
- this->lcl_ec_name_ = get_opt.optarg;
- break;
- case 'r':
- this->rmt_ec_name_ = get_opt.optarg;
- break;
- case 'a':
- this->event_a_ =
- ACE_ES_EVENT_UNDEFINED + ACE_OS::atoi (get_opt.optarg);
- break;
- case 'b':
- this->event_b_ =
- ACE_ES_EVENT_UNDEFINED + ACE_OS::atoi (get_opt.optarg);
- break;
- case 'c':
- this->event_c_ =
- ACE_ES_EVENT_UNDEFINED + ACE_OS::atoi (get_opt.optarg);
- break;
- case 't':
- this->interval_ = ACE_OS::atoi (get_opt.optarg);
- break;
- case 'm':
- this->message_count_ = ACE_OS::atoi (get_opt.optarg);
- break;
- case '?':
- default:
- ACE_DEBUG ((LM_DEBUG,
- "Usage: %s "
- "-l local_ec_name "
- "-r remote_ec_name "
- "<-a event_type_a> "
- "<-b event_type_b> "
- "<-c event_type_c> "
- "-t event_interval "
- "-m message_count "
- "\n",
- argv[0]));
- return -1;
- }
- }
-
- if (this->event_a_ <= 0
- || this->event_b_ <= 0
- || this->event_c_ <= 0 )
- {
- ACE_DEBUG ((LM_DEBUG,
- "%s: you must specify the event types\n",
- argv[0]));
- return -1;
- }
-
- return 0;
-}
-
-// ****************************************************************
-
-int
-main (int argc, char *argv [])
-{
- Test_ECP test;
- return test.run (argc, argv);
-}
-
-#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION)
-template class ACE_PushConsumer_Adapter<Test_ECP>;
-template class ACE_PushSupplier_Adapter<Test_ECP>;
-template class ACE_PushConsumer_Adapter<EC_Proxy>;
-template class ACE_PushSupplier_Adapter<EC_Proxy>;
-#elif defined(ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA)
-#pragma instantiate ACE_PushConsumer_Adapter<Test_ECP>
-#pragma instantiate ACE_PushSupplier_Adapter<Test_ECP>
-#pragma instantiate ACE_PushConsumer_Adapter<EC_Proxy>
-#pragma instantiate ACE_PushSupplier_Adapter<EC_Proxy>
-#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */
diff --git a/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.h b/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.h
deleted file mode 100644
index de3a58139ef..00000000000
--- a/TAO/orbsvcs/tests/EC_Multiple/EC_Multiple.h
+++ /dev/null
@@ -1,184 +0,0 @@
-/* -*- C++ -*- */
-// $Id$
-//
-// ============================================================================
-//
-// = DESCRIPTION
-// This test attempts to communicate several Event Channels.
-// The test hardcodes all the objects involved (consumers,
-// suppliers, proxies, etc.); the objective is to gain understanding
-// on the architecture needed to exploit locality in the Event
-// cycle, not to provide a definite solution.
-//
-// ============================================================================
-
-#if !defined (EC_MULTIPLE_H)
-#define EC_MULTIPLE_H
-
-#include "ace/SString.h"
-#include "orbsvcs/RtecEventChannelAdminC.h"
-#include "orbsvcs/RtecEventCommS.h"
-#include "orbsvcs/Channel_Clients_T.h"
-
-
-class EC_Proxy
-// = TITLE
-// Event Channel Proxy.
-//
-// = DESCRIPTION
-// This class mediates among two event channels, it connects as a
-// consumer of events with a remote event channel, and as a supplier
-// of events with the local EC.
-// As a consumer it gives a QoS designed to only accept the events
-// in which *local* consumers are interested.
-// Eventually the local EC should create this object and compute its
-// QoS in an automated manner; but this requires some way to filter
-// out the peers registered as consumers, otherwise we will get
-// loops in the QoS graph.
-// It uses exactly the same set of events in the publications list
-// when connected as a supplier.
-//
-// = NOTES
-// An alternative implementation would be to register with the
-// remote EC as a supplier, and then filter on the remote EC, but
-// one of the objectives is to minimize network traffic.
-// On the other hand the events will be pushed to remote consumers,
-// event though they will be dropped upon receipt (due to the TTL
-// field); IMHO this is another suggestion that the EC needs to know
-// (somehow) which consumers are truly its peers in disguise.
-//
-// = ALTERNATIVES
-// Check http://www.cs.wustl.edu/~coryan/Multiple_EC.html for a
-// discussion on that topic.
-//
-{
-public:
- EC_Proxy (void);
- ~EC_Proxy (void);
-
- int open (RtecEventChannelAdmin::EventChannel_ptr remote_ec,
- RtecEventChannelAdmin::EventChannel_ptr local_ec,
- const RtecEventChannelAdmin::ConsumerQOS& subscriptions,
- const RtecEventChannelAdmin::SupplierQOS& publications,
- CORBA::Environment &_env);
- // Establish the connections.
-
- void disconnect_push_supplier (CORBA::Environment &);
- // The channel is disconnecting.
-
- void disconnect_push_consumer (CORBA::Environment &);
- // The channel is disconnecting.
-
- void push (const RtecEventComm::EventSet &events,
- CORBA::Environment &);
- // This is the Consumer side behavior, it pushes the events to the
- // local event channel.
-
- int shutdown (CORBA::Environment&);
-
-private:
- ACE_PushConsumer_Adapter<EC_Proxy> consumer_;
- // Our consumer personality....
-
- ACE_PushSupplier_Adapter<EC_Proxy> supplier_;
- // Our supplier personality....
-
- RtecEventChannelAdmin::ProxyPushConsumer_var consumer_proxy_;
- // We talk to the EC (as a supplier) using this proxy.
-
- RtecEventChannelAdmin::ProxyPushSupplier_var supplier_proxy_;
- // We talk to the EC (as a consumer) using this proxy.
-};
-
-class Test_ECP
-//
-// = TITLE
-// A simple test for the EC_Proxy class.
-//
-// = DESCRIPTION
-// This class is design to exercise several features of the EC_Proxy
-// class and the multiple EC architecture.
-// We want to create two EC, each one having a single supplier and a
-// single consumer.
-// + To test the remote facilities the consumer register for both a
-// local event and a remote one.
-// + To test the remote filtering features the remote consumer only
-// wants one of the local events, and this event is generated less
-// frequently.
-//
-// This class creates the local ECP a consumer and a supplier, it
-// uses the command line to figure the
-//
-{
-public:
- Test_ECP (void);
-
- int run (int argc, char* argv[]);
- // Execute the test.
-
- void disconnect_push_supplier (CORBA::Environment &);
- void disconnect_push_consumer (CORBA::Environment &);
- void push (const RtecEventComm::EventSet &events,
- CORBA::Environment &);
- // Implement the consumer and supplier upcalls.
-
-
-private:
- int parse_args (int argc, char* argv[]);
-
- RtecEventChannelAdmin::EventChannel_ptr
- get_ec (CosNaming::NamingContext_ptr naming_context,
- const char* ec_name,
- CORBA::Environment &_env);
-
- int connect_supplier (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- CORBA::Environment &_env);
- int connect_consumer (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- CORBA::Environment &_env);
- int connect_ecp (RtecEventChannelAdmin::EventChannel_ptr local_ec,
- RtecEventChannelAdmin::EventChannel_ptr remote_ec,
- CORBA::Environment &_env);
-
- int shutdown (CORBA::Environment&);
-
-private:
- ACE_PushConsumer_Adapter<Test_ECP> consumer_;
- // Our consumer personality....
-
- ACE_PushSupplier_Adapter<Test_ECP> supplier_;
- // Our supplier personality....
-
- EC_Proxy ecp_;
- // The proxy used to connect both event channels.
-
- RtecEventChannelAdmin::ProxyPushConsumer_var consumer_proxy_;
- // We talk to the EC (as a supplier) using this proxy.
-
- RtecEventChannelAdmin::ProxyPushSupplier_var supplier_proxy_;
- // We talk to the EC (as a consumer) using this proxy.
-
- RtecEventComm::EventSourceID supplier_id_;
- // Our ID as a supplier.
-
- char* rmt_ec_name_;
- // The name of the "remote" EC.
-
- char* lcl_ec_name_;
- // The name of the "local" EC.
-
- int event_a_;
- int event_b_;
- int event_c_;
- // We generate events <a> and <b> and receive events <a> and <c>,
- // this allows for a lot of configurations (making a == c or
- // different, etc.)
-
- int interval_;
- // The interval between the messages.
-
- int message_count_;
- // How many messages will we send...
-};
-
-
-#endif /* EC_MULTIPLE_H */
diff --git a/TAO/orbsvcs/tests/EC_Multiple/Makefile b/TAO/orbsvcs/tests/EC_Multiple/Makefile
deleted file mode 100644
index b112de5963b..00000000000
--- a/TAO/orbsvcs/tests/EC_Multiple/Makefile
+++ /dev/null
@@ -1,63 +0,0 @@
-# $Id$
-
-BIN = EC_Multiple
-
-BUILD = $(BIN)
-
-EC_MULTIPLE_SRCS= \
- EC_Multiple.cpp
-
-LSRC= \
- $(EC_MULTIPLE_SRCS) \
-
-EC_MULTIPLE_OBJS = $(EC_MULTIPLE_SRCS:.cpp=.o)
-
-LDLIBS= -lorbsvcs -lTAO
-
-#----------------------------------------------------------------------------
-# Include macros and targets
-#----------------------------------------------------------------------------
-
-include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU
-include $(ACE_ROOT)/include/makeinclude/macros.GNU
-include $(ACE_ROOT)/include/makeinclude/rules.common.GNU
-include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU
-include $(ACE_ROOT)/include/makeinclude/rules.local.GNU
-
-ifdef quantify
- CCFLAGS += -Dquantify
- CPPFLAGS += -I/pkg/purify/quantify-2.1-solaris2
-endif # quantify
-
-#### Local rules and variables...
-
-ifndef TAO_ROOT
-TAO_ROOT = $(ACE_ROOT)/TAO
-endif
-TSS_ORB_FLAG = #-DTAO_HAS_TSS_ORBCORE
-DCFLAGS = -g
-LDFLAGS += -L$(TAO_ROOT)/orbsvcs/orbsvcs -L$(TAO_ROOT)/tao
-CPPFLAGS += -I$(TAO_ROOT)/orbsvcs -I$(TAO_ROOT) -I$(TAO_ROOT)/tao/compat $(TSS_ORB_FLAG)#-H
-
-# Leave the scheduler output out if this is a config run.
-ifeq ($(runtime),1)
-EC_MULTIPLE_CONFIG_OBJS=EC_Multiple_Scheduler_Runtime.o
-endif # runtime
-
-ifeq ($(probe),1)
- CCFLAGS += -DACE_ENABLE_TIMEPROBES
-endif # probe
-
-EC_Multiple: $(addprefix $(VDIR),$(EC_MULTIPLE_OBJS) $(EC_MULTIPLE_CONFIG_OBJS))
- $(LINK.cc) $(LDFLAGS) -o $@ $^ $(VLDLIBS) $(POSTLINK)
-
-#----------------------------------------------------------------------------
-# Dependencies
-#----------------------------------------------------------------------------
-
-# DO NOT DELETE THIS LINE -- g++dep uses it.
-# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
-
-
-
-# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
diff --git a/TAO/orbsvcs/tests/EC_Multiple/README b/TAO/orbsvcs/tests/EC_Multiple/README
deleted file mode 100644
index c0c8d301852..00000000000
--- a/TAO/orbsvcs/tests/EC_Multiple/README
+++ /dev/null
@@ -1,29 +0,0 @@
-# $Id$
-
- This test ilustrates how to connect multiple ECs.
-
- The test requires the several other processes are running, the
-user must remember to assign a different port to each one:
-
-$ Naming_Service
-$ Scheduling_Service -ORBport 10030
-
- then we run two instances of the test, configuring the events
-that are local, only remote, remote and local:
-
-$ EC_Multiple -ORBport 10060 -l EC1 -r EC2 -a 1 -b 2 -c 3
-$ EC_Multiple -ORBport 10070 -l EC2 -r EC1 -a 4 -b 3 -c 2
-
- In this examples the first test treats EC1 as a local EC, and
-EC2 as remote, it generates events <1> and <2> and listens to events
-<1> and <3>. The second instance treats EC2 as local an EC1 as
-remote, generates events <4> and <3> but listens to <4> and <2>.
-
- Note how this configuration will have pure local events, some
-events that are both local and remote. Right now you have to examine
-the output carefully to notice what is happening.
-
- Another configuration of interest is:
-
-$ EC_Multiple -ORBport 10060 -l EC1 -r EC2 -a 1 -b 2 -c 2
-$ EC_Multiple -ORBport 10070 -l EC2 -r EC1 -a 4 -b 2 -c 2