summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/Fault_Detector
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2007-01-24 15:39:09 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2007-01-24 15:39:09 +0000
commitb273c8bbb2bb98b5b862d1ce24855ae207b4eb0c (patch)
tree70bff03d1cf156ecf05ee4c5c338d8ce423e64ee /TAO/orbsvcs/Fault_Detector
parentd43378e7d80d7db5bb3517e16b858fb09b117007 (diff)
downloadATCD-b273c8bbb2bb98b5b862d1ce24855ae207b4eb0c.tar.gz
Wed Jan 24 14:00:12 UTC 2007 Johnny Willemsen <jwillemsen@remedy.nl>
Diffstat (limited to 'TAO/orbsvcs/Fault_Detector')
-rw-r--r--TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.cpp30
-rw-r--r--TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.h6
-rw-r--r--TAO/orbsvcs/Fault_Detector/Fault_Detector_i.cpp4
3 files changed, 11 insertions, 29 deletions
diff --git a/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.cpp b/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.cpp
index 0efefef03cd..e6e7f35f24b 100644
--- a/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.cpp
+++ b/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.cpp
@@ -84,7 +84,7 @@ TAO::FT_FaultDetectorFactory_i::~FT_FaultDetectorFactory_i ()
shutdown_i ();
}
ACE_DECLARE_NEW_ENV;
- fini (ACE_ENV_SINGLE_ARG_PARAMETER);
+ fini ();
this->threadManager_.close ();
}
@@ -216,7 +216,6 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
CORBA::Object_var poa_object =
this->orb_->resolve_initial_references (TAO_OBJID_ROOTPOA
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
if (CORBA::is_nil (poa_object.in ()))
ACE_ERROR_RETURN ((LM_ERROR,
@@ -228,7 +227,6 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
PortableServer::POA::_narrow (poa_object.in ()
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
if (CORBA::is_nil(this->poa_.in ()))
{
@@ -238,27 +236,22 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
}
PortableServer::POAManager_var poa_manager =
- this->poa_->the_POAManager (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
+ this->poa_->the_POAManager ();
- poa_manager->activate (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
+ poa_manager->activate ();
// Register with the POA.
this->objectId_ = this->poa_->activate_object (this ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
// find my IOR
CORBA::Object_var this_obj =
this->poa_->id_to_reference (objectId_.in ()
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
this->ior_ = this->orb_->object_to_string (this_obj.in ()
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
this->identity_ = "FaultDetectorFactory";
@@ -269,19 +262,15 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
ACE_TRY_NEW_ENV
{
CORBA::Object_var rm_obj = orb->resolve_initial_references("ReplicationManager" ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
this->replication_manager_ = ::FT::ReplicationManager::_narrow(rm_obj.in() ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
if (!CORBA::is_nil (replication_manager_.in ()))
{
// capture the default notifier
- this->notifier_ = this->replication_manager_->get_fault_notifier (ACE_ENV_SINGLE_ARG_PARAMETER);
- ACE_TRY_CHECK;
+ this->notifier_ = this->replication_manager_->get_fault_notifier ();
// register with ReplicationManager::RegistrationFactory
PortableGroup::Criteria criteria(0);
this->factory_registry_ = this->replication_manager_->get_factory_registry (criteria ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
if (! CORBA::is_nil(factory_registry_.in ()))
{
@@ -301,7 +290,6 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
FT::FAULT_DETECTOR_ROLE_NAME,
info
ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
ACE_DEBUG ((LM_DEBUG,
"FaultDetector Registration complete.\n"
@@ -346,7 +334,6 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
CORBA::Object_var naming_obj =
this->orb_->resolve_initial_references ("NameService" ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
if (CORBA::is_nil(naming_obj.in ())){
ACE_ERROR_RETURN ((LM_ERROR,
@@ -356,20 +343,18 @@ int TAO::FT_FaultDetectorFactory_i::init (CORBA::ORB_ptr orb ACE_ENV_ARG_DECL)
this->naming_context_ =
::CosNaming::NamingContext::_narrow (naming_obj.in () ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
this->this_name_.length (1);
this->this_name_[0].id = CORBA::string_dup (this->ns_name_);
this->naming_context_->rebind (this->this_name_, this_obj.in() //CORBA::Object::_duplicate(this_obj)
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
}
return result;
}
-int TAO::FT_FaultDetectorFactory_i::fini (ACE_ENV_SINGLE_ARG_DECL)
+int TAO::FT_FaultDetectorFactory_i::fini (void)
{
if (this->ior_output_file_ != 0)
{
@@ -389,7 +374,6 @@ int TAO::FT_FaultDetectorFactory_i::fini (ACE_ENV_SINGLE_ARG_DECL)
FT::FAULT_DETECTOR_ROLE_NAME,
this->location_
ACE_ENV_ARG_PARAMETER);
- ACE_CHECK_RETURN (-1);
this->registered_ = 0;
}
return 0;
@@ -496,7 +480,7 @@ void TAO::FT_FaultDetectorFactory_i::change_properties (
METHOD_RETURN(TAO::FT_FaultDetectorFactory_i::change_properties);
}
-void TAO::FT_FaultDetectorFactory_i::shutdown (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+void TAO::FT_FaultDetectorFactory_i::shutdown (void)
ACE_THROW_SPEC ((
CORBA::SystemException
))
@@ -704,7 +688,7 @@ void TAO::FT_FaultDetectorFactory_i::delete_object (
METHOD_RETURN(TAO::FT_FaultDetectorFactory_i::delete_object);
}
-CORBA::Boolean TAO::FT_FaultDetectorFactory_i::is_alive (ACE_ENV_SINGLE_ARG_DECL_NOT_USED)
+CORBA::Boolean TAO::FT_FaultDetectorFactory_i::is_alive (void)
ACE_THROW_SPEC ((CORBA::SystemException))
{
METHOD_RETURN(TAO::FT_FaultDetectorFactory_i::is_alive)
diff --git a/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.h b/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.h
index a28eebffe56..590a603bac1 100644
--- a/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.h
+++ b/TAO/orbsvcs/Fault_Detector/FT_FaultDetectorFactory_i.h
@@ -123,7 +123,7 @@ namespace TAO
* Prepare to exit.
* @return zero for success; nonzero is process return code for failure.
*/
- int fini (ACE_ENV_SINGLE_ARG_DECL);
+ int fini (void);
/**
* Idle-time activity.
@@ -163,7 +163,7 @@ namespace TAO
, PortableGroup::InvalidProperty
));
- virtual void shutdown (ACE_ENV_SINGLE_ARG_DECL)
+ virtual void shutdown (void)
ACE_THROW_SPEC ((
CORBA::SystemException
));
@@ -197,7 +197,7 @@ namespace TAO
//////////////////////////////////////////
// CORBA interface PullMonitorable methods
- virtual CORBA::Boolean is_alive (ACE_ENV_SINGLE_ARG_DECL)
+ virtual CORBA::Boolean is_alive (void)
ACE_THROW_SPEC ((CORBA::SystemException));
/////////////////////////
diff --git a/TAO/orbsvcs/Fault_Detector/Fault_Detector_i.cpp b/TAO/orbsvcs/Fault_Detector/Fault_Detector_i.cpp
index 60d749ef0dd..0d86fea6734 100644
--- a/TAO/orbsvcs/Fault_Detector/Fault_Detector_i.cpp
+++ b/TAO/orbsvcs/Fault_Detector/Fault_Detector_i.cpp
@@ -89,9 +89,8 @@ void TAO::Fault_Detector_i::run()
{
ACE_TRY_NEW_ENV
{
- if (this->monitorable_->is_alive(ACE_ENV_SINGLE_ARG_PARAMETER))
+ if (this->monitorable_->is_alive())
{
- ACE_TRY_CHECK;
// use this rather than ACE_OS::sleep
// to allow the nap to be interruped see request_quit
this->sleep_.wait (&sleep_time_, 0);
@@ -167,7 +166,6 @@ void TAO::Fault_Detector_i::notify()
}
this->notifier_->push_structured_fault(vEvent.in()
ACE_ENV_ARG_PARAMETER);
- ACE_TRY_CHECK;
if (TAO_debug_level > 5)
{