Sub-system interface

This is the interface any new or old sub-system must obey so it can be used by the pmake program. Each of the functions is documented. For a simple implementation where you can learn the details, see the code of the sub-system.


This function is a constructor, it should return a new object and do all the initialization stuff it needs to begin accepting jobs.


This function receives a job structure and should launch the job on the system. This method should not block. The debug variable is set to true if the user wants you to print or save debug information.


This function should return a boolean, stating if the process passed as a parameter $job is still running. The logger could be used to print debug messages.


This function should be called to force the interruption of a running process.


This function should simply return the unique ID of this process.


If for whatever reason the job specified could not be run (eg: there is no resources available), you should return false on the function.


Clean any mess you may created. (eg. temporary files).


Tries to get any info from the dead job. This function should *try* to populate the $job->{realtime} and $job->{exitstatus}. It is not required however. It should simply *try* to get this info.