|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.isi.pegasus.planner.provenance.NetloggerCallback
public class NetloggerCallback
Implements callback interface to calculate space usage.
| Field Summary | |
|---|---|
protected int |
counter
The counter to track the number of invocation records. |
static String |
MACHINE_INFO_PREFIX
The prefix for machine information keys |
protected List<Map<String,String>> |
mInvocationList
List of Invocation maps. |
protected Map<String,String> |
mInvocationMap
The Map of key value pairs that are to be logged via Netlogger. |
protected LogManager |
mLogger
The handle to the logger. |
protected String |
mMainJob
The main job whose record is being parsed. |
protected String |
mSite
The logical site where the job was run. |
| Fields inherited from interface edu.isi.pegasus.planner.visualize.Callback |
|---|
VERSION |
| Constructor Summary | |
|---|---|
NetloggerCallback()
The default constructor. |
|
| Method Summary | |
|---|---|
void |
cbInputFile(String filename,
StatInfo info)
Callback function for when stat information for an input file is encountered. |
void |
cbInvocationEnd()
Callback signalling that an invocation record has been parsed. |
void |
cbInvocationStart(String job,
String resource)
Callback for the starting of an invocation record. |
void |
cbMachine(Machine machine)
Callback to pass the machine information on which the job is executed. |
void |
cbMetadata(Map metadata)
Callback for the metadata retrieved from the kickstart record. |
void |
cbOutputFile(String filename,
StatInfo info)
Callback function for when stat information for an output file is encountered. |
void |
cbStdERR(List jobs,
String data)
Callback function for the data section of stderr. |
void |
cbStdIN(List jobs,
String data)
Callback function for the data section of stdin. |
void |
cbStdOut(List jobs,
String data)
Callback function for the data section of stdout. |
void |
done()
Callback signalling that we are done with the parsing of the files. |
Object |
getConstructedObject()
Returns a List of Map objects where each map captures information in one invocation record. |
private String |
getListValueFromMetadata(Map m,
String key)
Returns the first value from the List values for a key |
void |
initialize(String directory,
boolean useStatInfo)
Initializes the callback. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String MACHINE_INFO_PREFIX
protected String mSite
protected String mMainJob
protected LogManager mLogger
protected Map<String,String> mInvocationMap
protected List<Map<String,String>> mInvocationList
protected int counter
| Constructor Detail |
|---|
public NetloggerCallback()
| Method Detail |
|---|
public void initialize(String directory,
boolean useStatInfo)
initialize in interface Callbackdirectory - the directory where all the files reside.useStatInfo - boolean indicating whether to use stat info or not.
public void cbInvocationStart(String job,
String resource)
cbInvocationStart in interface Callbackjob - the job/file being parsed.resource - the site id where the job was executed.
public void cbStdIN(List jobs,
String data)
Callback
cbStdIN in interface Callbackjobs - all the jobs specified in the kickstart record.data - the data contents as String.
public void cbStdOut(List jobs,
String data)
Callback
cbStdOut in interface Callbackjobs - all the jobs specified in the kickstart record.data - the data contents as String.
public void cbStdERR(List jobs,
String data)
Callback
cbStdERR in interface Callbackjobs - all the jobs specified in the kickstart record.data - the data contents as String.
public void cbInputFile(String filename,
StatInfo info)
cbInputFile in interface Callbackfilename - the name of the file.info - the StatInfo about the file.
public void cbOutputFile(String filename,
StatInfo info)
cbOutputFile in interface Callbackfilename - the name of the file.info - the StatInfo about the file.public void cbInvocationEnd()
cbInvocationEnd in interface Callbackpublic Object getConstructedObject()
getConstructedObject in interface Callbackpublic void done()
done in interface Callbackpublic void cbMetadata(Map metadata)
cbMetadata in interface Callbackmetadata - public void cbMachine(Machine machine)
cbMachine in interface Callbackmachine -
private String getListValueFromMetadata(Map m,
String key)
m - key -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||