# parsl.dataflow.dflow.DataFlowKernelLoader

class parsl.dataflow.dflow.DataFlowKernelLoader

  Manage which DataFlowKernel is active.

  This is a singleton class containing only class methods. You should not need to instantiate this class.

  __init__()

  Methods

  `__init__`() |
  `clear`() | Clear the active DataFlowKernel so that a new one can be loaded.
  `dfk`() | Return the currently-loaded DataFlowKernel.
  `load`([config]) | Load a DataFlowKernel.
  `wait_for_current_tasks`() | Waits for all tasks in the task list to be completed, by waiting for their AppFuture to be completed.

  classmethod clear() → None

    Clear the active DataFlowKernel so that a new one can be loaded.

  classmethod dfk() → DataFlowKernel

    Return the currently-loaded DataFlowKernel.

  classmethod load(config: Config | None = None) → DataFlowKernel

    Load a DataFlowKernel.

    Parameters:

      config (-) – Configuration to load. This config will be passed to a new DataFlowKernel instantiation which will be set as the active DataFlowKernel.

    Returns:

      The loaded DataFlowKernel object.

    Return type:

      - DataFlowKernel

  classmethod wait_for_current_tasks() → None

    Waits for all tasks in the task list to be completed, by waiting for their AppFuture to be completed. This method will not necessarily wait for any tasks added after cleanup has started such as data stageout.