diff --git a/src/oca/java/src/org/opennebula/client/host/HostPool.java b/src/oca/java/src/org/opennebula/client/host/HostPool.java index 0acbf94d71..9de7640ff3 100644 --- a/src/oca/java/src/org/opennebula/client/host/HostPool.java +++ b/src/oca/java/src/org/opennebula/client/host/HostPool.java @@ -74,6 +74,20 @@ public class HostPool extends Pool implements Iterable{ return client.call(MONITORING); } + /** + * Retrieves the monitoring data for all the hosts in the pool. + * + * @param client XML-RPC Client. + * @param num number of monitoring records to be retrieved, if -1 + * every record will be retrieved. + * @return If successful the message contains the string + * with the information returned by OpenNebula. + */ + public static OneResponse monitoring(Client client, int num) + { + return client.call(MONITORING, num); + } + /** * Loads the xml representation of the host pool. * diff --git a/src/oca/java/src/org/opennebula/client/vm/VirtualMachinePool.java b/src/oca/java/src/org/opennebula/client/vm/VirtualMachinePool.java index 503b52f5ca..d17c971beb 100644 --- a/src/oca/java/src/org/opennebula/client/vm/VirtualMachinePool.java +++ b/src/oca/java/src/org/opennebula/client/vm/VirtualMachinePool.java @@ -251,6 +251,30 @@ public class VirtualMachinePool extends Pool implements Iterable return client.call(MONITORING, filter); } + /** + * Retrieves the monitoring data for all or part of the Virtual + * Machines in the pool. + * + * @param client XML-RPC Client. + * @param filter Filter flag to use. Possible values: + * + * @param num number of monitoring records to be retrieved, if -1 + * every record will be retrieved. + * @return If successful the message contains the string + * with the information returned by OpenNebula. + */ + public static OneResponse monitoring(Client client, int filter, int num) + { + return client.call(MONITORING, filter, num); + } + /** * Loads the xml representation of all or part of the * Virtual Machines in the pool. The filter used is the one set in