summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcoryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-03-10 22:44:44 +0000
committercoryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-03-10 22:44:44 +0000
commita8d995af661c5cf422d6f44689912517a6f3cc78 (patch)
tree305e7099f08659bac64eb62e79c33f5b49aae9a7
parent217421d25d53994a278154b7887efb87d38f646f (diff)
downloadATCD-a8d995af661c5cf422d6f44689912517a6f3cc78.tar.gz
ChangeLogTag:Wed Mar 10 16:43:55 1999 Carlos O'Ryan <coryan@cs.wustl.edu>
-rw-r--r--TAO/ChangeLog-99c46
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp4
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp59
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h12
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h6
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h8
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp1
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp22
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp33
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h9
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i6
-rw-r--r--TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp9
-rw-r--r--TAO/orbsvcs/orbsvcs/RtecEventChannelAdmin.idl29
-rw-r--r--TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp221
-rw-r--r--TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h27
-rw-r--r--TAO/tao/decode.cpp13
-rw-r--r--TAO/tests/CDR/allocator.cpp14
17 files changed, 183 insertions, 336 deletions
diff --git a/TAO/ChangeLog-99c b/TAO/ChangeLog-99c
index b16a3182bcb..110054af411 100644
--- a/TAO/ChangeLog-99c
+++ b/TAO/ChangeLog-99c
@@ -1,3 +1,49 @@
+Wed Mar 10 16:43:55 1999 Carlos O'Ryan <coryan@cs.wustl.edu>
+
+ * orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h:
+ * orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i:
+ * orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp:
+ * orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp:
+ The type of event generated by the filter is can be passed in
+ the Filter constructor.
+ This is also used to control if the event is a one shot timeout
+ or an interval timeout.
+
+ * orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp:
+ We must create a Timeout_Filter for events of type
+ ACE_ES_TIMEOUT_EVENT too.
+ The type of event is passed to the Timeout_Filter.
+
+ * orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp:
+ Only push events if the consumer is not disconnected.
+
+ * orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp:
+ Fixed memory managment bug.
+
+ * orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h:
+ * orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp:
+ The UDP gateway does not require an scheduler, it can be argued
+ that it cannot use an scheduler because UDP is not suitable for
+ hard real-time systems.
+
+ * orbsvcs/tests/EC_Mcast/EC_Mcast.h:
+ * orbsvcs/tests/EC_Mcast/EC_Mcast.cpp:
+ Removed scheduler and some includes related to the old EC.
+
+ * orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h:
+ Work around horrible g++ 2.7.2 bug with forward declaration of
+ templates.
+
+ * orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h:
+ Also fixed a couple of g++ 2.7.2 warnings, that look like
+ compiler bugs to me.
+
+ * tao/decode.cpp:
+ Updated some comments in the object reference decoder.
+
+ * tests/CDR/allocator.cpp:
+ Minor cosmetic fixes.
+
Wed Mar 10 10:43:08 EST 1999 Aniruddha Gokhale <gokhale@sahyadri.research.bell-labs.com>
* TAO_IDL/fe/idl.yy:
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp
index ce09012eb3d..6f52a5a67bf 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Basic_Filter_Builder.cpp
@@ -59,13 +59,15 @@ TAO_EC_Basic_Filter_Builder::
}
return new TAO_EC_Disjunction_Filter (children, n);
}
- else if (e.header.type == ACE_ES_EVENT_INTERVAL_TIMEOUT
+ else if (e.header.type == ACE_ES_EVENT_TIMEOUT
+ || e.header.type == ACE_ES_EVENT_INTERVAL_TIMEOUT
|| e.header.type == ACE_ES_EVENT_DEADLINE_TIMEOUT)
{
pos++;
TAO_EC_QOS_Info qos_info;
return new TAO_EC_Timeout_Filter (this->event_channel_,
qos_info,
+ e.header.type,
e.header.creation_time);
}
return new TAO_EC_Type_Filter (e.header);
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp
index 9e8b2a1d0de..00589382f06 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.cpp
@@ -27,8 +27,6 @@ TAO_ECG_UDP_Sender::get_local_addr (ACE_INET_Addr& addr)
void
TAO_ECG_UDP_Sender::init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
- RtecScheduler::Scheduler_ptr lcl_sched,
- const char* lcl_name,
RtecUDPAdmin::AddrServer_ptr addr_server,
TAO_ECG_UDP_Out_Endpoint* endpoint,
CORBA::Environment &TAO_IN_ENV)
@@ -40,29 +38,6 @@ TAO_ECG_UDP_Sender::init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
RtecUDPAdmin::AddrServer::_duplicate (addr_server);
this->endpoint_ = endpoint;
-
- this->lcl_info_ = lcl_sched->lookup (lcl_name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- if (this->lcl_info_ == -1)
- {
- this->lcl_info_ =
- lcl_sched->create (lcl_name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
- ACE_Time_Value tv (0, 500);
- TimeBase::TimeT time;
- ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- lcl_sched->set (this->lcl_info_,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- 25000 * 10,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 0,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- }
}
int
@@ -97,10 +72,6 @@ TAO_ECG_UDP_Sender::open (RtecEventChannelAdmin::ConsumerQOS& sub,
if (sub.dependencies.length () == 0)
return;
- for (CORBA::ULong j = 0; j < sub.dependencies.length (); ++j)
- {
- sub.dependencies[j].rt_info = this->lcl_info_;
- }
//ACE_DEBUG ((LM_DEBUG, "ECG (%t) Gateway/Supplier "));
//ACE_SupplierQOS_Factory::debug (pub);
@@ -657,8 +628,6 @@ TAO_ECG_UDP_Receiver::TAO_ECG_UDP_Receiver (void)
void
TAO_ECG_UDP_Receiver::init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
- RtecScheduler::Scheduler_ptr lcl_sched,
- const char* lcl_name,
TAO_ECG_UDP_Out_Endpoint* ignore_from,
RtecUDPAdmin::AddrServer_ptr addr_server,
ACE_Reactor *reactor,
@@ -674,29 +643,6 @@ TAO_ECG_UDP_Receiver::init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
this->addr_server_ =
RtecUDPAdmin::AddrServer::_duplicate (addr_server);
- this->lcl_info_ = lcl_sched->lookup (lcl_name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- if (this->lcl_info_ == -1)
- {
- this->lcl_info_ =
- lcl_sched->create (lcl_name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
- ACE_Time_Value tv (0, 500);
- TimeBase::TimeT time;
- ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- lcl_sched->set (this->lcl_info_,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- 25000 * 10,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 1,
- RtecScheduler::REMOTE_DEPENDANT,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- }
-
this->reactor_ = reactor;
this->max_timeout_ = max_timeout;
// @@ TODO throw an exception....
@@ -723,11 +669,6 @@ TAO_ECG_UDP_Receiver::open (RtecEventChannelAdmin::SupplierQOS& pub,
if (pub.publications.length () == 0)
return;
- for (CORBA::ULong i = 0; i < pub.publications.length (); ++i)
- {
- pub.publications[i].dependency_info.rt_info = this->lcl_info_;
- }
-
// = Connect as a supplier to the local EC
RtecEventChannelAdmin::SupplierAdmin_var supplier_admin =
this->lcl_ec_->for_suppliers (TAO_IN_ENV);
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h b/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h
index d52955e99f6..50e4e9f7f95 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Gateway_UDP.h
@@ -131,8 +131,6 @@ public:
// Get the local endpoint used to send the events.
void init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
- RtecScheduler::Scheduler_ptr lcl_sched,
- const char* lcl_name,
RtecUDPAdmin::AddrServer_ptr addr_server,
TAO_ECG_UDP_Out_Endpoint* endpoint,
CORBA::Environment &_env);
@@ -200,9 +198,6 @@ private:
// The remote and the local EC, so we can reconnect when the
// subscription list changes.
- RtecScheduler::handle_t lcl_info_;
- // Our local and remote RT_Infos.
-
RtecEventChannelAdmin::ProxyPushSupplier_var supplier_proxy_;
// We talk to the EC (as a consumer) using this proxy.
@@ -427,8 +422,6 @@ public:
TAO_ECG_UDP_Receiver (void);
void init (RtecEventChannelAdmin::EventChannel_ptr lcl_ec,
- RtecScheduler::Scheduler_ptr lcl_sched,
- const char* lcl_name,
TAO_ECG_UDP_Out_Endpoint* ignore_from,
RtecUDPAdmin::AddrServer_ptr addr_server,
ACE_Reactor *reactor,
@@ -477,10 +470,7 @@ private:
RtecEventChannelAdmin::EventChannel_var lcl_ec_;
// The remote and the local EC, so we can reconnect when the list changes.
- RtecScheduler::handle_t lcl_info_;
- // Our RT_Info.
-
- RtecEventChannelAdmin::ProxyPushConsumer_var consumer_proxy_;
+ RtecEventChannelAdmin::ProxyPushConsumer_var consumer_proxy_;
// We talk to the EC (as a consumer) using this proxy.
TAO_ECG_UDP_Out_Endpoint* ignore_from_;
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h b/TAO/orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h
index d013e88cef4..78de7603223 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_ObserverStrategy.h
@@ -191,9 +191,9 @@ public:
// + Does it want to receive all changes?
//
- Observer_Entry (void);
- Observer_Entry (RtecEventChannelAdmin::Observer_Handle h,
- RtecEventChannelAdmin::Observer_ptr o);
+ ACE_INLINE Observer_Entry (void);
+ ACE_INLINE Observer_Entry (RtecEventChannelAdmin::Observer_Handle h,
+ RtecEventChannelAdmin::Observer_ptr o);
RtecEventChannelAdmin::Observer_Handle handle;
// The handle
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h b/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h
index 80da5120e96..d4f828d0bac 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set.h
@@ -33,6 +33,14 @@
#include "ace/Containers.h"
#include "tao/corba.h"
#include "EC_Busy_Lock.h"
+#if defined(__GNUC__) && __GNUC__ == 2 && __GNUC_MINOR__ < 8
+// g++ 2.7.2 is broken and cannot handle forward declaration of
+// templates in this case.
+// I could just include this file for all compilers, but I want to
+// minimize compile-time dependencies *and* document this problem so
+// we can fix it as g++ 2.7.2 is phased out.
+#include "EC_Command.h"
+#endif /* __GNUC__ */
class TAO_EC_ProxyPushSupplier;
template<class Target,class Object> class TAO_EC_Connected_Command;
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp
index e2a6029e376..1203f51f872 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_ProxyPushSupplier_Set_T.cpp
@@ -88,6 +88,7 @@ TAO_EC_ProxyPushSupplier_Set_Delayed<ACE_SYNCH_USE>::connected (
if (this->busy_count_ == 0)
{
// We can add the object immediately
+ supplier->_incr_refcnt ();
this->connected_i (supplier, ACE_TRY_ENV);
}
else
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp
index 4db043fcdff..2df4c647806 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_ProxySupplier.cpp
@@ -198,11 +198,12 @@ TAO_EC_ProxyPushSupplier::push (const RtecEventComm::EventSet& event,
{
// Do not take a lock, this is a call back from our child filter, so
// we are holding the lock already (in the filter() method).
- this->event_channel_->dispatching ()->push (this,
- this->consumer_.in (),
- event,
- qos_info,
- ACE_TRY_ENV);
+ if (this->is_connected_i ())
+ this->event_channel_->dispatching ()->push (this,
+ this->consumer_.in (),
+ event,
+ qos_info,
+ ACE_TRY_ENV);
this->child_->clear ();
}
@@ -213,11 +214,12 @@ TAO_EC_ProxyPushSupplier::push_nocopy (RtecEventComm::EventSet& event,
{
// Do not take a lock, this is a call back from our child filter, so
// we are holding the lock already (in the filter() method).
- this->event_channel_->dispatching ()->push_nocopy (this,
- this->consumer_.in (),
- event,
- qos_info,
- ACE_TRY_ENV);
+ if (this->is_connected_i ())
+ this->event_channel_->dispatching ()->push_nocopy (this,
+ this->consumer_.in (),
+ event,
+ qos_info,
+ ACE_TRY_ENV);
this->child_->clear ();
}
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp
index fa66acfe545..7749a2e0bce 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.cpp
@@ -14,22 +14,39 @@ ACE_RCSID(Event, EC_Timeout_Filter, "$Id$")
TAO_EC_Timeout_Filter::TAO_EC_Timeout_Filter (
TAO_EC_Event_Channel *event_channel,
const TAO_EC_QOS_Info& qos_info,
+ RtecEventComm::EventType type,
RtecEventComm::Time period)
: event_channel_ (event_channel),
- qos_info_ (qos_info)
+ qos_info_ (qos_info),
+ type_ (type)
{
ACE_Time_Value tv_delta;
ORBSVCS_Time::TimeT_to_Time_Value (tv_delta, period);
- ACE_Time_Value tv_interval;
- ORBSVCS_Time::TimeT_to_Time_Value (tv_interval, period);
-
TAO_EC_Timeout_Generator *tg =
this->event_channel_->timeout_generator ();
- this->id_ =
- tg->schedule_timer (this,
- tv_delta,
- tv_interval);
+
+ if (type == ACE_ES_EVENT_INTERVAL_TIMEOUT)
+ {
+ ACE_Time_Value tv_interval;
+ ORBSVCS_Time::TimeT_to_Time_Value (tv_interval, period);
+
+ this->id_ =
+ tg->schedule_timer (this,
+ tv_delta,
+ tv_interval);
+ }
+ else
+ {
+ this->id_ =
+ tg->schedule_timer (this,
+ tv_delta);
+ }
+
+ // ACE_DEBUG ((LM_DEBUG,
+ // "EC_Timeout_Filter - interval = %d:%d, ID = %d\n",
+ // tv_interval.sec (), tv_interval.usec (),
+ // this->id_));
}
TAO_EC_Timeout_Filter::~TAO_EC_Timeout_Filter (void)
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h
index bbdd690d490..5045beac2af 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.h
@@ -47,15 +47,19 @@ class TAO_ORBSVCS_Export TAO_EC_Timeout_Filter : public TAO_EC_Filter
public:
TAO_EC_Timeout_Filter (TAO_EC_Event_Channel *event_channel,
const TAO_EC_QOS_Info& qos_info,
+ RtecEventComm::EventType type,
RtecEventComm::Time period);
// Constructor.
-
+
virtual ~TAO_EC_Timeout_Filter (void);
// Destructor.
const TAO_EC_QOS_Info& qos_info (void) const;
// Return the QOS_Info for this Timeout filter.
+ RtecEventComm::EventType type (void) const;
+ // The type of timeout event that we generate.
+
// = The TAO_EC_Filter methods, please check the documentation in
// TAO_EC_Filter.
virtual int filter (const RtecEventComm::EventSet& event,
@@ -87,6 +91,9 @@ private:
TAO_EC_QOS_Info qos_info_;
// Events "generated" by this filter use this QOS_Info.
+ RtecEventComm::EventType type_;
+ // The type of timeout event...
+
int id_;
// The ID of the timeout in the Timeout_Generator, for
// cancellation.
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i
index 5f65bedfd24..f47bb605f57 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Filter.i
@@ -5,3 +5,9 @@ TAO_EC_Timeout_Filter::qos_info (void) const
{
return this->qos_info_;
}
+
+ACE_INLINE RtecEventComm::EventType
+TAO_EC_Timeout_Filter::type (void) const
+{
+ return this->type_;
+}
diff --git a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp
index e4b94a24b40..8cc5e206761 100644
--- a/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp
+++ b/TAO/orbsvcs/orbsvcs/Event/EC_Timeout_Generator.cpp
@@ -17,9 +17,14 @@ TAO_EC_Timeout_Generator::~TAO_EC_Timeout_Generator (void)
// ****************************************************************
int
-TAO_EC_Timeout_Adapter::handle_timeout (const ACE_Time_Value &,
+TAO_EC_Timeout_Adapter::handle_timeout (const ACE_Time_Value & /* tv */,
const void *vp)
{
+ // ACE_DEBUG ((LM_DEBUG,
+ // "TAO_EC_Timeout_Adapter::handle_timeout -"
+ // " expire at %d:%d\n",
+ // tv.sec (), tv.usec ()));
+
TAO_EC_Timeout_Filter *filter =
ACE_static_cast(TAO_EC_Timeout_Filter*, ACE_const_cast(void*,vp));
@@ -29,7 +34,7 @@ TAO_EC_Timeout_Adapter::handle_timeout (const ACE_Time_Value &,
ACE_TRY_NEW_ENV
{
RtecEventComm::Event e;
- e.header.type = ACE_ES_EVENT_TIMEOUT;
+ e.header.type = filter->type ();
e.header.source = 0;
RtecEventComm::EventSet single_event (1, 1, &e, 0);
diff --git a/TAO/orbsvcs/orbsvcs/RtecEventChannelAdmin.idl b/TAO/orbsvcs/orbsvcs/RtecEventChannelAdmin.idl
index 42e8395ed3b..13cda1da364 100644
--- a/TAO/orbsvcs/orbsvcs/RtecEventChannelAdmin.idl
+++ b/TAO/orbsvcs/orbsvcs/RtecEventChannelAdmin.idl
@@ -6,38 +6,38 @@
#include "RtecEventComm.idl"
#include "RtecScheduler.idl"
-module RtecEventChannelAdmin
+module RtecEventChannelAdmin
{
exception AlreadyConnected {};
exception TypeError {};
- struct Dependency
+ struct Dependency
{
RtecEventComm::Event event;
RtecScheduler::handle_t rt_info;
};
typedef sequence<Dependency> DependencySet;
- struct ConsumerQOS
+ struct ConsumerQOS
{
DependencySet dependencies;
boolean is_gateway;
};
- struct Publication
+ struct Publication
{
RtecEventComm::Event event;
RtecScheduler::Dependency_Info dependency_info;
};
typedef sequence<Publication> PublicationSet;
- struct SupplierQOS
+ struct SupplierQOS
{
PublicationSet publications;
boolean is_gateway;
};
- interface ProxyPushSupplier: RtecEventComm::PushSupplier
+ interface ProxyPushSupplier: RtecEventComm::PushSupplier
{
// = TITLE
// The Proxy Supplier
@@ -64,7 +64,7 @@ module RtecEventChannelAdmin
// Resume the reception of events.
};
- interface ProxyPushConsumer: RtecEventComm::PushConsumer
+ interface ProxyPushConsumer: RtecEventComm::PushConsumer
{
// = TITLE
// The Proxy Consumer
@@ -84,7 +84,7 @@ module RtecEventChannelAdmin
// @@ TODO: Find out the exception specs for the following interface's
// methods.
- interface ConsumerAdmin
+ interface ConsumerAdmin
{
// = TITLE
// The Supplier factory
@@ -97,7 +97,7 @@ module RtecEventChannelAdmin
// Obtain a supplier
};
- interface SupplierAdmin
+ interface SupplierAdmin
{
// = TITLE
// The Consumer factory
@@ -110,7 +110,7 @@ module RtecEventChannelAdmin
// Obtain a consumer
};
- interface Observer
+ interface Observer
{
// = TITLE
// Observes any changes in the consumer or supplier sets for an
@@ -123,19 +123,18 @@ module RtecEventChannelAdmin
void update_consumer (in ConsumerQOS sub);
// A change in the list of consumers has ocurred. The disjunction
- // of the subscriptions (and its equivalent form ) is
- // passed to the observer.
+ // of the subscriptions is passed to the observer.
void update_supplier (in SupplierQOS pub);
- // A change in the list of consumers has ocurred. The disjunction
- // of the publications (and its equivalent form for suppliers).
+ // A change in the list of suppliers has ocurred. The disjunction
+ // of the publications is passed to the observer.
};
typedef unsigned long Observer_Handle;
// This is used as an opaque ID to control the addition and removal
// of handles from an event channel.
- interface EventChannel
+ interface EventChannel
{
// = TITLE
// The Event Channel class
diff --git a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
index 00ba11800dd..bca917ef4a0 100644
--- a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
+++ b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
@@ -7,11 +7,7 @@
#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/Sched/Config_Scheduler.h"
-#include "orbsvcs/Runtime_Scheduler.h"
#include "orbsvcs/Event/EC_Event_Channel.h"
#include "orbsvcs/Event/EC_Basic_Factory.h"
@@ -122,20 +118,6 @@ ECM_Driver::run (int argc, char* argv[])
}
}
- ACE_Config_Scheduler scheduler_impl;
- RtecScheduler::Scheduler_var scheduler =
- scheduler_impl._this (TAO_TRY_ENV);
- TAO_CHECK_ENV;
-
- CORBA::String_var str =
- this->orb_->object_to_string (scheduler.in (), TAO_TRY_ENV);
- TAO_CHECK_ENV;
- ACE_DEBUG ((LM_DEBUG, "The (local) scheduler IOR is <%s>\n",
- str.in ()));
-
- if (ACE_Scheduler_Factory::server (scheduler.in ()) == -1)
- return -1;
-
TAO_EC_Basic_Factory ec_factory (root_poa.in ());
TAO_EC_Event_Channel ec_impl (&ec_factory);
@@ -145,7 +127,8 @@ ECM_Driver::run (int argc, char* argv[])
ec_impl._this (TAO_TRY_ENV);
TAO_CHECK_ENV;
- str = this->orb_->object_to_string (ec.in (), TAO_TRY_ENV);
+ CORBA::String_var str =
+ this->orb_->object_to_string (ec.in (), TAO_TRY_ENV);
TAO_CHECK_ENV;
ACE_DEBUG ((LM_DEBUG, "The (local) EC IOR is <%s>\n", str.in ()));
@@ -159,35 +142,29 @@ ECM_Driver::run (int argc, char* argv[])
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: local EC objref ready\n"));
this->open_federations (ec.in (),
- scheduler.in (),
TAO_TRY_ENV);
TAO_CHECK_ENV;
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: open_federations done\n"));
this->open_senders (ec.in (),
- scheduler.in (),
TAO_TRY_ENV);
TAO_CHECK_ENV;
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: open_senders done\n"));
this->open_receivers (ec.in (),
- scheduler.in (),
TAO_TRY_ENV);
TAO_CHECK_ENV;
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: open_receivers done\n"));
this->activate_federations (ec.in (),
- scheduler.in (),
TAO_TRY_ENV);
TAO_CHECK_ENV;
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: activate_federations done\n"));
- ACE_DEBUG ((LM_DEBUG, "EC_Mcast: activate the EC\n"));
-
ACE_DEBUG ((LM_DEBUG, "EC_Mcast: running the test\n"));
if (this->orb_->run () == -1)
ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "orb->run"), -1);
@@ -206,13 +183,6 @@ ECM_Driver::run (int argc, char* argv[])
ec_impl.shutdown (TAO_TRY_ENV);
TAO_CHECK_ENV;
-
- ACE_DEBUG ((LM_DEBUG, "EC_Mcast: shutdown grace period\n"));
-
- ACE_Time_Value tv (5, 0);
- if (this->orb_->run (&tv) == -1)
- ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "orb->run"), -1);
-
}
TAO_CATCH (CORBA::SystemException, sys_ex)
{
@@ -239,28 +209,28 @@ ECM_Driver::federation_has_shutdown (ECM_Local_Federation *federation,
void
ECM_Driver::open_federations (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
for (int i = 0; i < this->local_federations_count_; ++i)
{
this->local_federations_[i]->open (this->event_count_,
- this->event_period_,
- ec, scheduler, TAO_IN_ENV);
+ ec, TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
}
}
void
ECM_Driver::activate_federations (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
this->federations_running_ = this->local_federations_count_;
+ RtecEventComm::Time interval = this->event_period_;
+ interval *= 10;
for (int i = 0; i < this->local_federations_count_; ++i)
{
- this->local_federations_[i]->activate (this->event_period_,
- ec, scheduler, TAO_IN_ENV);
+ this->local_federations_[i]->activate (ec,
+ interval,
+ TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
}
}
@@ -277,7 +247,6 @@ ECM_Driver::close_federations (CORBA::Environment &TAO_IN_ENV)
void
ECM_Driver::open_senders (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
if (this->endpoint_.dgram ().open (ACE_Addr::sap_any) == -1)
@@ -296,7 +265,6 @@ ECM_Driver::open_senders (RtecEventChannelAdmin::EventChannel_ptr ec,
{
this->all_federations_[i]->open (&this->endpoint_,
ec,
- scheduler,
TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
}
@@ -315,13 +283,11 @@ ECM_Driver::close_senders (CORBA::Environment &TAO_IN_ENV)
void
ECM_Driver::open_receivers (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
for (int i = 0; i < this->local_federations_count_; ++i)
{
this->local_federations_[i]->open_receiver (ec,
- scheduler,
&this->endpoint_,
TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
@@ -609,20 +575,13 @@ ECM_Federation::ECM_Federation (char* name,
void
ECM_Federation::open (TAO_ECG_UDP_Out_Endpoint *endpoint,
RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
- const int bufsize = 512;
- char buf[bufsize];
- ACE_OS::strcpy (buf, this->name ());
- ACE_OS::strcat (buf, "/sender");
-
RtecUDPAdmin::AddrServer_var addr_server =
this->addr_server (TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- this->sender_.init (ec, scheduler,
- buf,
+ this->sender_.init (ec,
addr_server.in (),
endpoint,
TAO_IN_ENV);
@@ -631,31 +590,17 @@ ECM_Federation::open (TAO_ECG_UDP_Out_Endpoint *endpoint,
// @@ TODO Make this a parameter....
this->sender_.mtu (64);
- RtecScheduler::handle_t rt_info =
- scheduler->create (buf, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID(TAO_IN_ENV);
-
// The worst case execution time is far less than 2
// milliseconds, but that is a safe estimate....
ACE_Time_Value tv (0, 2000);
TimeBase::TimeT time;
ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- scheduler->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- 0,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 0,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
ACE_ConsumerQOS_Factory qos;
qos.start_disjunction_group ();
for (int i = 0; i < this->consumer_types (); ++i)
{
- qos.insert_type (this->consumer_ipaddr (i), rt_info);
+ qos.insert_type (this->consumer_ipaddr (i), 0);
}
RtecEventChannelAdmin::ConsumerQOS qos_copy = qos.get_ConsumerQOS ();
this->sender_.open (qos_copy, TAO_IN_ENV);
@@ -687,34 +632,9 @@ ECM_Supplier::ECM_Supplier (ECM_Local_Federation* federation)
void
ECM_Supplier::open (const char* name,
- RtecScheduler::Period_t period,
RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &TAO_IN_ENV)
{
- RtecScheduler::handle_t rt_info =
- scheduler->create (name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
- // The execution times are set to reasonable values, but
- // actually they are changed on the real execution, i.e. we
- // lie to the scheduler to obtain right priorities; but we
- // don't care if the set is schedulable.
- ACE_Time_Value tv (0, 2000);
- TimeBase::TimeT time;
- ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
-
- scheduler->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- period,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 1,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
this->supplier_id_ = ACE::crc32 (name);
ACE_DEBUG ((LM_DEBUG, "ID for <%s> is %04.4x\n", name,
this->supplier_id_));
@@ -724,11 +644,11 @@ ECM_Supplier::open (const char* name,
{
qos.insert (this->supplier_id_,
this->federation_->supplier_ipaddr (i),
- rt_info, 1);
+ 0, 1);
}
qos.insert (this->supplier_id_,
ACE_ES_EVENT_SHUTDOWN,
- rt_info, 1);
+ 0, 1);
RtecEventChannelAdmin::SupplierAdmin_var supplier_admin =
ec->for_suppliers (TAO_IN_ENV);
@@ -760,50 +680,15 @@ ECM_Supplier::close (CORBA::Environment &TAO_IN_ENV)
}
void
-ECM_Supplier::activate (const char* name,
- RtecScheduler::Period_t period,
- RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
+ECM_Supplier::activate (RtecEventChannelAdmin::EventChannel_ptr ec,
+ RtecEventComm::Time interval,
CORBA::Environment &TAO_IN_ENV)
{
- const int bufsize = 512;
- char buf[bufsize];
- ACE_OS::strcpy (buf, "consumer_");
- ACE_OS::strcat (buf, name);
- RtecScheduler::handle_t rt_info =
- scheduler->create (buf, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
- // The execution times are set to reasonable values, but
- // actually they are changed on the real execution, i.e. we
- // lie to the scheduler to obtain right priorities; but we
- // don't care if the set is schedulable.
- ACE_Time_Value tv (0, 2000);
- TimeBase::TimeT time;
- ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- scheduler->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- period,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 1,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
-
- // Also connect our consumer for timeout events from the EC.
- int interval = period / 10;
- ACE_Time_Value tv_timeout (interval / ACE_ONE_SECOND_IN_USECS,
- interval % ACE_ONE_SECOND_IN_USECS);
- TimeBase::TimeT timeout;
- ORBSVCS_Time::Time_Value_to_TimeT (timeout, tv_timeout);
-
ACE_ConsumerQOS_Factory consumer_qos;
consumer_qos.start_disjunction_group ();
consumer_qos.insert_time (ACE_ES_EVENT_INTERVAL_TIMEOUT,
- timeout,
- rt_info);
+ interval,
+ 0);
// = Connect as a consumer.
RtecEventChannelAdmin::ConsumerAdmin_var consumer_admin =
@@ -871,29 +756,14 @@ ECM_Consumer::ECM_Consumer (ECM_Local_Federation *federation)
void
ECM_Consumer::open (const char* name,
RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
ACE_RANDR_TYPE &seed,
CORBA::Environment& TAO_IN_ENV)
{
- this->rt_info_ =
- scheduler->create (name, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID(TAO_IN_ENV);
-
// The worst case execution time is far less than 2
// milliseconds, but that is a safe estimate....
ACE_Time_Value tv (0, 2000);
TimeBase::TimeT time;
ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- scheduler->set (this->rt_info_,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- 0,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 0,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
// = Connect as a consumer.
this->consumer_admin_ = ec->for_consumers (TAO_IN_ENV);
@@ -915,8 +785,7 @@ ECM_Consumer::connect (ACE_RANDR_TYPE &seed,
ACE_ConsumerQOS_Factory qos;
qos.start_disjunction_group ();
- qos.insert_type (ACE_ES_EVENT_SHUTDOWN,
- this->rt_info_);
+ qos.insert_type (ACE_ES_EVENT_SHUTDOWN, 0);
const ECM_Federation* federation = this->federation_->federation ();
for (int i = 0; i < federation->consumer_types (); ++i)
{
@@ -934,8 +803,7 @@ ECM_Consumer::connect (ACE_RANDR_TYPE &seed,
federation->name (),
federation->consumer_name (i)));
this->federation_->subscribed_bit (i, 1);
- qos.insert_type (federation->consumer_ipaddr (i),
- this->rt_info_);
+ qos.insert_type (federation->consumer_ipaddr (i), 0);
}
RtecEventComm::PushConsumer_var objref = this->_this (TAO_IN_ENV);
@@ -1012,9 +880,7 @@ ECM_Local_Federation::~ECM_Local_Federation (void)
void
ECM_Local_Federation::open (int event_count,
- RtecScheduler::Period_t period,
RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment& TAO_IN_ENV)
{
this->event_count_ = event_count;
@@ -1024,12 +890,12 @@ ECM_Local_Federation::open (int event_count,
ACE_OS::strcpy (buf, this->federation_->name ());
ACE_OS::strcat (buf, "/supplier");
- this->supplier_.open (buf, period, ec, scheduler, TAO_IN_ENV);
+ this->supplier_.open (buf, ec, TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
ACE_OS::strcpy (buf, this->federation_->name ());
ACE_OS::strcat (buf, "/consumer");
- this->consumer_.open (buf, ec, scheduler, this->seed_, TAO_IN_ENV);
+ this->consumer_.open (buf, ec, this->seed_, TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
this->last_subscription_change_ = ACE_OS::gettimeofday ();
@@ -1046,14 +912,11 @@ ECM_Local_Federation::close (CORBA::Environment &TAO_IN_ENV)
}
void
-ECM_Local_Federation::activate (RtecScheduler::Period_t period,
- RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
+ECM_Local_Federation::activate (RtecEventChannelAdmin::EventChannel_ptr ec,
+ RtecEventComm::Time interval,
CORBA::Environment& TAO_IN_ENV)
{
- this->supplier_.activate (this->federation_->name (),
- period,
- ec, scheduler, TAO_IN_ENV);
+ this->supplier_.activate (ec, interval, TAO_IN_ENV);
}
void
@@ -1148,15 +1011,9 @@ ECM_Local_Federation::consumer_push (ACE_hrtime_t,
void
ECM_Local_Federation::open_receiver (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
TAO_ECG_UDP_Out_Endpoint* ignore_from,
CORBA::Environment &TAO_IN_ENV)
{
- const int bufsize = 512;
- char buf[bufsize];
- ACE_OS::strcpy (buf, this->name ());
- ACE_OS::strcat (buf, "/receiver");
-
RtecUDPAdmin::AddrServer_var addr_server =
this->federation_->addr_server (TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
@@ -1166,33 +1023,19 @@ ECM_Local_Federation::open_receiver (RtecEventChannelAdmin::EventChannel_ptr ec,
// @@ This should be parameters...
ACE_Time_Value expire_interval (1, 0);
const int max_timeouts = 5;
- this->receiver_.init (ec, scheduler,
- buf,
+ this->receiver_.init (ec,
ignore_from,
addr_server.in (),
- reactor, expire_interval, max_timeouts,
+ reactor,
+ expire_interval,
+ max_timeouts,
TAO_IN_ENV);
TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
- RtecScheduler::handle_t rt_info =
- scheduler->create (buf, TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID(TAO_IN_ENV);
-
- // The worst case execution time is far less than 2
- // milliseconds, but that is a safe estimate....
- ACE_Time_Value tv (0, 2000);
- TimeBase::TimeT time;
- ORBSVCS_Time::Time_Value_to_TimeT (time, tv);
- scheduler->set (rt_info,
- RtecScheduler::VERY_HIGH_CRITICALITY,
- time, time, time,
- 0,
- RtecScheduler::VERY_LOW_IMPORTANCE,
- time,
- 1,
- RtecScheduler::OPERATION,
- TAO_IN_ENV);
- TAO_CHECK_ENV_RETURN_VOID (TAO_IN_ENV);
+ const int bufsize = 512;
+ char buf[bufsize];
+ ACE_OS::strcpy (buf, this->name ());
+ ACE_OS::strcat (buf, "/receiver");
RtecEventComm::EventSourceID source = ACE::crc32 (buf);
@@ -1206,7 +1049,7 @@ ECM_Local_Federation::open_receiver (RtecEventChannelAdmin::EventChannel_ptr ec,
{
qos.insert (source,
this->consumer_ipaddr (i),
- rt_info, 1);
+ 0, 1);
}
RtecEventChannelAdmin::SupplierQOS qos_copy =
diff --git a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
index b05aa7aedb2..8d021e57381 100644
--- a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
+++ b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
@@ -111,7 +111,6 @@ public:
void open (TAO_ECG_UDP_Out_Endpoint *endoint,
RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &_env);
// Connect the UDP sender to the EC.
@@ -164,19 +163,15 @@ public:
ECM_Supplier (ECM_Local_Federation* federation);
void open (const char* name,
- RtecScheduler::Period_t period,
RtecEventChannelAdmin::EventChannel_ptr event_channel,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment& _env);
// This method connects the supplier to the EC.
void close (CORBA::Environment &_env);
// Disconnect from the EC.
- void activate (const char* name,
- RtecScheduler::Period_t period,
- RtecEventChannelAdmin::EventChannel_ptr event_channel,
- RtecScheduler::Scheduler_ptr scheduler,
+ void activate (RtecEventChannelAdmin::EventChannel_ptr event_channel,
+ RtecEventComm::Time interval,
CORBA::Environment& _env);
// Connect as a consumer to start receiving events.
@@ -224,7 +219,6 @@ public:
void open (const char* name,
RtecEventChannelAdmin::EventChannel_ptr event_channel,
- RtecScheduler::Scheduler_ptr scheduler,
ACE_RANDR_TYPE &seed,
CORBA::Environment& _env);
// This method connects the consumer to the EC.
@@ -247,9 +241,6 @@ private:
ECM_Local_Federation* federation_;
// To callback.
- RtecScheduler::handle_t rt_info_;
- // The handle for our RT_Info description.
-
RtecEventChannelAdmin::ProxyPushSupplier_var supplier_proxy_;
// We talk to the EC using this proxy.
@@ -271,18 +262,15 @@ public:
// Destructor
void open (int event_count,
- RtecScheduler::Period_t period,
RtecEventChannelAdmin::EventChannel_ptr event_channel,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment& _env);
// Connect both the supplier and the consumer.
void close (CORBA::Environment& _env);
// Disconnect everybody from the EC
- void activate (RtecScheduler::Period_t period,
- RtecEventChannelAdmin::EventChannel_ptr event_channel,
- RtecScheduler::Scheduler_ptr scheduler,
+ void activate (RtecEventChannelAdmin::EventChannel_ptr event_channel,
+ RtecEventComm::Time interval,
CORBA::Environment& _env);
// Activate the supplier
@@ -299,7 +287,6 @@ public:
// The federation description.
void open_receiver (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
TAO_ECG_UDP_Out_Endpoint* ignore_from,
CORBA::Environment &_env);
// Connect the UDP receiver to the EC.
@@ -431,12 +418,10 @@ public:
private:
void open_federations (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &_env);
// Connect the federations to the EC.
void activate_federations (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &_env);
// Activate all the federations
@@ -445,12 +430,10 @@ private:
// the objects, etc.
void open_senders (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &_env);
// Connect all the senders, so we can start multicasting events.
void open_receivers (RtecEventChannelAdmin::EventChannel_ptr ec,
- RtecScheduler::Scheduler_ptr scheduler,
CORBA::Environment &_env);
// Connect all the receivers, thus we accept events arriving through
// multicast.
@@ -483,7 +466,7 @@ private:
private:
int event_period_;
- // The events are generated using this interval.
+ // The events are generated using this interval, in microseconds.
int event_count_;
// How many events will the suppliers send
diff --git a/TAO/tao/decode.cpp b/TAO/tao/decode.cpp
index 515e64f3aba..4aa12166636 100644
--- a/TAO/tao/decode.cpp
+++ b/TAO/tao/decode.cpp
@@ -607,14 +607,11 @@ TAO_Marshal_ObjRef::decode (CORBA::TypeCode_ptr,
// object reference.
stream->decode (CORBA::_tc_string, &type_hint, 0, env);
- // Read the profiles, discarding all until an IIOP profile comes by.
- // Once we see an IIOP profile, ignore any further ones.
- //
- // XXX this will need to change someday to let different protocol
- // code be accessed, not just IIOP. Protocol modules will be
- // dynamically loaded from shared libraries via ORB_init (), and we
- // just need to be able to access such preloaded libraries here as
- // we unmarshal objrefs.
+ // @@ TODO: Only IIOP profiles are parsed here! We should use the
+ // connector registry to isolate this code from the particulars of
+ // all the protocols.
+ // Also: the connector registry should create a base TAO_Profile if
+ // it does not find the right protocol to handle the current one.
CORBA::ULong profiles;
STUB_Object *objdata = 0;
diff --git a/TAO/tests/CDR/allocator.cpp b/TAO/tests/CDR/allocator.cpp
index 92b2b2d905a..aebfd317fb4 100644
--- a/TAO/tests/CDR/allocator.cpp
+++ b/TAO/tests/CDR/allocator.cpp
@@ -35,9 +35,9 @@ class Application_Simulator
// = DESCRIPTION
// Tries to simulate the behavior of an application: it randomly
// acquires and releases memory, of variable sizes.
- // The intention is to produce some level of fragmentation in main
+ // The intention is to produce some level of fragmentation in main
// memory.
-
+
public:
Application_Simulator (int max_fragments,
int max_fragment_size);
@@ -128,15 +128,15 @@ main (int argc, char *argv[])
ACE_DEBUG ((LM_DEBUG, "SEED = %d\n", seed));
- ACE_Allocator* buffer_allocator =
+ ACE_Allocator* buffer_allocator =
ACE_Allocator::instance ();
- ACE_Allocator* dblock_allocator =
+ ACE_Allocator* dblock_allocator =
ACE_Allocator::instance ();
if (tss)
{
- buffer_allocator =
+ buffer_allocator =
TAO_ORB_Core_instance ()->output_cdr_buffer_allocator ();
- dblock_allocator =
+ dblock_allocator =
TAO_ORB_Core_instance ()->output_cdr_dblock_allocator ();
}
@@ -147,7 +147,7 @@ main (int argc, char *argv[])
int* argument_sizes;
ACE_NEW_RETURN (argument_sizes, int[max_arguments], 1);
-
+
int n = ACE_OS::rand_r (seed) % max_arguments + 1;
for (int k = 0; k < n; ++k)
argument_sizes[k] = ACE_OS::rand_r (seed) % max_argument_size + 1;