Server_Info.h

Go to the documentation of this file.
00001 //=============================================================================
00002 /**
00003  *  @file    Server_Info.h
00004  *
00005  *  Server_Info.h,v 1.6 2005/04/12 22:18:48 michel_j Exp
00006  *
00007  *  This class implements the Server_Info for the Implementation Repository.
00008  *
00009  *
00010  *  @author Darrell Brunsch <brunsch@cs.wustl.edu>
00011  *  @author Priyanka Gontla <gontla_p@ociweb.com>
00012  */
00013 #ifndef SERVER_INFO_H
00014 #define SERVER_INFO_H
00015 
00016 #include "ace/Bound_Ptr.h"
00017 
00018 #include "tao/ImR_Client/ImplRepoC.h"
00019 
00020 #include "ace/SString.h"
00021 
00022 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00023 # pragma once
00024 #endif /* ACE_LACKS_PRAGMA_ONCE */
00025 
00026 /**
00027 * @brief Information about IMR registered servers.
00028 */
00029 struct Server_Info
00030 {
00031   Server_Info (const ACE_CString& server_name,
00032     const ACE_CString& aname,
00033     const ACE_CString& cmdline,
00034     const ImplementationRepository::EnvironmentList& env,
00035     const ACE_CString& working_dir,
00036     ImplementationRepository::ActivationMode amode,
00037     int start_limit,
00038     const ACE_CString& partial_ior = ACE_CString(""),
00039     const ACE_CString& server_ior = ACE_CString(""),
00040     ImplementationRepository::ServerObject_ptr svrobj = ImplementationRepository::ServerObject::_nil()
00041     );
00042 
00043   /// Convert to the corba type
00044   ImplementationRepository::ServerInformation* createImRServerInfo(ACE_ENV_SINGLE_ARG_DECL);
00045 
00046   void reset();
00047 
00048   /// The name of the server.
00049   ACE_CString name;
00050   /// The name of the activator in which this server runs
00051   ACE_CString activator;
00052   /// The command line startup command (program and arguments).
00053   ACE_CString cmdline;
00054   /// Environment Variables.
00055   ImplementationRepository::EnvironmentList env_vars;
00056   /// The working directory.
00057   ACE_CString dir;
00058   /// The type of activation this supports.
00059   ImplementationRepository::ActivationMode activation_mode;
00060   /// Limit of retries to start the server
00061   int start_limit;
00062   /// Current endpoint used by the server.
00063   ACE_CString partial_ior;
00064   /// IOR of the server object in the server.
00065   ACE_CString ior;
00066   /// The timestamp of the last time we verified the server is alive
00067   ACE_Time_Value last_ping;
00068   /// The cached server object
00069   ImplementationRepository::ServerObject_var server;
00070   int start_count;
00071   int waiting_clients;
00072   bool starting;
00073 };
00074 
00075 typedef ACE_Strong_Bound_Ptr<Server_Info, ACE_Null_Mutex> Server_Info_Ptr;
00076 
00077 #endif /* SERVER_INFO_H */

Generated on Thu Nov 9 13:36:20 2006 for TAO_Implementation_Repository by doxygen 1.3.6