Package com.sun.grid.jsv.examples
Class SimpleJsv
- java.lang.Object
-
- com.sun.grid.jsv.examples.SimpleJsv
-
- All Implemented Interfaces:
Jsv
public class SimpleJsv extends java.lang.Object implements Jsv
This is a simple JSV that:- Rejects binary jobs
- Rejects parallel jobs that don't request a multiple of 16 processes
- Temporarily reject jobs that request h_vmem
- Removes request for h_data
- Increments the job context variable "a"
- Removes the job context variable "b"
- Removes the job context variable "c"
- Adds a job context variable d=5
-
-
Constructor Summary
Constructors Constructor Description SimpleJsv()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(java.lang.String[] args)
Run this JSV.void
onStart(JsvManager jsv)
This method is called to start the job verification process.void
onVerify(JsvManager jsv)
This method is called to trigger the job verification step.
-
-
-
Method Detail
-
main
public static void main(java.lang.String[] args)
Run this JSV.- Parameters:
args
- the command line arguments
-
onStart
public void onStart(JsvManager jsv)
Description copied from interface:Jsv
This method is called to start the job verification process. In general, the most common use for this method is to call the JsvManager.requestEnvironment() method.- Specified by:
onStart
in interfaceJsv
- See Also:
JsvManager.requestEnvironment(boolean)
-
onVerify
public void onVerify(JsvManager jsv)
Description copied from interface:Jsv
This method is called to trigger the job verification step. This method is used by the Jsv implementation to accept, modify, or reject the job. Information about the job being verified is available from the JobDescription instance retrieved from the JsvManager.getJobDescription() method. Changes made to the JobDescription instance will be propagated to the JSV framework. Before this method returns, it should call one of the result methods on the JsvManager instance, accept(), modify(), reject(), rejectWait(), or setResult(). If none is called, the job will be implicitly accepted or modified as appropriate.- Specified by:
onVerify
in interfaceJsv
- See Also:
JsvManager.getJobDescription()
,JsvManager.accept(java.lang.String)
,JsvManager.modify(java.lang.String)
,JsvManager.reject(java.lang.String)
,JsvManager.rejectWait(java.lang.String)
,JsvManager.setResult(com.sun.grid.jsv.JsvManager.Result, java.lang.String)
-
-