Changeset 21015

Show
Ignore:
Timestamp:
02/09/08 20:13:19 (8 months ago)
Author:
patrick
Message:

Changed the remote run-time performance monitoring plug-in to take advantage
of Tweek 1.3.4 and its support for direct connections to Subject Manager
servants. Now, users need not run the CORBA Naming Service to be able to
connect the VRJConfig performance monitoring plug-in to a running VR Juggler
application.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • juggler/trunk/modules/vrjuggler/plugins/configure.ac

    r20974 r21015  
    146146VPR_PATH([1.1.23], , [AC_MSG_ERROR([*** VPR required for plugins ***])]) 
    147147 
    148 min_tweek_version='1.1.10
     148min_tweek_version='1.3.4
    149149if test "x$test_tweek_cxx" = "xY" ; then 
    150150   TWEEK_PATH_CXX([$min_tweek_version], [HAVE_TWEEK_CXX='Y'], 
  • juggler/trunk/modules/vrjuggler/plugins/corba_perf_mon/CorbaPerfPlugin.cpp

    r20974 r21015  
    8181   bool CorbaPerfPlugin::configAdd(jccl::ConfigElementPtr element) 
    8282   { 
     83      const unsigned int min_def_version(2); 
     84 
     85      if ( element->getVersion() < min_def_version ) 
     86      { 
     87         vprDEBUG(jcclDBG_PLUGIN, vprDBG_WARNING_LVL) 
     88            << clrOutBOLD(clrYELLOW, "WARNING") << ": Element named '" 
     89            << element->getName() << "'" << std::endl; 
     90         vprDEBUG_NEXTnl(jcclDBG_PLUGIN, vprDBG_WARNING_LVL) 
     91            << "is version " << element->getVersion() 
     92            << ", but we expect at least version " << min_def_version 
     93            << ".\n"; 
     94         vprDEBUG_NEXTnl(jcclDBG_PLUGIN, vprDBG_WARNING_LVL) 
     95            << "Default values will be used for some settings.\n" 
     96            << vprDEBUG_FLUSH; 
     97      } 
     98 
    8399      // If the ORB is already running, we need to shut it down first.  One big 
    84100      // reason for doing this is to release the resources (memory and so on) 
     
    87103      { 
    88104         vprDEBUG(vrjDBG_PLUGIN, vprDBG_STATE_LVL) 
    89          << "[CorbaPerfPlugin::configAdd()] Attempting to shut down " 
     105            << "[CorbaPerfPlugin::configAdd()] Attempting to shut down " 
    90106            << "existing CORBA instance.\n" << vprDEBUG_FLUSH; 
    91107 
     
    94110      } 
    95111 
    96       const std::string ns_host = 
    97          element->getProperty<std::string>("naming_service_host"); 
    98       const vpr::Uint16 ns_port = 
    99          element->getProperty<vpr::Uint16>("naming_service_port"); 
    100       const std::string iiop_version = 
    101          element->getProperty<std::string>("iiop_version"); 
    102  
    103112      // We'll ignore the return value for now.  startCorba() prints out enough 
    104113      // warning information on its own if something goes wrong. 
    105       this->startCorba(ns_host, ns_port, iiop_version); 
     114      this->startCorba(element->getProperty<std::string>("endpoint_addr"), 
     115                       element->getProperty<vpr::Uint16>("endpoint_port")); 
    106116 
    107117      return true; 
     
    176186   } 
    177187 
    178    bool CorbaPerfPlugin::startCorba(const std::string& nsHost, 
    179                                     const vpr::Uint16 nsPort, 
    180                                     const std::string& iiopVer) 
     188   bool CorbaPerfPlugin::startCorba(const std::string& listenAddr, 
     189                                    const vpr::Uint16 listenPort) 
    181190   { 
    182191      // Create new CORBA Manager and initialize it. 
     
    190199 
    191200         // Attempt to initialize the CORBA Manager. 
    192          bool status = mCorbaManager->init("corba_perf_mon", dummy_int, NULL, 
    193                                            nsHost, nsPort, iiopVer); 
     201         bool status = mCorbaManager->initDirect("corba_perf_mon", dummy_int, 
     202                                                 NULL, listenAddr, 
     203                                                 listenPort); 
    194204 
    195205         // Test to see if init succeeded. 
  • juggler/trunk/modules/vrjuggler/plugins/corba_perf_mon/CorbaPerfPlugin.h

    r20974 r21015  
    102102       * handling remote performance monitoring requests. 
    103103       * 
    104        * @param nsHost  The name of the host computer where the CORBA Naming 
    105        *                Service is running. 
    106        * @param nsport  The port number on which the CORBA Naming Service is 
    107        *                listening for incoming connections. 
    108        * @param iiopVer The version of IIOP the Naming Service is using.  This 
    109        *                is normally 1.0 or 1.2. 
     104       * @param listenAddr The address to which the CORBA endpoint will be 
     105       *                   bound. Using an empty string will result in binding 
     106       *                   to the default interface. 
     107       * @param listenPort The port number for the CORBA endpoint. This must 
     108       *                   be a valid port number. 
    110109       */ 
    111       bool startCorba(const std::string& nsHost, const vpr::Uint16 nsPort
    112                       const std::string& iiopVer); 
     110      bool startCorba(const std::string& listenAddr
     111                      const vpr::Uint16 listenPort); 
    113112 
    114113      /**