OpenDDS
Snapshot(2023/04/07-19:43)
|
#include <DCPSInfoRepoServ.h>
Classes | |
struct | InitError |
Public Member Functions | |
InfoRepo (int argc, ACE_TCHAR *argv[]) | |
~InfoRepo () | |
void | run () |
virtual void | shutdown () |
ShutdownInterface used to schedule a shutdown. More... | |
void | set_shutdown_signal (int which_signal) |
void | sync_shutdown () |
virtual int | handle_exception (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
Handler for the reactor to dispatch finalization activity to. More... | |
![]() | |
virtual | ~ShutdownInterface () |
![]() | |
virtual | ~ACE_Event_Handler (void) |
virtual ACE_HANDLE | get_handle (void) const |
virtual void | set_handle (ACE_HANDLE) |
virtual int | priority (void) const |
virtual void | priority (int priority) |
virtual int | handle_input (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
virtual int | handle_output (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
virtual int | handle_timeout (const ACE_Time_Value ¤t_time, const void *act=0) |
virtual int | handle_exit (ACE_Process *) |
virtual int | handle_close (ACE_HANDLE handle, ACE_Reactor_Mask close_mask) |
virtual int | handle_signal (int signum, siginfo_t *=0, ucontext_t *=0) |
virtual int | resume_handler (void) |
virtual int | handle_qos (ACE_HANDLE=ACE_INVALID_HANDLE) |
virtual int | handle_group_qos (ACE_HANDLE=ACE_INVALID_HANDLE) |
virtual void | reactor (ACE_Reactor *reactor) |
virtual ACE_Reactor * | reactor (void) const |
virtual ACE_Reactor_Timer_Interface * | reactor_timer_interface (void) const |
virtual Reference_Count | add_reference (void) |
virtual Reference_Count | remove_reference (void) |
Reference_Counting_Policy & | reference_counting_policy (void) |
Private Member Functions | |
void | init () |
void | usage (const ACE_TCHAR *cmd) |
void | parse_args (int argc, ACE_TCHAR *argv[]) |
void | finalize () |
Actual finalization of service resources. More... | |
Private Attributes | |
CORBA::ORB_var | orb_ |
ACE_TString | ior_file_ |
std::string | listen_address_str_ |
int | listen_address_given_ |
bool | use_bits_ |
bool | resurrect_ |
ACE_Time_Value | reassociate_delay_ |
bool | finalized_ |
Flag to indicate that finalization has already occurred. More... | |
bool | servant_finalized_ |
OpenDDS::Federator::Config | federatorConfig_ |
Repository Federation behaviors. More... | |
OpenDDS::Federator::ManagerImpl | federator_ |
PortableServer::Servant_var< TAO_DDS_DCPSInfo_i > | info_servant_ |
ACE_Thread_Mutex | lock_ |
ACE_Condition_Thread_Mutex | cond_ |
bool | shutdown_complete_ |
int | shutdown_signal_ |
ACE_Time_Value | dispatch_cleanup_delay_ |
Definition at line 25 of file DCPSInfoRepoServ.h.
InfoRepo::InfoRepo | ( | int | argc, |
ACE_TCHAR * | argv[] | ||
) |
Definition at line 41 of file DCPSInfoRepoServ.cpp.
References ACE_TEXT(), finalize(), and init().
InfoRepo::~InfoRepo | ( | ) |
Definition at line 68 of file DCPSInfoRepoServ.cpp.
References finalize().
|
private |
Actual finalization of service resources.
Definition at line 87 of file DCPSInfoRepoServ.cpp.
References ACE_ERROR, TAO_DDS_DCPSInfo_i::cleanup_all_built_in_topics(), federator_, OpenDDS::Federator::ManagerImpl::finalize(), TAO_DDS_DCPSInfo_i::finalize(), finalized_, info_servant_, CORBA::is_nil(), LM_ERROR, orb_, OpenDDS::DCPS::retcode_to_string(), servant_finalized_, and TheServiceParticipant.
Referenced by InfoRepo(), run(), and ~InfoRepo().
|
virtual |
Handler for the reactor to dispatch finalization activity to.
Reimplemented from ACE_Event_Handler.
Definition at line 121 of file DCPSInfoRepoServ.cpp.
References ACE_DEBUG, ACE_ERROR, TAO_DDS_DCPSInfo_i::cleanup_all_built_in_topics(), federator_, OpenDDS::Federator::ManagerImpl::finalize(), TAO_DDS_DCPSInfo_i::finalize(), info_servant_, LM_DEBUG, LM_ERROR, orb_, OpenDDS::DCPS::retcode_to_string(), servant_finalized_, shutdown_signal_, and TheServiceParticipant.
|
private |
Definition at line 255 of file DCPSInfoRepoServ.cpp.
References ACE_DEBUG, ACE_ERROR, ACE_TEXT(), ACE_ARGV_T< CHAR_TYPE >::add(), ACE_ARGV_T< CHAR_TYPE >::argc(), ACE_ARGV_T< CHAR_TYPE >::argv(), OpenDDS::Federator::Config::argv(), ACE_OS::atoi(), ACE_String_Base< char >::c_str(), OpenDDS::DCPS::DCPS_debug_level, OpenDDS::DCPS::Discovery::DEFAULT_REPO, dispatch_cleanup_delay_, ACE_OS::fclose(), OpenDDS::Federator::Config::federateIor(), OpenDDS::Federator::Config::federationDomain(), OpenDDS::Federator::Config::federationId(), federator_, OpenDDS::Federator::FEDERATOR_IORTABLE_KEY, federatorConfig_, ACE_OS::fopen(), ACE_OS::fprintf(), OpenDDS::DCPS::Service_Participant::get_discovery(), OpenDDS::Federator::ManagerImpl::id(), TAO::String_var< charT >::in(), OpenDDS::Federator::ManagerImpl::info(), info_servant_, ior_file_, CORBA::is_nil(), LM_DEBUG, LM_ERROR, OpenDDS::Federator::ManagerImpl::localRepo(), OpenDDS::Federator::ManagerImpl::orb(), orb_, CORBA::ORB_init(), TAO_DDS_DCPSFederationId::overridden(), parse_args(), PortableServer::PERSISTENT, reassociate_delay_, OpenDDS::Federator::REPOSITORY_IORTABLE_KEY, resurrect_, OpenDDS::DCPS::Service_Participant::set_repo_ior(), OpenDDS::DCPS::static_rchandle_cast(), ACE_OS::strcmp(), PortableServer::string_to_ObjectId(), TheParticipantFactoryWithArgs, TheServiceParticipant, use_bits_, PortableServer::USER_ID, and ACE_Time_Value::zero.
Referenced by InfoRepo().
|
private |
Definition at line 193 of file DCPSInfoRepoServ.cpp.
References ACE_TEXT(), ACE_TEXT_ALWAYS_CHAR, ACE_OS::atoi(), ACE_Arg_Shifter_T< class >::consume_arg(), ACE_Arg_Shifter_T< class >::cur_arg_strncasecmp(), dispatch_cleanup_delay_, ACE_Arg_Shifter_T< class >::get_the_parameter(), ACE_Arg_Shifter_T< class >::ignore_arg(), ior_file_, ACE_Arg_Shifter_T< class >::is_anything_left(), listen_address_given_, listen_address_str_, ACE_Time_Value::msec(), reassociate_delay_, resurrect_, ACE_Time_Value::sec(), TURN_ON_VERBOSE_DEBUG, usage(), and use_bits_.
Referenced by init().
void InfoRepo::run | ( | void | ) |
Definition at line 76 of file DCPSInfoRepoServ.cpp.
References ACE_GUARD, cond_, finalize(), lock_, orb_, shutdown_complete_, and ACE_Condition< ACE_Thread_Mutex >::signal().
Referenced by ACE_TMAIN().
void InfoRepo::set_shutdown_signal | ( | int | which_signal | ) |
Definition at line 146 of file DCPSInfoRepoServ.cpp.
References shutdown_signal_.
Referenced by InfoRepo_Shutdown::operator()().
|
virtual |
ShutdownInterface used to schedule a shutdown.
Implements ShutdownInterface.
Definition at line 152 of file DCPSInfoRepoServ.cpp.
References orb_.
Referenced by InfoRepo_Shutdown::operator()(), and sync_shutdown().
void InfoRepo::sync_shutdown | ( | ) |
shutdown() and wait for it to complete: cannot be called from the reactor thread.
Definition at line 159 of file DCPSInfoRepoServ.cpp.
References ACE_GUARD, cond_, lock_, shutdown(), shutdown_complete_, and ACE_Condition< ACE_Thread_Mutex >::wait().
|
private |
Definition at line 170 of file DCPSInfoRepoServ.cpp.
References ACE_DEBUG, ACE_TEXT(), and LM_INFO.
Referenced by parse_args().
|
private |
Definition at line 78 of file DCPSInfoRepoServ.h.
Referenced by run(), and sync_shutdown().
|
private |
Definition at line 83 of file DCPSInfoRepoServ.h.
Referenced by init(), and parse_args().
|
private |
Definition at line 73 of file DCPSInfoRepoServ.h.
Referenced by finalize(), handle_exception(), and init().
|
private |
Repository Federation behaviors.
Definition at line 72 of file DCPSInfoRepoServ.h.
Referenced by init().
|
private |
Flag to indicate that finalization has already occurred.
Definition at line 68 of file DCPSInfoRepoServ.h.
Referenced by finalize().
|
private |
Definition at line 75 of file DCPSInfoRepoServ.h.
Referenced by finalize(), handle_exception(), and init().
|
private |
Definition at line 60 of file DCPSInfoRepoServ.h.
Referenced by init(), and parse_args().
|
private |
Definition at line 62 of file DCPSInfoRepoServ.h.
Referenced by parse_args().
|
private |
Definition at line 61 of file DCPSInfoRepoServ.h.
Referenced by parse_args().
|
private |
Definition at line 77 of file DCPSInfoRepoServ.h.
Referenced by run(), and sync_shutdown().
|
private |
Definition at line 58 of file DCPSInfoRepoServ.h.
Referenced by finalize(), handle_exception(), init(), run(), and shutdown().
|
private |
Definition at line 65 of file DCPSInfoRepoServ.h.
Referenced by init(), and parse_args().
|
private |
Definition at line 64 of file DCPSInfoRepoServ.h.
Referenced by init(), and parse_args().
|
private |
Definition at line 69 of file DCPSInfoRepoServ.h.
Referenced by finalize(), and handle_exception().
|
private |
Definition at line 79 of file DCPSInfoRepoServ.h.
Referenced by run(), and sync_shutdown().
|
private |
Definition at line 81 of file DCPSInfoRepoServ.h.
Referenced by handle_exception(), and set_shutdown_signal().
|
private |
Definition at line 63 of file DCPSInfoRepoServ.h.
Referenced by init(), and parse_args().