summaryrefslogtreecommitdiff
path: root/trunk/CIAO/DAnCE/TargetManager/TargetManagerExt.idl
blob: 26d0c336b626b41b4a230c07e85e789ffc3bd7f1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
// $Id$

/**
 * @file TargetManagerExt.idl
 *
 * @brief The Extensions to the TM interface for ARMS demo
 *
 * @author Nilabja R <nilabjar@dre.vanderbilt.edu>
 * @author Nishanth Shankaran <nshankar@dre.vanderbilt.edu>
 *
 * This file declares a interface which will be implemented as
 * a facet by the TargetManager component
 */

#include "DAnCE/Interfaces/NodeManagerDaemon.idl"

module CIAO
{
  /**
   * @struct Cpu_Info
   * @brief Consists of individual host-cpu info
   */
  struct Host_Info
  {
    string hostname;
    double cpu_util;
  };

  /// The sequence of CPU infos
  typedef sequence<Host_Info> Host_Infos;

  /**
   * @struct Component_Cpu_Util
   * @brief Contains a component CPU Util
   */
  struct Component_Info
  {
    string component_name;
    double cpu_util;
  };

  /// The sequence of component cpu utilization
  typedef sequence <Component_Info> Component_Infos;


  /**
   * @struct Host_NodeManager
   * @brief Contains the node manager to host reference
   */
  struct Host_NodeManager
  {
    /// host name
    string host_;

    /// the node manager IOR
    ::CIAO::NodeManagerDaemon node_mgr_;
  };

  /// Sequence of NodeManager.
  typedef sequence <Host_NodeManager> Host_NodeManager_seq;

  /**
   * @interface TargetManagerExt
   * @brief The Target Manager Extension
   *
   * Contains the interface used by the RACE
   * controller.
   */
  interface TargetManagerExt
  {
    ///Returns the pid in which a component runs
    long get_pid (in string component_uuid);
    
    /// returns the cpu usage for each host in the 
    /// last cycle
    Host_Infos get_host_cpu ();
    
    /// Return the detail of the components
    Component_Infos get_component_cpu ();

    /// Returns the OR of the Node managers
    Host_NodeManager_seq get_all_node_managers ();
  };
};