Oracle Fusion Middleware
Java API Reference for Oracle WebLogic Server
12c (12.1.3)

Part Number E41849-02

weblogic.management.runtime
Interface TaskRuntimeMBean

All Superinterfaces:
DynamicMBean, MBeanRegistration, NotificationBroadcaster, RuntimeMBean, WebLogicMBean
All Known Subinterfaces:
ClassRedefinitionTaskRuntimeMBean, CoherenceServerLifeCycleTaskRuntimeMBean, DataRetirementTaskRuntimeMBean, DeploymentTaskRuntimeMBean, JDBCDataSourceTaskRuntimeMBean, ServerLifeCycleTaskRuntimeMBean, SystemComponentLifeCycleTaskRuntimeMBean, WLDFDataRetirementTaskRuntimeMBean, WLDFImageCreationTaskRuntimeMBean

public interface TaskRuntimeMBean
extends RuntimeMBean

Exposes monitoring information about an ongoing and potentially long-running administrative process. This should be taken to mean, at minimum, any OA&M operation involving I/O. Examples include starting and stopping servers, deploying and undeploying applications, or migrating services.

An MBean operation of this sort should fork a separate thread to perform the actual work and immediately return an instance of TaskRuntimeMBean to the caller. The caller can then use this to track the task's progress as desired. Users can also query for all instances of TaskRuntimeMBean to get a summary of both currently-running and recently-completed tasks.

Instance of TaskRuntimeMBean continue to exist in the MBeanServer after the completion of the work they describe. They will eventually either be explicitly deregistered by the user, or removed by a scavenger process which periodically purges TaskRuntimeMBeans that have been completed for some time.

Deprecation of MBeanHome and Type-Safe Interfaces

This is a type-safe interface for a WebLogic Server MBean, which you can import into your client classes and access through weblogic.management.MBeanHome. As of 9.0, the MBeanHome interface and all type-safe interfaces for WebLogic Server MBeans are deprecated. Instead, client classes that interact with WebLogic Server MBeans should use standard JMX design patterns in which clients use the javax.management.MBeanServerConnection interface to discover MBeans, attributes, and attribute types at runtime.


Method Summary
 void cancel()
          Attempts to cancel this task.
 long getBeginTime()
          The time at which this task was started.
 String getDescription()
          A description of this task.
 long getEndTime()
          The time at which this task was completed.
 Exception getError()
          Returns an exception describing the error, if any, that occurred while performing this task.
 TaskRuntimeMBean getParentTask()
          The task of which this task is a part.
 String getStatus()
          The status of this task.
 TaskRuntimeMBean[] getSubTasks()
          An array of TaskRuntimeMBeans that describes a set of parallel tasks which are components of this task.
 boolean isRunning()
          Indicates whether the task is still running.
 boolean isSystemTask()
          Indicates whether this task was initiated by the server versus a user.
 
Methods inherited from interface weblogic.management.WebLogicMBean
getMBeanInfo, getName, getObjectName, getParent, getType, isCachingDisabled, isRegistered, setParent
 
Methods inherited from interface javax.management.DynamicMBean
getAttribute, getAttributes, invoke, setAttribute, setAttributes
 
Methods inherited from interface javax.management.MBeanRegistration
postDeregister, postRegister, preDeregister, preRegister
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, getNotificationInfo, removeNotificationListener
 

Method Detail

getDescription

String getDescription()

A description of this task.

Returns:
The description value

getStatus

String getStatus()

The status of this task.

Returns:
The status value

isRunning

boolean isRunning()

Indicates whether the task is still running.

Returns:
The running value

getBeginTime

long getBeginTime()

The time at which this task was started.

Returns:
The beginTime value

getEndTime

long getEndTime()

The time at which this task was completed.

A value of -1 indicates that the task is currently running.

Returns:
The endTime value

getSubTasks

TaskRuntimeMBean[] getSubTasks()

An array of TaskRuntimeMBeans that describes a set of parallel tasks which are components of this task.

A value of null indicates that this task has no subtasks.

A simple example of a task with subtasks would be one which monitors a user's request to start a cluster; that task should return a set of subtasks indicating the individual server-startup processes which compose the overall cluster-startup task.

Returns:
The subTasks value

getParentTask

TaskRuntimeMBean getParentTask()

The task of which this task is a part.

A value of null indicates that this task is not a subtask.

Returns:
The parentTask value
See Also:
TaskRuntimeMBean.getSubTasks()

cancel

void cancel()
            throws Exception

Attempts to cancel this task.

An exception is thrown to indicate failure to cancel the task. Not all tasks can be cancelled.

Throws:
Exception

getError

Exception getError()

Returns an exception describing the error, if any, that occurred while performing this task.

Returns:
The error value

isSystemTask

boolean isSystemTask()

Indicates whether this task was initiated by the server versus a user.

Returns:
The systemTask value

Copyright 1996, 2014, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.

Oracle Fusion Middleware
Java API Reference for Oracle WebLogic Server
12c (12.1.3)

Part Number E41849-02