Class ResGroup
Defined in: rhqapi.js.
Constructor Attributes | Constructor Name and Description |
---|---|
ResGroup(param)
|
Field Attributes | Field Name and Description |
---|---|
gets ID of this group
|
|
gets name of this group
|
|
gets underlying ResourceGroup instance
|
Method Attributes | Method Name and Description |
---|---|
getId()
returns ID of this group
|
|
getMetricIntervals(metricName)
Returns Array with metric intervals of given metric for all resources in this group.
|
|
getMetricStatuses(metricName)
Returns Array with metric statuses of given metric for all resources in this group.
|
|
isMetricDisabled(metricName)
Returns true only if given metric is disabled on all resources in this group
|
|
isMetricEnabled(metricName)
Returns true only if given metric is enabled on all resources in this group
|
|
remove()
removes this resource group
|
|
resources(params)
get explicit resources contained in this group
|
|
resourcesImpl(params)
get implicit resources contained in this group
|
|
runOperation(params)
Invokes operation on this group and returns result of the operation.
|
|
scheduleOperation(params)
Schedules operation on this group.
|
|
scheduleOperationUsingCron(name, cronExpression, opParams)
schedules operation on this group using cron expression.
|
Field Detail
id
gets ID of this group
name
gets name of this group
obj
gets underlying ResourceGroup instance
Method Detail
{Number}
getId()
returns ID of this group
getMetricIntervals(metricName)
Returns Array with metric intervals of given metric for all resources in this group.
- Parameters:
- {String} metricName
- Returns:
- Array with javascript objects (hashmap) with following keys:
- id {String} - resource id
- interval {Number} - metric collection interval
getMetricStatuses(metricName)
Returns Array with metric statuses of given metric for all resources in this group.
- Parameters:
- {String} metricName
- Returns:
- Array with javascript objects (hashmap) with following keys:
- id {String} - resource id
- isEnabled {Boolean} - true when metric is enabled
isMetricDisabled(metricName)
Returns true only if given metric is disabled on all resources in this group
- Parameters:
- {String} metricName
isMetricEnabled(metricName)
Returns true only if given metric is enabled on all resources in this group
- Parameters:
- {String} metricName
remove()
removes this resource group
{Resrouce[]}
resources(params)
get explicit resources contained in this group
- Parameters:
- params
- - you can filter child resources same way as in resources.find() function
- Returns:
- array of explicit resources
{Resrouce[]}
resourcesImpl(params)
get implicit resources contained in this group
- Parameters:
- params
- - you can filter child resources same way as in resources.find() function
- Returns:
- array of implicit resources
runOperation(params)
Invokes operation on this group and returns result of the operation.
allAgents.invokeOperation("executeAvailabilityScan");
- Parameters:
- {Object} params
- - inputs for scheduling with fileds as follows:
- {String} name - name of operation (required)
- {boolean} haltOnFailure (optional, default is true)
- {Array} executionOrderResources defines execution order (optional)
- {String} description (optional)
- {Object} config - hashmap for operation params (Configuration) (optional)
scheduleOperation(params)
Schedules operation on this group. In contrast to invokeOperation this is
not blocking operation.
scheduleOperation({name:"executeAvailabilityScan",delay:10,repeatInterval:10,repeatCount:10,config:{changesOnly:false});
- Parameters:
- {Object} params
- - inputs for scheduling with fileds as follows:
- {String} name of operation (required)
- {Number} delay of operation in seconds (optional, 0 is default)
- {Number} repeatInterval of operation in seconds (optional, 0 is default)
- {Number} repeatCount of operations (optional, 0 is default)
- {Number} timeout of operation in seconds (optional, 0 is default)
- {boolean} haltOnFailure (optional, default is true)
- {Array} executionOrderResources defines execution order (optional)
- {String} description (optional)
- {Object} config - hashmap for operation params (Configuration) (optional)
scheduleOperationUsingCron(name, cronExpression, opParams)
schedules operation on this group using cron expression. In contrast to invokeOperation this is
not blocking operation.
allAgents.scheduleOperationUsingCron("executeAvailabilityScan","5 5 5 * * ?",{changesOnly:false});
- Parameters:
- {String} name
- of operation (required)
- {String} cronExpression
- (required)
- {Object} opParams
- - hashmap for operation params (Configuration) (optional)