replace

Output of --help=replace

The following help text is generated by ecflow_client --help=replace

replace
-------

Replaces a node in the server, with the given path
Can also be used to add nodes in the server

Argument(s):

    node: path
        # The path to the node to be replaced.
        # This path must exist in both the argument `definition` file
        # and on the definition currently loaded on the server.

    definition: path
        # The path to the client definition file,
        # which provides the definition of the new node.

    parent: (optional) [ parent | false ] (default = parent)
        # Allows automatically creating parent families or suite as needed,
        # when argument `node` does not exist in the server

    force: (optional) (default = false)
        # Force the replacement, even if any node is queued/executing.
        # Using this option might causes zombies to be created

Replace can fail if:
- The node path(arg1) does not exist in the provided client definition(arg2)
- The client definition(arg2) must be free of errors
- If the third argument is not provided, then node path(arg1) must exist in the server
- Nodes to be replaced are in active/submitted state, in which case arg4(force) can be used

Replace will preserve the suspended status, if this is not required please re-queue first
After replace is done, we check trigger expressions. These are reported to standard output.
It is up to the user to correct invalid trigger expressions, otherwise the tasks will *not* run.
Please note, you can use --check to check trigger expression and limits in the server.
For more information use --help check.

Usage:

    --replace=/suite/f1/t1 /tmp/client.def parent      # Add/replace node tree /suite/f1/t1
    --replace=/suite/f1/t1 /tmp/client.def false force # replace t1 even if its active or submitted

The client considers, for both user and task commands, the following environment variables:

  ECF_HOST <string> [mandatory*]
    The main server hostname; default value is 'localhost'
  ECF_PORT <int> [mandatory*]
    The main server port; default value is '3141'
  ECF_SSL <any> [optional*]
    Enable secure communication between client and server.
  ECF_HOSTFILE <string> [optional]
    File that lists alternate hosts to try, if connection to main host fails
  ECF_HOSTFILE_POLICY <string> [optional]
    The policy ('task' or 'all') to define which commands consider using alternate hosts.

The options marked with (*) must be specified in order for the client to communicate
with the server, either by setting the environment variables or by specifying the
command line options.

See also

Protocol reference for ReplaceNodeCmd — the request/reply payloads exchanged with the server and the C++ command class that implements this command.