Documentation
¶
Index ¶
- Constants
- func Load(jm *JM) error
- func NativeGetConfig() error
- func NativeGetError(j *job.Job, sysCfg *sys.Config) string
- func NativeGetOutput(j *job.Job, sysCfg *sys.Config) string
- func NativeSetConfig() error
- func NativeSubmit(j *job.Job, env *buildenv.Info, sysCfg *sys.Config) (syexec.SyCmd, error)
- func PrunGetConfig() error
- func PrunGetError(j *job.Job, sysCfg *sys.Config) string
- func PrunGetOutput(j *job.Job, sysCfg *sys.Config) string
- func PrunSetConfig() error
- func PrunSubmit(j *job.Job, env *buildenv.Info, sysCfg *sys.Config) (syexec.SyCmd, error)
- func SlurmGetConfig() error
- func SlurmGetError(j *job.Job, sysCfg *sys.Config) string
- func SlurmGetOutput(j *job.Job, sysCfg *sys.Config) string
- func SlurmLoad(jm *JM, sysCfg *sys.Config) error
- func SlurmSetConfig() error
- func SlurmSubmit(j *job.Job, hostBuildEnv *buildenv.Info, sysCfg *sys.Config) (syexec.SyCmd, error)
- func TempFile(j *job.Job, env *buildenv.Info, sysCfg *sys.Config) error
- type GetConfigFn
- type JM
- type LoadFn
- type Loader
- type Native
- type Prun
- type SetConfigFn
- type SubmitFn
Constants ¶
const ( // NativeID is the value set to JM.ID when mpirun shall be used to submit a job NativeID = "native" // SlurmID is the value set to JM.ID when Slurm shall be used to submit a job SlurmID = "slurm" // PrunID is the value set to JM.ID when prun shall be used to submit a job PrunID = "prun" )
Variables ¶
This section is empty.
Functions ¶
func NativeGetConfig ¶
func NativeGetConfig() error
NativeGetConfig gets the configuration of the native job manager
func NativeGetError ¶
NativeGetError retrieves the error messages from an application after the completion of a job
func NativeGetOutput ¶
NativeGetOutput retrieves the application's output after the completion of a job
func NativeSetConfig ¶
func NativeSetConfig() error
NativeSetConfig sets the configuration of the native job manager
func NativeSubmit ¶
NativeSubmit is the function to call to submit a job through the native job manager
func PrunGetConfig ¶
func PrunGetConfig() error
PrunGetConfig gets the configuration of the native job manager
func PrunGetError ¶
PrunGetError retrieves the error messages from an application after the completion of a job
func PrunGetOutput ¶
PrunGetOutput retrieves the application's output after the completion of a job
func PrunSetConfig ¶
func PrunSetConfig() error
PrunSetConfig sets the configuration of the native job manager
func PrunSubmit ¶
PrunSubmit is the function to call to submit a job through the native job manager
func SlurmGetConfig ¶
func SlurmGetConfig() error
SlurmGetConfig is the Slurm function to get the configuration of the job manager
func SlurmGetError ¶
SlurmGetError reads the content of the Slurm error file that is associated to a job
func SlurmGetOutput ¶
SlurmGetOutput reads the content of the Slurm output file that is associated to a job
func SlurmSetConfig ¶
func SlurmSetConfig() error
SlurmSetConfig is the Slurm function to set the configuration of the job manager
func SlurmSubmit ¶
SlurmSubmit prepares the batch script necessary to start a given job.
Note that a script does not need any specific environment to be submitted
Types ¶
type GetConfigFn ¶
type GetConfigFn func() error
GetConfigFn is a "function pointer" that lets us get the configuration of a given job manager
type JM ¶
type JM struct { // ID identifies which job manager has been detected on the system ID string // Set is the function that sets the configuration of the current job manager Set SetConfigFn // Get is the function that gets the configuration of the current job manager Get GetConfigFn Load LoadFn // Submit is the function to submit a job through the current job manager Submit SubmitFn }
JM is the structure representing a specific JM
func Detect ¶
func Detect() JM
Detect figures out which job manager must be used on the system and return a structure that gather all the data necessary to interact with it
func NativeDetect ¶
NativeDetect is the function used by our job management framework to figure out if mpirun should be used directly. The native component is the default job manager. If application, the function returns a structure with all the "function pointers" to correctly use the native job manager.
func PrunDetect ¶
PrunDetect is the function used by our job management framework to figure out if mpirun should be used directly. The native component is the default job manager. If application, the function returns a structure with all the "function pointers" to correctly use the native job manager.
func SlurmDetect ¶
LoadSlurm is the function used by our job management framework to figure out if Slurm can be used and if so return a JM structure with all the "function pointers" to interact with Slurm through our generic API.
type Loader ¶
type Loader interface {
Load() bool
}
Loader checks whether a giv job manager is applicable or not
type Native ¶
type Native struct { }
Native is the structure representing the native job manager (i.e., directly use mpirun)
type Prun ¶
type Prun struct { }
Prun is the structure representing the native job manager (i.e., directly use mpirun)
type SetConfigFn ¶
type SetConfigFn func() error
SetConfigFn is a "function pointer" that lets us store the configuration of a given job manager