org.jppf.server.job.management
Class DriverJobManagement

java.lang.Object
  extended by javax.management.NotificationBroadcasterSupport
      extended by org.jppf.server.job.management.DriverJobManagement
All Implemented Interfaces:
NotificationBroadcaster, NotificationEmitter, DriverJobManagementMBean

public class DriverJobManagement
extends NotificationBroadcasterSupport
implements DriverJobManagementMBean

Implementation of the job management bean.

Author:
Laurent Cohen

Field Summary
 
Fields inherited from interface org.jppf.server.job.management.DriverJobManagementMBean
MBEAN_NAME
 
Constructor Summary
DriverJobManagement()
          Initialize this MBean.
 
Method Summary
 void cancelJob(String jobUuid)
          Cancel the job with the specified id.
 String[] getAllJobIds()
          Get the set of ids for all the jobs currently queued or executing.
 JobInformation getJobInformation(String jobUuid)
          Get an object describing the job with the specified uuid.
 NodeJobInformation[] getNodeInformation(String jobUuid)
          Get a list of objects describing the nodes to which the whole or part of a job was dispatched.
 void resumeJob(String jobUuid)
          Resume the job with the specified id.
 void sendNotification(Notification notification)
          
 void suspendJob(String jobUuid, Boolean requeue)
          Suspend the job with the specified id.
 void updateMaxNodes(String jobUuid, Integer maxNodes)
          Update the maximum number of nodes a node can run on.
 
Methods inherited from class javax.management.NotificationBroadcasterSupport
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.management.NotificationEmitter
removeNotificationListener
 
Methods inherited from interface javax.management.NotificationBroadcaster
addNotificationListener, getNotificationInfo, removeNotificationListener
 

Constructor Detail

DriverJobManagement

public DriverJobManagement()
Initialize this MBean.

Method Detail

cancelJob

public void cancelJob(String jobUuid)
               throws Exception
Cancel the job with the specified id.

Specified by:
cancelJob in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job to cancel.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.cancelJob(java.lang.String)

suspendJob

public void suspendJob(String jobUuid,
                       Boolean requeue)
                throws Exception
Suspend the job with the specified id.

Specified by:
suspendJob in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job to suspend.
requeue - true if the sub-jobs running on each node should be canceled and requeued, false if they should be left to execute until completion.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.suspendJob(java.lang.String,java.lang.Boolean)

resumeJob

public void resumeJob(String jobUuid)
               throws Exception
Resume the job with the specified id.

Specified by:
resumeJob in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job to resume.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.resumeJob(java.lang.String)

updateMaxNodes

public void updateMaxNodes(String jobUuid,
                           Integer maxNodes)
                    throws Exception
Update the maximum number of nodes a node can run on.

Specified by:
updateMaxNodes in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job to update.
maxNodes - the new maximum number of nodes for the job.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.updateMaxNodes(java.lang.String, java.lang.Integer)

getAllJobIds

public String[] getAllJobIds()
                      throws Exception
Get the set of ids for all the jobs currently queued or executing.

Specified by:
getAllJobIds in interface DriverJobManagementMBean
Returns:
a set of ids as strings.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.getAllJobIds()

getJobInformation

public JobInformation getJobInformation(String jobUuid)
                                 throws Exception
Get an object describing the job with the specified uuid.

Specified by:
getJobInformation in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job to get information about.
Returns:
an instance of JobInformation.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.getJobInformation(java.lang.String)

getNodeInformation

public NodeJobInformation[] getNodeInformation(String jobUuid)
                                        throws Exception
Get a list of objects describing the nodes to which the whole or part of a job was dispatched.

Specified by:
getNodeInformation in interface DriverJobManagementMBean
Parameters:
jobUuid - the id of the job for which to find node information.
Returns:
a list of NodeManagementInfo instances.
Throws:
Exception - if any error occurs.
See Also:
DriverJobManagementMBean.getNodeInformation(java.lang.String)

sendNotification

public void sendNotification(Notification notification)

Overrides:
sendNotification in class NotificationBroadcasterSupport


Copyright © 2005-2010 JPPF Team.