diff options
Diffstat (limited to 'netsvcs')
-rw-r--r-- | netsvcs/clients/Naming/Client/Client_Test.cpp | 6 | ||||
-rw-r--r-- | netsvcs/clients/Naming/Client/main.cpp | 2 | ||||
-rw-r--r-- | netsvcs/clients/Naming/Dump_Restore/Dump_Restore.cpp | 8 | ||||
-rw-r--r-- | netsvcs/clients/Naming/Dump_Restore/main.cpp | 3 | ||||
-rw-r--r-- | netsvcs/clients/Tokens/collection/collection.cpp | 4 | ||||
-rw-r--r-- | netsvcs/clients/Tokens/manual/manual.cpp | 8 | ||||
-rw-r--r-- | netsvcs/lib/Client_Logging_Handler.cpp | 6 | ||||
-rw-r--r-- | netsvcs/lib/Name_Handler.cpp | 2 | ||||
-rw-r--r-- | netsvcs/lib/Server_Logging_Handler_T.cpp | 8 | ||||
-rw-r--r-- | netsvcs/lib/TS_Clerk_Handler.cpp | 12 | ||||
-rw-r--r-- | netsvcs/lib/TS_Server_Handler.cpp | 2 | ||||
-rw-r--r-- | netsvcs/lib/Token_Handler.cpp | 2 | ||||
-rw-r--r-- | netsvcs/servers/main.cpp | 10 |
13 files changed, 36 insertions, 37 deletions
diff --git a/netsvcs/clients/Naming/Client/Client_Test.cpp b/netsvcs/clients/Naming/Client/Client_Test.cpp index 850294843c4..36fd6ba1317 100644 --- a/netsvcs/clients/Naming/Client/Client_Test.cpp +++ b/netsvcs/clients/Naming/Client/Client_Test.cpp @@ -119,8 +119,8 @@ Client_Test::open (void) this->display_menu (); if (ACE::register_stdin_handler (this, - ACE_Service_Config::reactor (), - ACE_Service_Config::thr_mgr ()) == -1) + ACE_Reactor::instance (), + ACE_Thread_Manager::instance ()) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "register_stdin_handler"), -1); return 0; } @@ -130,7 +130,7 @@ int Client_Test::close (void) { // Deregister this handler with the ACE_Reactor. - return ACE_Service_Config::reactor ()->remove_handler + return ACE_Reactor::instance ()->remove_handler (ACE_STDIN, ACE_Event_Handler::DONT_CALL | ACE_Event_Handler::READ_MASK); } diff --git a/netsvcs/clients/Naming/Client/main.cpp b/netsvcs/clients/Naming/Client/main.cpp index 88d370aca66..93ecb8ba823 100644 --- a/netsvcs/clients/Naming/Client/main.cpp +++ b/netsvcs/clients/Naming/Client/main.cpp @@ -36,7 +36,7 @@ main (int argc, char *argv[]) // Run forever, performing the configured services until we are shut // down by a SIGINT/SIGQUIT signal. - ACE_Service_Config::run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); return 0; } diff --git a/netsvcs/clients/Naming/Dump_Restore/Dump_Restore.cpp b/netsvcs/clients/Naming/Dump_Restore/Dump_Restore.cpp index 07a57ca3b88..e06b09ff499 100644 --- a/netsvcs/clients/Naming/Dump_Restore/Dump_Restore.cpp +++ b/netsvcs/clients/Naming/Dump_Restore/Dump_Restore.cpp @@ -35,15 +35,15 @@ Dump_Restore::Dump_Restore (int argc, char *argv[]) this->display_menu (); if (ACE::register_stdin_handler (this, - ACE_Service_Config::reactor (), - ACE_Service_Config::thr_mgr ()) == -1) + ACE_Reactor::instance (), + ACE_Thread_Manager::instance ()) == -1) ACE_ERROR ((LM_ERROR, "%p\n", "register_stdin_handler")); } Dump_Restore::~Dump_Restore (void) { // Deregister this handler with the ACE_Reactor. - ACE_Service_Config::reactor ()->remove_handler + ACE_Reactor::instance ()->remove_handler (ACE_STDIN, ACE_Event_Handler::DONT_CALL | ACE_Event_Handler::READ_MASK); @@ -264,7 +264,7 @@ Dump_Restore::populate (Dump_Restore::Operation_Type op) // reset file pointer ACE_OS::rewind (this->infile_); - ACE_Allocator *allocator = ACE_Service_Config::alloc (); + ACE_Allocator *allocator = ACE_Allocator::instance (); ACE_Read_Buffer read_buffer (this->infile_, 0, allocator); for (char *temp; (temp = read_buffer.read ('\n')) != 0; ) diff --git a/netsvcs/clients/Naming/Dump_Restore/main.cpp b/netsvcs/clients/Naming/Dump_Restore/main.cpp index 52b17884573..3bb75ff26ac 100644 --- a/netsvcs/clients/Naming/Dump_Restore/main.cpp +++ b/netsvcs/clients/Naming/Dump_Restore/main.cpp @@ -14,8 +14,7 @@ main (int argc, char *argv[]) // Get a handler Dump_Restore client_handler (argc, argv); - for (;;) - daemon.run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); /* NOTREACHED */ ACE_DEBUG ((LM_DEBUG, "leaving main\n")); diff --git a/netsvcs/clients/Tokens/collection/collection.cpp b/netsvcs/clients/Tokens/collection/collection.cpp index 68f7e40b0a4..44a58ffec02 100644 --- a/netsvcs/clients/Tokens/collection/collection.cpp +++ b/netsvcs/clients/Tokens/collection/collection.cpp @@ -41,7 +41,7 @@ static int remote = 0; static void * run_thread (void *vp) { - ACE_Thread_Control tc (ACE_Service_Config::thr_mgr ()); + ACE_Thread_Control tc (ACE_Thread_Manager::instance ()); ACE_Token_Proxy *collection = (ACE_Token_Proxy *) vp; int count = iterations; @@ -176,7 +176,7 @@ main (int argc, char* argv[]) collectionBR.insert (*R); // Spawn off three threads. - ACE_Thread_Manager *mgr = ACE_Service_Config::thr_mgr (); + ACE_Thread_Manager *mgr = ACE_Thread_Manager::instance (); if (mgr->spawn (ACE_THR_FUNC (run_thread), (void *) &collectionAR, THR_BOUND | THR_SUSPENDED) == -1) diff --git a/netsvcs/clients/Tokens/manual/manual.cpp b/netsvcs/clients/Tokens/manual/manual.cpp index f9f269bb0c3..de9282ffc21 100644 --- a/netsvcs/clients/Tokens/manual/manual.cpp +++ b/netsvcs/clients/Tokens/manual/manual.cpp @@ -146,7 +146,7 @@ STDIN_Token::open (int argc, char *argv[]) return -1; // Register for signals. - if (ACE_Service_Config::reactor ()->register_handler + if (ACE_Reactor::instance ()->register_handler (SIGINT, this) == -1) ACE_DEBUG ((LM_DEBUG, "Can't register signal handler\n")); @@ -154,7 +154,7 @@ STDIN_Token::open (int argc, char *argv[]) #else // Register for STDIN events with Reactor. - if (ACE_Service_Config::reactor ()->register_handler + if (ACE_Reactor::instance ()->register_handler (ACE_STDIN, this, ACE_Event_Handler::READ_MASK) == -1) ACE_ERROR_RETURN ((LM_DEBUG, "Can't register signal handler\n"), 0); @@ -167,7 +167,7 @@ STDIN_Token::open (int argc, char *argv[]) #if (ACE_WIN32) #else - ACE_Service_Config::run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); #endif /* ACE_WIN32 */ ACE_OS::printf ("Exiting...\n"); @@ -260,7 +260,7 @@ STDIN_Token::handle_exception (ACE_HANDLE fd) { ACE_UNUSED_ARG (fd); - ACE_Service_Config::run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); return -1; } diff --git a/netsvcs/lib/Client_Logging_Handler.cpp b/netsvcs/lib/Client_Logging_Handler.cpp index d59b963e6f5..53f94af6c36 100644 --- a/netsvcs/lib/Client_Logging_Handler.cpp +++ b/netsvcs/lib/Client_Logging_Handler.cpp @@ -18,7 +18,7 @@ ACE_Client_Logging_Handler::ACE_Client_Logging_Handler (const char rendezvous[]) // Register message FIFO to receive input from clients. Note that // we need to put the EXCEPT_MASK here to deal with SVR4 MSG_BAND // data correctly... - else if (ACE_Service_Config::reactor ()->register_handler + else if (ACE_Reactor::instance ()->register_handler (this->message_fifo_.get_handle (), this, ACE_Event_Handler::READ_MASK | ACE_Event_Handler::EXCEPT_MASK) == -1) ACE_ERROR ((LM_ERROR, "%n: %p\n", @@ -48,7 +48,7 @@ ACE_Client_Logging_Handler::open (void *) // Register ourselves to receive SIGPIPE so we can attempt // reconnections. #if !defined (ACE_WIN32) - if (ACE_Service_Config::reactor ()->register_handler (SIGPIPE, this) == -1) + if (ACE_Reactor::instance ()->register_handler (SIGPIPE, this) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%n: %p\n", "register_handler (SIGPIPE)"), -1); #endif /* ACE_WIN32 */ @@ -116,7 +116,7 @@ ACE_Client_Logging_Handler::close (u_long) { ACE_DEBUG ((LM_DEBUG, "shutting down!!!\n")); - if (ACE_Service_Config::reactor ()->remove_handler + if (ACE_Reactor::instance ()->remove_handler (this->message_fifo_.get_handle (), ACE_Event_Handler::READ_MASK | ACE_Event_Handler::EXCEPT_MASK | ACE_Event_Handler::DONT_CALL) == -1) ACE_ERROR ((LM_ERROR, "%n: %p\n", diff --git a/netsvcs/lib/Name_Handler.cpp b/netsvcs/lib/Name_Handler.cpp index 1323922fd81..0cf4deb65fe 100644 --- a/netsvcs/lib/Name_Handler.cpp +++ b/netsvcs/lib/Name_Handler.cpp @@ -52,7 +52,7 @@ ACE_Name_Acceptor::init (int argc, char *argv[]) // Set the acceptor endpoint into listen mode (use the Singleton // global Reactor...). - if (this->open (this->service_addr_, ACE_Service_Config::reactor (), + if (this->open (this->service_addr_, ACE_Reactor::instance (), 0, 0, 0, &this->scheduling_strategy_, "Name Server", "ACE naming service") == -1) diff --git a/netsvcs/lib/Server_Logging_Handler_T.cpp b/netsvcs/lib/Server_Logging_Handler_T.cpp index 5d85bc14a8f..5e0916b5c26 100644 --- a/netsvcs/lib/Server_Logging_Handler_T.cpp +++ b/netsvcs/lib/Server_Logging_Handler_T.cpp @@ -139,7 +139,7 @@ ACE_Server_Logging_Acceptor_T<SLH, LMR, SS>::init (int argc, char *argv[]) // Set the acceptor endpoint into listen mode (use the Singleton // global Reactor...). if (this->open (this->service_addr_, - ACE_Service_Config::reactor (), + ACE_Reactor::instance (), 0, 0, 0, &this->scheduling_strategy(), "Logging Server", "ACE logging service") == -1) @@ -198,7 +198,7 @@ template<class SLH, class LMR, class SS> int ACE_Server_Logging_Acceptor_T<SLH, LMR, SS>::make_svc_handler (SLH *&handler) { ACE_NEW_RETURN (handler, - SLH (ACE_Service_Config::thr_mgr (), this->receiver()), + SLH (ACE_Thread_Manager::instance (), this->receiver()), -1); return 0; } @@ -226,7 +226,7 @@ ACE_Server_Logging_Handler<LMR>::open (void *) // Register ourselves with the Reactor to enable subsequent // dispatching. - if (ACE_Service_Config::reactor ()->register_handler + if (ACE_Reactor::instance ()->register_handler (this, ACE_Event_Handler::READ_MASK) == -1) return -1; return 0; @@ -253,7 +253,7 @@ ACE_Thr_Server_Logging_Handler<LMR>::open (void *) // Spawn a new thread of control to handle logging records with the // client. Note that this implicitly uses the - // ACE_Service_Config::thr_mgr () to control all the threads. + // ACE_Thread_Manager::instance () to control all the threads. if (this->activate (THR_BOUND | THR_DETACHED) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "spawn"), -1); return 0; diff --git a/netsvcs/lib/TS_Clerk_Handler.cpp b/netsvcs/lib/TS_Clerk_Handler.cpp index ae44474533e..272c30811ac 100644 --- a/netsvcs/lib/TS_Clerk_Handler.cpp +++ b/netsvcs/lib/TS_Clerk_Handler.cpp @@ -99,13 +99,13 @@ ACE_TS_Clerk_Handler::open (void *) // Register ourselves to receive SIGPIPE so we can attempt // reconnections. #if !defined (ACE_WIN32) - if (ACE_Service_Config::reactor ()->register_handler (SIGPIPE, this) == -1) + if (ACE_Reactor::instance ()->register_handler (SIGPIPE, this) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%n: %p\n", "register_handler (SIGPIPE)"), -1); #endif // Register ourselves with the reactor to receive input - if (ACE_Service_Config::reactor ()->register_handler (this->get_handle (), + if (ACE_Reactor::instance ()->register_handler (this->get_handle (), this, ACE_Event_Handler::READ_MASK | ACE_Event_Handler::EXCEPT_MASK) == -1) @@ -156,7 +156,7 @@ ACE_TS_Clerk_Handler::reinitiate_connection (void) ACE_DEBUG ((LM_DEBUG, "(%t) Scheduling reinitiation of connection\n")); // Reschedule ourselves to try and connect again. - if (ACE_Service_Config::reactor ()->schedule_timer (this, 0, + if (ACE_Reactor::instance ()->schedule_timer (this, 0, this->timeout ()) == -1) ACE_ERROR_RETURN ((LM_ERROR, "(%t) %p\n", "schedule_timer"), -1); } @@ -397,7 +397,7 @@ ACE_TS_Clerk_Processor::fini (void) // Cancel the timer if (this->timer_id_ != -1) - ACE_Service_Config::reactor ()->cancel_timer (this->timer_id_); + ACE_Reactor::instance ()->cancel_timer (this->timer_id_); // Destroy all the handlers ACE_TS_Clerk_Handler **handler = 0; @@ -459,7 +459,7 @@ ACE_TS_Clerk_Processor::init (int argc, char *argv[]) } // Now set up timer to receive updates from server // set the timer to go off after timeout value - this->timer_id_ = ACE_Service_Config::reactor ()->schedule_timer (this, + this->timer_id_ = ACE_Reactor::instance ()->schedule_timer (this, NULL, ACE_Time_Value (this->timeout_), ACE_Time_Value (this->timeout_)); @@ -494,7 +494,7 @@ ACE_TS_Clerk_Processor::initiate_connection (ACE_TS_Clerk_Handler *handler, // Reschedule ourselves to try and connect again. if (synch_options[ACE_Synch_Options::USE_REACTOR]) { - if (ACE_Service_Config::reactor ()->schedule_timer (handler, + if (ACE_Reactor::instance ()->schedule_timer (handler, 0, handler->timeout ()) == -1) ACE_ERROR_RETURN ((LM_ERROR, "(%t) %p\n", "schedule_timer"), -1); diff --git a/netsvcs/lib/TS_Server_Handler.cpp b/netsvcs/lib/TS_Server_Handler.cpp index a6ee2c59d4c..95736e085c7 100644 --- a/netsvcs/lib/TS_Server_Handler.cpp +++ b/netsvcs/lib/TS_Server_Handler.cpp @@ -46,7 +46,7 @@ ACE_TS_Server_Acceptor::init (int argc, char *argv[]) // Set the acceptor endpoint into listen mode (use the Singleton // global Reactor...). - if (this->open (this->service_addr_, ACE_Service_Config::reactor (), + if (this->open (this->service_addr_, ACE_Reactor::instance (), 0, 0, 0, &this->scheduling_strategy_, "Time Server", "ACE time service") == -1) diff --git a/netsvcs/lib/Token_Handler.cpp b/netsvcs/lib/Token_Handler.cpp index cce62947988..0a520bc6afa 100644 --- a/netsvcs/lib/Token_Handler.cpp +++ b/netsvcs/lib/Token_Handler.cpp @@ -47,7 +47,7 @@ ACE_Token_Acceptor::init (int argc, char *argv[]) // Set the acceptor endpoint into listen mode (use the Singleton // global Reactor...). - if (this->open (this->service_addr_, ACE_Service_Config::reactor (), + if (this->open (this->service_addr_, ACE_Reactor::instance (), 0, 0, 0, &this->scheduling_strategy_, "Token Server", "ACE token service") == -1) diff --git a/netsvcs/servers/main.cpp b/netsvcs/servers/main.cpp index 1052dd2d0aa..237bb0b5f29 100644 --- a/netsvcs/servers/main.cpp +++ b/netsvcs/servers/main.cpp @@ -30,7 +30,7 @@ main (int argc, char *argv[]) ACE_Service_Config daemon; // Create an adapter to end the event loop. - ACE_Sig_Adapter sa ((ACE_Sig_Handler_Ex) ACE_Service_Config::end_reactor_event_loop); + ACE_Sig_Adapter sa ((ACE_Sig_Handler_Ex) ACE_Reactor::end_event_loop); ACE_Sig_Set sig_set; sig_set.sig_add (SIGINT); @@ -39,10 +39,10 @@ main (int argc, char *argv[]) // Register ourselves to receive SIGINT and SIGQUIT so we can shut // down gracefully via signals. #if !defined (ACE_WIN32) - if (ACE_Service_Config::reactor ()->register_handler (sig_set, &sa) == -1) + if (ACE_Reactor::instance ()->register_handler (sig_set, &sa) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%p\n"), -1); #else - if (ACE_Service_Config::reactor ()->register_handler (SIGINT, &sa) == -1) + if (ACE_Reactor::instance ()->register_handler (SIGINT, &sa) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%p\n"), -1); #endif /* ACE_WIN32 */ @@ -102,7 +102,7 @@ main (int argc, char *argv[]) // Run forever, performing the configured services until we are shut // down by a SIGINT/SIGQUIT signal. - daemon.run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); // Destructors of Service_Ptr's automagically call fini(). } @@ -111,7 +111,7 @@ main (int argc, char *argv[]) // Run forever, performing the configured services until we are shut // down by a SIGINT/SIGQUIT signal. - daemon.run_reactor_event_loop (); + ACE_Reactor::run_event_loop (); return 0; } |