The Status action

Sure!

The Status action

This action updates project execution status with a custom message (which can be calculated using an expression). It serves the same purpose but works differently in EasyMorph Desktop, Launcher and EasyMorph Server.

To demonstrate how it works, here is a sample project:

status.morph (1.6 KB)

Desktop

When we Reload & Run (Ctrl + F5) the project this is the result:

As you can notice, the status message in the run progress dialog changes when a Status action is calcu. When no Status action present in project or its sub-projects, then the default status message never changes.

Desktop (command line mode)

Status messages are printed when a project is run in the command line mode:
status-command-line

Launcher

EasyMorph Launcher also displays status messages in real time:

status-launcher

Besides that status messages are logged in the task log:

Server

Now let’s see what happens if we run the same project on the Server:

On Server, the action does two things:

  1. Updates the task status in the web console.
  2. Writes status messages in the task log (see below)

Purpose

The Status action can be helpful on various occasions:

  • Indicate milestones for long running projects
  • Since status messages from called/iterated subprojects are also displayed, it allows creating status messages that would indicate progress of iterations (e.g. “10 files processed out of 123”, or “Processing: 12-May-2017”) which can help estimate total run time
  • Log particular messages or custom warnings into task logs (e.g. number of dates processed, data quality metrics, etc.). Such messages can later be parsed and necessary actions taken.
  • Estimate execution time of an action or a chain of actions in a project. In this case the Status action can be used to record start/end times.
  • Log values of calculated parameters (input parameters are logged automatically in the task log).
  • Create audit records with file names or database tables modified.
1 Like