Hop Run

Hop Run is a command line tool to run your workflows and pipelines.

Hop Run can be launched through the script with the corresponding name in your Hop installation directory, either hop-run.sh on Mac and Linux or hop-run.bat on Windows.

Except for the laucher script, all options are platform agnostic; there is no difference in the way hop-run works on any operating system.

Hop Run Options

You can display Hop Run’s options by running the command without any options.

If you’re on Windows (tough luck), run hop-run.bat, on Mac and Linux, run hop-run.sh.

You’ll see the option listed in a similar output to the one below:

Output of help
Usage: <main class> [-ho] [-e=<environmentOption>] [-f=<filename>]
                    [-j=<projectOption>] [-l=<level>]
                    [-r=<runConfigurationName>] [-p=<parameters>[,
                    <parameters>...]]... [-s=<systemProperties>[,
                    <systemProperties>...]]...
  -e, --environment=<environmentOption>
                          The name of the lifecycle environment to use
  -f, --file=<filename>   The filename of the workflow or pipeline to run
  -h, --help              Displays this help message and quits.
  -j, --project=<projectOption>
                          The name of the project to use
  -l, --level=<level>     The debug level, one of NOTHING, ERROR, MINIMAL, BASIC, DETAILED, DEBUG, ROWLEVEL
  -m, --metadata-export=<metadataExportFile>
                          A file containing exported metadata in JSON format
  -o, --printoptions      Print the used options
  -p, --parameters=<parameters>[,<parameters>...]
                          A comma separated list of PARAMETER=VALUE pairs
  -r, --runconfig=<runConfigurationName>
                          The name of the Run Configuration to use
  -s, --system-properties=<systemProperties>[,<systemProperties>...]
                          A comma separated list of KEY=VALUE pairs

The available options are listed in more detail in the table below:

Short Extended Description

-e

--environment

The name of the environment to use.

Check the documentation on environments for more details.

-f

--file

The filename of the workflow or pipeline to run

-h

--help

Displays this help message and quits.

-j

--project

The name of the project to use when running a pipeline or workflow

-l

--level

The debug level, one of NOTHING, ERROR, MINIMAL, BASIC, DETAILED, DEBUG, ROWLEVEL

-m

--metadata-export

A file containing exported metadata in JSON format. See also the metadata export option in Hop Conf

-o

--printoptions

Print the used options

-p

--parameters

A comma separated list of PARAMETER=VALUE pairs

-r

--runconfig

The name of the Run Configuration to use. Check the documentation on run configurations for more details.

-s

--system-properties

A comma separated list of KEY=VALUE pairs

Examples

./hop-run.sh -j=transforms -r=local -f=/path/to/worklow/file.hwf

Parameter Examples

This is a list of examples on how the parameters on this command are parsed

Normal Usage

--parameters=key1=value1,key2=value2

Result:

Key value

key1

value1

key2

value2

Spaces in value Usage

--parameters=key1="This value contains spaces",key2=value2

Result:

Key value

key1

This value contains spaces

key2

value2

Commas in value Usage

--parameters=key1=\"value1,value2\"

Result:

Key value

key1

value1,value2

Forcing quotes in value

--parameters=key1="\"\"String with spaces\"\""

Result:

Key value

key1

"String with spaces"