|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.rhq.core.pc.agent.AgentService
org.rhq.core.pc.operation.OperationManager
public class OperationManager
Manages the scheduling and invocation of operations for all resources across all plugins.
This is an agent service; its interface is made remotely accessible if this is deployed within the agent.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.rhq.core.pc.agent.AgentService |
|---|
AgentService.LifecycleState |
| Constructor Summary | |
|---|---|
OperationManager()
|
|
| Method Summary | |
|---|---|
CancelResults |
cancelOperation(String jobId)
|
protected OperationFacet |
getOperationFacet(int resourceId,
long facetMethodTimeout)
Given a resource, this obtains that resource's OperationFacet interface. |
protected org.rhq.core.domain.resource.ResourceType |
getResourceType(int resourceId)
Given a resource ID, this obtains that resource's type. |
void |
initialize()
Initializes the container service which will effectively tell the service to start doing its work. |
void |
invokeOperation(String jobId,
int resourceId,
String operationName,
org.rhq.core.domain.configuration.Configuration parameterConfig)
|
protected void |
invokeOperation(String jobId,
int resourceId,
String operationName,
org.rhq.core.domain.configuration.Configuration parameterConfig,
OperationServerService operationServerService)
Not tying this call to a particular OperationServerService implementation allows other internal classes
to call this method and receive the results, rather than having them sent to the server. |
void |
setConfiguration(PluginContainerConfiguration configuration)
Informs the container service how it should be configured by providing the full plugin container configuration. |
void |
shutdown()
This will shutdown the operation thread pool and attempt to cancel operations already in progress. |
| Methods inherited from class org.rhq.core.pc.agent.AgentService |
|---|
addLifecycleListener, getClientInterface, notifyLifecycleListenersOfNewState, remoteInputStream, remoteOutputStream, removeLifecycleListener, setAgentServiceStreamRemoter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public OperationManager()
| Method Detail |
|---|
public void initialize()
ContainerServicenull
configuration will be set via a call to ContainerService.setConfiguration(PluginContainerConfiguration).
initialize in interface ContainerServicepublic void shutdown()
shutdown in interface ContainerServiceContainerService.shutdown()public void setConfiguration(PluginContainerConfiguration configuration)
ContainerServicenull configuration object so implementations of
this interface should never have to worry about a null configuration parameter value.
setConfiguration in interface ContainerService
public void invokeOperation(@NotNull
String jobId,
int resourceId,
@NotNull
String operationName,
@Nullable
org.rhq.core.domain.configuration.Configuration parameterConfig)
throws PluginContainerException
invokeOperation in interface OperationAgentServicePluginContainerException
protected void invokeOperation(String jobId,
int resourceId,
String operationName,
org.rhq.core.domain.configuration.Configuration parameterConfig,
OperationServerService operationServerService)
throws PluginContainerException
OperationServerService implementation allows other internal classes
to call this method and receive the results, rather than having them sent to the server.
PluginContainerExceptionpublic CancelResults cancelOperation(String jobId)
cancelOperation in interface OperationAgentService
protected OperationFacet getOperationFacet(int resourceId,
long facetMethodTimeout)
throws PluginContainerException
resourceId - identifies the resource that is to have the operation invoked on it
PluginContainerException - on error
protected org.rhq.core.domain.resource.ResourceType getResourceType(int resourceId)
throws PluginContainerException
resourceId - identifies the resource whose type is to be returned
PluginContainerException - if cannot determine the resource's type
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||