diff --git a/doc/source/_static/project_schema.html b/doc/source/_static/project_schema.html index e1bfd259..cd672788 100644 --- a/doc/source/_static/project_schema.html +++ b/doc/source/_static/project_schema.html @@ -1 +1 @@ - Project

Project

Type: object

The configurations of a Project.

No Additional Properties

Type: string

The name of the project

Default: null

The base directory containing the project related files. Default is a folder with the project name inside the projects folder

Type: string
Type: null

Default: null

Folder where remote files are copied. Default a 'tmp' folder in base_dir

Type: string
Type: null

Default: null

Folder containing all the logs. Default a 'log' folder in base_dir

Type: string
Type: null

Default: null

Folder containing daemon related files. Default to a 'daemon' folder in base_dir

Type: string
Type: null

Type: enum (of string) Default: "info"

The level set for logging

Must be one of:

  • "error"
  • "warn"
  • "info"
  • "debug"

Type: object

The options for the Runner

No Additional Properties

Type: integer Default: 30

Delay between subsequent execution of the checkout from database (seconds)

Type: integer Default: 30

Delay between subsequent execution of the checking the status of jobs that are submitted to the scheduler (seconds)

Type: integer Default: 30

Delay between subsequent advancement of the job's remote state (seconds)

Type: integer Default: 600

Delay between subsequent refresh from the DB of the number of submitted and running jobs (seconds). Only use if a worker with max_jobs is present

Type: integer Default: 60

Delay between subsequent refresh from the DB of the number of submitted and running jobs (seconds). Only use if a worker with max_jobs is present

Default: 86400

Time to consider the lock on a document expired and can be overridden (seconds)

Type: integer
Type: null

Type: boolean Default: true

Whether to delete the local temporary folder after a job has completed

Type: integer Default: 3

Maximum number of attempt performed before failing an advancement of a remote state

Type: array of integer Default: [30, 300, 1200]

List of increasing delay between subsequent attempts when the advancement of a remote step fails

No Additional Items

Each item of this array must be:

Type: object

A dictionary with the worker name as keys and the worker configuration as values

Each additional property must conform to the following schema


Type: object

Worker representing the local host.

Executes command directly.

No Additional Properties

Type: const Default: "local"

The discriminator field to determine the worker type

Specific value: "local"

Type: string

Type of the scheduler. Depending on the values supported by QToolKit

Type: stringFormat: path

Absolute path of the directory of the worker where subfolders for executing the calculation will be created

Default: null

A dictionary defining the default resources requested to the scheduler. Used to fill in the QToolKit template

Default: null

String with commands that will be executed before the execution of the Job

Default: null

String with commands that will be executed after the execution of the Job

Type: integer Default: 60

Timeout for the execution of the commands in the worker (e.g. submitting a job)

Default: null

The maximum number of jobs that can be submitted to the queue.

Default: null

Options for batch execution. If define the worker will be considered a batch worker

Type: object

Worker representing a remote host reached through an SSH connection.

Uses a Fabric Connection. Check Fabric documentation for more datails on the
options defininf a Connection.

No Additional Properties

Type: const Default: "remote"

The discriminator field to determine the worker type

Specific value: "remote"

Type: string

Type of the scheduler. Depending on the values supported by QToolKit

Type: stringFormat: path

Absolute path of the directory of the worker where subfolders for executing the calculation will be created

Default: null

A dictionary defining the default resources requested to the scheduler. Used to fill in the QToolKit template

Default: null

String with commands that will be executed before the execution of the Job

Default: null

String with commands that will be executed after the execution of the Job

Type: integer Default: 60

Timeout for the execution of the commands in the worker (e.g. submitting a job)

Default: null

The maximum number of jobs that can be submitted to the queue.

Default: null

Options for batch execution. If define the worker will be considered a batch worker

Type: string

The host to which to connect

Default: null

The filename, or list of filenames, of optional private key(s) and/or certs to try for authentication

Default: null

A shell command string to use as a proxy or gateway

Default: null

Other keyword arguments passed to paramiko.client.SSHClient.connect

Default: null

Whether to send environment variables 'inline' as prefixes in front of command strings

Default: 60

Keepalive value in seconds passed to paramiko's transport

Default: "bash"

The shell command used to execute the command remotely. If None the command is executed directly

Type: boolean Default: true

Whether to use a login shell when executing the command

Type: object

Dictionary describing a maggma Store used for the queue data. Can contain the monty serialized dictionary or a dictionary with a 'type' specifying the Store subclass. Should be subclass of a MongoStore, as it requires to perform MongoDB actions.

Type: object

A dictionary with the ExecutionConfig name as keys and the ExecutionConfig configuration as values

Each additional property must conform to the following schema

Type: object

Configuration to be set before and after the execution of a Job.

No Additional Properties

Default: null

list of modules to be loaded

Type: array of string
No Additional Items

Each item of this array must be:

Default: null

dictionary with variable to be exported

Default: null

Other commands to be executed before the execution of a job

Default: null

Commands to be executed after the execution of a job

Type: object

The JobStore used for the input. Can contain the monty serialized dictionary or the Store int the Jobflow format

Default: null

A dictionary with metadata associated to the project

Type: object
Type: null
+ Project

Project

Type: object

The configurations of a Project.

No Additional Properties

Name

Type: string

The name of the project

Base Dir

Default: null

The base directory containing the project related files. Default is a folder with the project name inside the projects folder

Type: string
Type: null

Tmp Dir

Default: null

Folder where remote files are copied. Default a 'tmp' folder in base_dir

Type: string
Type: null

Log Dir

Default: null

Folder containing all the logs. Default a 'log' folder in base_dir

Type: string
Type: null

Daemon Dir

Default: null

Folder containing daemon related files. Default to a 'daemon' folder in base_dir

Type: string
Type: null

Type: enum (of string) Default: "info"

The level set for logging

Must be one of:

  • "error"
  • "warn"
  • "info"
  • "debug"

Type: object

The options for the Runner

No Additional Properties

Delay Checkout

Type: integer Default: 30

Delay between subsequent execution of the checkout from database (seconds)

Delay Check Run Status

Type: integer Default: 30

Delay between subsequent execution of the checking the status of jobs that are submitted to the scheduler (seconds)

Delay Advance Status

Type: integer Default: 30

Delay between subsequent advancement of the job's remote state (seconds)

Delay Refresh Limited

Type: integer Default: 600

Delay between subsequent refresh from the DB of the number of submitted and running jobs (seconds). Only used if a worker with max_jobs is present

Delay Update Batch

Type: integer Default: 60

Delay between subsequent refresh from the DB of the number of submitted and running jobs (seconds). Only used if a batch worker is present

Lock Timeout

Default: 86400

Time to consider the lock on a document expired and can be overridden (seconds)

Type: integer
Type: null

Delete Tmp Folder

Type: boolean Default: true

Whether to delete the local temporary folder after a job has completed

Max Step Attempts

Type: integer Default: 3

Maximum number of attempt performed before failing an advancement of a remote state

Delta Retry

Type: array of integer Default: [30, 300, 1200]

List of increasing delay between subsequent attempts when the advancement of a remote step fails

No Additional Items

Each item of this array must be:

Workers

Type: object

A dictionary with the worker name as keys and the worker configuration as values

Each additional property must conform to the following schema


Type: object

Worker representing the local host.

Executes command directly.

No Additional Properties

Type

Type: const Default: "local"

The discriminator field to determine the worker type

Specific value: "local"

Scheduler Type

Type: string

Type of the scheduler. Depending on the values supported by QToolKit

Work Dir

Type: stringFormat: path

Absolute path of the directory of the worker where subfolders for executing the calculation will be created

Resources

Default: null

A dictionary defining the default resources requested to the scheduler. Used to fill in the QToolKit template

Pre Run

Default: null

String with commands that will be executed before the execution of the Job

Post Run

Default: null

String with commands that will be executed after the execution of the Job

Timeout Execute

Type: integer Default: 60

Timeout for the execution of the commands in the worker (e.g. submitting a job)

Max Jobs

Default: null

The maximum number of jobs that can be submitted to the queue.

Default: null

Options for batch execution. If define the worker will be considered a batch worker

Type: object

Configuration for execution of batch jobs.

Allows to execute multiple Jobs in a single process executed on the worker (e.g. SLURM job).

Same definition as BatchConfig
Type: object

Worker representing a remote host reached through an SSH connection.

Uses a Fabric Connection. Check Fabric documentation for more details on the
options defining a Connection.

No Additional Properties

Type

Type: const Default: "remote"

The discriminator field to determine the worker type

Specific value: "remote"

Scheduler Type

Type: string

Type of the scheduler. Depending on the values supported by QToolKit

Work Dir

Type: stringFormat: path

Absolute path of the directory of the worker where subfolders for executing the calculation will be created

Resources

Default: null

A dictionary defining the default resources requested to the scheduler. Used to fill in the QToolKit template

Pre Run

Default: null

String with commands that will be executed before the execution of the Job

Post Run

Default: null

String with commands that will be executed after the execution of the Job

Timeout Execute

Type: integer Default: 60

Timeout for the execution of the commands in the worker (e.g. submitting a job)

Max Jobs

Default: null

The maximum number of jobs that can be submitted to the queue.

Default: null

Options for batch execution. If define the worker will be considered a batch worker

Type: object

Configuration for execution of batch jobs.

Allows to execute multiple Jobs in a single process executed on the worker (e.g. SLURM job).

Same definition as BatchConfig

Host

Type: string

The host to which to connect

Key Filename

Default: null

The filename, or list of filenames, of optional private key(s) and/or certs to try for authentication

Passphrase

Default: null

Passphrase used for decrypting private keys

Gateway

Default: null

A shell command string to use as a proxy or gateway

Connect Kwargs

Default: null

Other keyword arguments passed to paramiko.client.SSHClient.connect

Inline Ssh Env

Default: null

Whether to send environment variables 'inline' as prefixes in front of command strings

Keepalive

Default: 60

Keepalive value in seconds passed to paramiko's transport

Shell Cmd

Default: "bash"

The shell command used to execute the command remotely. If None the command is executed directly

Login Shell

Type: boolean Default: true

Whether to use a login shell when executing the command

Interactive Login

Type: boolean Default: false

Whether the authentication to the host should be interactive

Type: object

The configuration of the Store used to store the states of the Jobs and the Flows

No Additional Properties

Store

Type: object

Dictionary describing a maggma Store used for the queue data. Can contain the monty serialized dictionary or a dictionary with a 'type' specifying the Store subclass. Should be subclass of a MongoStore, as it requires to perform MongoDB actions. The collection is used to store the jobs

Flows Collection

Type: string Default: "flows"

The name of the collection containing information about the flows. Taken from the same database as the one defined in the store

Auxiliary Collection

Type: string Default: "jf_auxiliary"

The name of the collection containing auxiliary information. Taken from the same database as the one defined in the store

Db Id Prefix

Default: null

a string defining the prefix added to the integer ID associated to each Job in the database

Type: string
Type: null

Exec Config

Type: object

A dictionary with the ExecutionConfig name as keys and the ExecutionConfig configuration as values

Each additional property must conform to the following schema

Type: object

Configuration to be set before and after the execution of a Job.

No Additional Properties

Modules

Default: null

list of modules to be loaded

Type: array of string
No Additional Items

Each item of this array must be:

Export

Default: null

dictionary with variable to be exported

Pre Run

Default: null

Other commands to be executed before the execution of a job

Post Run

Default: null

Commands to be executed after the execution of a job

Jobstore

Type: object

The JobStore used for the input. Can contain the monty serialized dictionary or the Store int the Jobflow format

Metadata

Default: null

A dictionary with metadata associated to the project

Type: object
Type: null
diff --git a/src/jobflow_remote/config/base.py b/src/jobflow_remote/config/base.py index 71d0435f..4d319c76 100644 --- a/src/jobflow_remote/config/base.py +++ b/src/jobflow_remote/config/base.py @@ -111,6 +111,13 @@ def to_logging(self) -> int: class BatchConfig(BaseModel): + """ + Configuration for execution of batch jobs. + + Allows to execute multiple Jobs in a single process executed on the + worker (e.g. SLURM job). + """ + jobs_handle_dir: Path = Field( description="Absolute path to a folder that will be used to store information to share with the jobs being executed" ) @@ -524,7 +531,7 @@ class Project(BaseModel): ) queue: QueueConfig = Field( description="The configuration of the Store used to store the states of" - "the Jobs and the Flows", + " the Jobs and the Flows", ) exec_config: dict[str, ExecutionConfig] = Field( default_factory=dict,