org.apache.hama.bsp
Class QueueManager

java.lang.Object
  extended by org.apache.hama.bsp.QueueManager

public class QueueManager
extends java.lang.Object

A BSPJob Queue Manager.


Constructor Summary
QueueManager(org.apache.hadoop.conf.Configuration conf)
           
 
Method Summary
 void addJob(java.lang.String name, org.apache.hama.bsp.JobInProgress job)
          Add a job to the specified queue.
 void createFCFSQueue(java.lang.String name)
          Create a FCFS queue with the name provided.
 Queue<org.apache.hama.bsp.JobInProgress> findQueue(java.lang.String name)
          Find Queue according to the name specified.
 void initJob(org.apache.hama.bsp.JobInProgress job)
          Initialize a job.
 void moveJob(java.lang.String from, java.lang.String to, org.apache.hama.bsp.JobInProgress job)
          Move a job from a queue to another.
 void removeJob(java.lang.String name, org.apache.hama.bsp.JobInProgress job)
          Remove a job from the head of a designated queue.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QueueManager

public QueueManager(org.apache.hadoop.conf.Configuration conf)
Method Detail

initJob

public void initJob(org.apache.hama.bsp.JobInProgress job)
Initialize a job.

Parameters:
job - required initialzied.

addJob

public void addJob(java.lang.String name,
                   org.apache.hama.bsp.JobInProgress job)
Add a job to the specified queue.

Parameters:
name - of the queue.
job - to be added.

removeJob

public void removeJob(java.lang.String name,
                      org.apache.hama.bsp.JobInProgress job)
Remove a job from the head of a designated queue.

Parameters:
name - from which a job is removed.
job - to be removed from the queue.

moveJob

public void moveJob(java.lang.String from,
                    java.lang.String to,
                    org.apache.hama.bsp.JobInProgress job)
Move a job from a queue to another.

Parameters:
from - a queue a job is to be removed.
to - a queue a job is to be added.

createFCFSQueue

public void createFCFSQueue(java.lang.String name)
Create a FCFS queue with the name provided.

Parameters:
name - of the queue.

findQueue

public Queue<org.apache.hama.bsp.JobInProgress> findQueue(java.lang.String name)
Find Queue according to the name specified.

Parameters:
name - of the queue.
Returns:
queue of JobInProgress


Copyright © 2008-2011 The Apache Software Foundation. All Rights Reserved.