Application Manager API

class radical.entk.AppManager(config_path=None, reattempts=None, resubmit_failed=None, autoterminate=None, write_workflow=None, rts=None, rts_config=None, name=None, base_path=None, **kwargs)[source]

An application manager takes the responsibility of setting up the communication infrastructure, instantiates the ResourceManager, TaskManager, WFProcessor objects and all their threads and processes. This is the Master object running in the main process and is designed to recover from errors from all other objects, threads and processes.

Arguments
config_path

Url to config path to be read for AppManager

reattempts

number of attempts to re-invoke any failed EnTK components

resubmit_failed

resubmit failed tasks (True/False)

autoterminate

terminate resource reservation upon execution of all tasks of first workflow (True/False)

write_workflow

write workflow and mapping to rts entities to a file (post-termination)

rts

Specify RTS to use. Current options: ‘mock’, ‘radical.pilot’ (default if unspecified)

rts_config

Configuration for the RTS, accepts {‘sandbox_cleanup’: True/False,’db_cleanup’: True/False} when RTS is RP

name

Name of the Application. It should be unique between executions. (default is randomly assigned)

base_path

base path of logger and profiler with a session id, None (default) will use a current working directory

property name

Name for the application manager. Allows the user to setup the name of the application manager, as well as its session ID. This name should be unique between different EnTK executions, otherwise it will produce an error.

Getter

Returns the name of the application manager

Setter

Assigns the name of the application manager

Type

String

property outputs
Return list of filenames that are to be staged out after

execution

Setter

Assign a list of names of files that need to be staged from the remote machine

Type

getter

property resource_desc

The resource description is a dictionary that holds information about the resource(s) that will be used to execute the workflow.

The following keys are mandatory in all resource descriptions:
‘resource’ : Label of the platform with resources.
‘walltime’ : Amount of time the workflow is expected to run.
‘cpus’ : Number of CPU cores/threads.
Optional keys include:
‘project’ : The project that will be charged.
‘gpus’ : Number of GPUs to be used by the workflow.
‘access_schema’ : The key of an access mechanism to use.
‘queue’ : The name of the batch queue.
‘job_name’ : The specific name of a batch job.
Getter

Returns the resource description

Setter

Assigns a resource description

run()[source]

Purpose: Run the application manager. Once the workflow and resource manager have been assigned. Invoking this method will start the setting up the communication infrastructure, submitting a resource request and then submission of all the tasks.

property services

Returns the list of tasks used to start “global” services :setter: Assigns a list of service tasks, which are launched before any stage starts and run during the whole workflow execution

Type

getter

property shared_data
Return list of filenames that are shared between multiple tasks

of the application

Setter

Assign a list of names of files that need to be staged to the remote machine

Type

getter

property sid

Get the session ID of the current EnTK execution

Getter

Returns the session ID of the EnTK execution

Type

String

property workflow

Return the last workflow assigned for execution :setter: Assign a new workflow to be executed

Type

getter

property workflows

Return a list of workflows assigned for execution

Type

getter