workflow Fields

Both make-workflow and workflow accept the same fields, which we describe below. Of all these fields only name and processes are required.

name

The readable name of the workflow as a string. This is used for display purposes. When the workflow constructor is used, the name field need not be provided explicitly.

version

A version string to distinguish different releases of the workflow.

synopsis

A short summary of what this workflow is about.

description

A description of what the workflow is supposed to accomplish.

processes

This field contains a list of processes that should be scheduled when the workflow is executed. A plain list of processes specifies processes that may run in parallel. A list of process lists is used to specify process dependencies. This is best done with the graph macro:

The following workflow definition lets the process combine run after generate-A and generate-B, which will both run in parallel. The process compress will run after combine, and thus at the very end.

workflow frobnicate
  processes
    graph
      combine -> generate-A generate-B
      compress -> combine

This can be expressed just as well with lists of process lists, but it looks a little dense. Here is the same thing in Scheme without the graph macro:

(workflow frobnicate
  (processes
    (list (list combine generate-A generate-B)
          (compress combine))))

If the processes all declare inputs and outputs, the GWL can connect the processes and ensure that only independent processes are run simultaneously. Use the auto-connect procedure on your processes:

workflow do-stuff
  processes
    auto-connect
      . this
      . that
      . something-else
before

This field holds a Scheme procedure that will be executed before the workflow processes are scheduled. This can be useful for printing introduction banners or logos.

workflow fancy-hello
  before
    lambda _
      display "\
 _          _ _         .
| |        | | |        .
| |__   ___| | | ___    .
| '_ \\ / _ \\ | |/ _ \\   .
| | | |  __/ | | (_) |  .
|_| |_|\\___|_|_|\\___/   .
"
      newline
      display "Now that I've got your attention, let's compute!"
      newline
      newline
  processes
    list hello
after

This field holds a Scheme procedure that will be executed after all workflow processes have been executed. This can be useful for printing further instructions or hints as to where the user may find important output files.

workflow fancy-bye
  after
    lambda _
      newline
      display "The main report file is called `report2021_final_really_approved.html'."
      newline
      newline
  processes
    list generate-report