update from RIFT as of 696b75d2fe9fb046261b08c616f1bcf6c0b54a9b second try
[osm/SO.git] / rwmon / plugins / vala / rwmon.vala
1 namespace RwMon {
2   public interface Monitoring: GLib.Object {
3     /**
4      * Init routine
5      *
6      * @param log_ctx - [in] the log context to use
7      *
8      * @return RwStatus
9      */
10     public abstract RwTypes.RwStatus init(RwLog.Ctx log_ctx);
11
12     /**
13      * nfvi_metrics
14      *
15      * Returns the NFVI metrics for a particular VM
16      *
17      * @param account - [in] the account details of the owner of the VM
18      * @param vm_id   - [in] the ID of the VM to retrieve the metrics from
19      * @param metrics - [out] An NfviMetrics object
20      *
21      * @return RwStatus
22      */
23     public abstract RwTypes.RwStatus nfvi_metrics(
24       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
25       string vm_id,
26       out Rwmon.YangData_RwProject_Project_NfviMetrics metrics);
27
28     /**
29      * nfvi_vcpu_metrics
30      *
31      * Returns the VCPU metrics for a particular VM
32      *
33      * @param account - [in] the account details of the owner of the VM
34      * @param vm_id   - [in] the ID of the VM to retrieve the metrics from
35      * @param metrics - [out] An NfviMetrics_Vcpu object
36      *
37      * @return RwStatus
38      */
39     public abstract RwTypes.RwStatus nfvi_vcpu_metrics(
40       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
41       string vm_id,
42       out Rwmon.YangData_RwProject_Project_NfviMetrics_Vcpu metrics);
43
44     /**
45      * nfvi_memory_metrics
46      *
47      * Returns the memory metrics for a particular VM
48      *
49      * @param account - [in] the account details of the owner of the VM
50      * @param vm_id   - [in] the ID of the VM to retrieve the metrics from
51      * @param metrics - [out] An NfviMetrics_Memory object
52      *
53      * @return RwStatus
54      */
55     public abstract RwTypes.RwStatus nfvi_memory_metrics(
56       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
57       string vm_id,
58       out Rwmon.YangData_RwProject_Project_NfviMetrics_Memory metrics);
59
60     /**
61      * nfvi_storage_metrics
62      *
63      * Returns the storage metrics for a particular VM
64      *
65      * @param account - [in] the account details of the owner of the VM
66      * @param vm_id   - [in] the ID of the VM to retrieve the metrics from
67      * @param metrics - [out] An NfviMetrics_Storage object
68      *
69      * @return RwStatus
70      */
71     public abstract RwTypes.RwStatus nfvi_storage_metrics(
72       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
73       string vm_id,
74       out Rwmon.YangData_RwProject_Project_NfviMetrics_Storage metrics);
75
76     /**
77      * nfvi_metrics_available
78      *
79      * Checks whether ceilometer exists for this account and is 
80      * providing NFVI metrics
81      *
82      * @param account - [in] the account details of the owner of the VM
83      * @param present - [out] True if ceilometer exists, False otherwise
84      *
85      * @return RwStatus
86      */
87     public abstract RwTypes.RwStatus nfvi_metrics_available(
88       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
89       out bool present);
90
91     /**
92      * alarm_create
93      *
94      * @param account - [in] the credentials required to update the alarm.
95      * @param vim_id  - [in] the identifier assigned by a VIM to the VDU that
96      *                  the alarm is associated with.
97      * @param alarm   - [ref] an alarm structure defining the alarm. Note that
98      *                  the underlying implmentation will fill in the alarm_id
99      *                  attribute, which is required for modifying or deleting
100      *                  an alarm.
101      *
102      * @return RwStatus
103      */
104     public abstract RwTypes.RwStatus alarm_create(
105       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
106       string vim_id,
107       ref Rwmon.YangData_RwProject_Project_Alarm alarm);
108
109     /**
110      * alarm_update
111      *
112      * @param account - [in] the credentials required to update the alarm.
113      * @param alarm   - [in] the complete alarm structure defining the alarm.
114      *                  This means that the alarm structure must contain a
115      *                  valid alarm_id, and any attribute of the structure that
116      *                  differs from the actual alarm will be updated to match
117      *                  the provided data.
118      *
119      * @return RwStatus
120      */
121     public abstract RwTypes.RwStatus alarm_update(
122       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
123       Rwmon.YangData_RwProject_Project_Alarm alarm);
124
125     /**
126      * alarm_delete
127      *
128      * @param account  - [in] the credentials required to delete the alarm.
129      * @param alarm_id - [in] the identifier of the alarm to delete
130      *
131      * @return RwStatus
132      */
133     public abstract RwTypes.RwStatus alarm_delete(
134       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
135       string alarm_id);
136
137     /**
138      * alarm_list
139      *
140      * @param account  - [in] the credentials required to list the alarms.
141      * @param alarms   - [out] a list of alarms
142      *
143      * @return RwStatus
144      */
145     public abstract RwTypes.RwStatus alarm_list(
146       Rwcal.YangData_RwProject_Project_CloudAccounts_CloudAccountList account,
147       out Rwmon.YangData_RwProject_Project_Alarm[] alarms);
148   }
149 }