../_images/menu-macros.png

View Macros

The 4P platform not only stores raw and processed datasets, but it also exposes the list of available macros and their detailed configuration. The next section also describes how to create a custom macro.

Hint

A macro is a pre-configured chain of computation steps that can be applied to specific input data types.

List of macros

To access the list of available macros, click the Macros item in the main menu.

../_images/view-macro-list.png

Macros are listed in a table ordered by their date of last time usage. The table displays the following information for each macro:

  • Status: this is the status of the current macro. A macro can be Valid, Invalid, Published or Archived.

  • Name: that’s the general name of the macro

  • Vector: the compatible vector

  • Input data: the type of data that can be used as an input of the current macro

  • Output data: the type of data that this macro can generate

  • Version: an indicator showing whether the macro is using the latest version of each of its modules

  • Visibility: indicates whether the macro’s visibility is extended to “non PHIS users”

Note

Unlike the datasets, published macros are common to every installation and organization. However, only extended macros are visible to users without PHIS account.

Details of a macro

To view the detailed information of a macro, just click on it in the list. This opens the details page of the macro which gives the following additional information:

  • Description: the detailed description of the macro and its features

  • Author: the name and mail of the user who created the macro

  • Technical guide: a document describing in details how the macro works

  • Macro used N times: a table listing the processes that already used the current macro and a link toward the processed dataset

../_images/view-macro-details.png

Status of a macro

As explained before, a macro has a status among one of the following:

../_images/view-macro-label-published.png

Published: a published macro is visible by every user of the 4P platform and can be used in processes. It is locked in a sense that its configuration and information cannot be modified to ensure data traceability.

../_images/view-macro-label-valid.png

Valid: this means that the macro configuration is valid and ready to be published. If not published, only the author has access to it and can modify it or use it for processes.

../_images/view-macro-label-invalid.png

Invalid: this means that the macro is not completely defined either because some parameters are missing or because input or output data types are not compatible. An invalid macro cannot be used in a process.

../_images/view-macro-label-archived.png

Archived: this means that the macro was published but is no longer maintained and editable. It stills exists to ensure the traceability of processes that used it, but is no longer usable for new processes.

Note

Notice that only users with super administrator privileges can browse through archived macros.

Actions on a macro

If the macro is not published nor archived, it is possible to modify its general information. To do so, click on the button Edit next to the name of the macro.

../_images/view-macro-btn-edit.png

Depending on its status, a few additional actions can be performed on a macro. These actions are listed in the actions toolbar:

../_images/view-macro-toolbar.png
  • Duplicate: Since a published macro is not editable, the button Duplicate can be used to create a copy of the current macro and then adjust a few parameters or change general information.

  • Process dataset: Launch a process using the current macro. A dataset would have to be selected.

  • Delete: Only valid and invalid macros can be deleted.

Important

Macros that are not published can only produce draft data. To produce final and valid data a macro must be published. Publication of a macro can be asked to one of the super-administrators.

Publish a macro

Only users with super-administrator privileges can publish a macro. Once published, it is visible and usable by all PHIS users of 4P and can not be deleted nor modified. Super-administrators have access to the following advanced actions:

  • Publish: Publish an element by making it final and visible by all users of the platform

  • Archive: Archive an element by hiding it from all users of the platform

  • Unpublish: Unpublish an element by making it back to a draft state

  • Unarchive: Unarchive an element by making it back to a published state

Hint

Modules, Data types and Macros offer the same publication control by super-administrators.

Extend a macro

../_images/macro-visibility-icons.png

Macros are by default never visible to users with no PHIS account. To make them visible, users with super-administrator privileges can extend a macro after it has been decided by the 4P decision-makers. The open eye / shut eye icons identified a visible / non visibile macro respectively.

Workflow of a macro

A macro also defines a workflow or chain of computation steps called modules. Open the Workflow tab to visualize (or edit) the workflow configuration.

../_images/view-macro-workflow.png

The left-hand side of this page displays the workflow itself. It contains:

  • One or several input data types on which the macro will execute a process. These input data contain input information that will be used as input parameters for each module of the chain.

  • One or several modules, each one executing one specific step of computation on the input dataset.

  • One or several output data types that will be generated by the modules in the chain.

The right-hand side of this page shows the specific configuration of the selected module on the left. The module name and description are shown, as well as the input and output data types. Is also displayed the list of the module inputs, the source that will provide each input parameter during runtime and the value, if known.

../_images/view-macro-workflow-inputs.png ../_images/view-macro-workflow-btn-parallel.png

The icon parallel process indicates, if activated, that the module will be parallely executed over each element of a list. If deactivated, the first element of the input list will be used as a value for this input parameter.

Note

Workflows are never editable by users with no PHIS account, but are still accessible in a read-only mode.

Update modules to newer versions

Macros are composed of one or several computation modules. Sometimes, the author of a module makes changes in the module behavior and the previous one becomes obsolete. When it is the case, the macro Version indicator shows that an upgrade is needed.

../_images/view-macro-details-update.png

For traceability reason, it is not possible to upgrade that current macro (unless it is in draft mode). However it is possible to duplicate the current macro and use the latest version of the module.