The Heron Explorer is a CLI tool that you can use to gain insight into a Heron installation, including:
The Heron Explorer vs. Heron CLI
There are two important differences between the Heron Explorer and Heron CLI. Unlike Heron CLI, the Heron Explorer (a) requires the Heron Tracker and (b) performs read-only, observation-oriented commands (rather than commands for actions like submitting, activating, and killing topologies).
In order to use the Heron Explorer, the Heron Tracker will need to be running. If you've installed the Tracker, you can start it up using just one command:
$ heron-tracker
The Heron Explorer is installed automatically if you follow the Heron tools installation tutorial in the Quick Start Guide. x
The commands available for the Heron Explorer are listed in the table below.
Command | Action | Arguments |
---|---|---|
clusters | Lists all currently available Heron clusters | None |
components | Displays information about a topology‘s spout and bolt components, including each component’s inputs and outputs (if any) and parallelism | [cluster]/[role]/[env] [topology-name] [options] |
metrics | Displays metrics for a topology | [cluster]/[role]/[env] [topology-name] [options] |
containers | Displays all of the containers in which a topology is running | [cluster]/[role]/[env] [topology-name] [options] |
topologies | Displays all topologies currently running in the specified cluster, cluster/role, or cluster/role/env | [cluster]/[role]/[env] [topology-name] [options] |
In addition to these commands, you can get help output by running heron-explorer help
and the current version of Heron Explorer by running heron-explorer version
.
To use a topology about which you'd like to gather information using Heron Explorer, you need to supply one of the following:
Here are three examples corresponding to the options above:
$ heron-explorer topologies local $ heron-explorer topologies us-west/finance $ heron-explorer topologies asia-1/iot/devel
The clusters
command lists all of the clusters running in the Heron installation. It takes no arguments.
Here's an example command and output:
$ heron-explorer clusters Available clusters: local
The components
command lists information about all of a topology's components (spouts and bolts), including:
spout
or bolt
)Here's an example command and output:
$ heron-explorer components \ us-east/analytics/staging \ ClickCounterTopology type name parallelism input output ------ ------------- ------------- --------------------- ------------- spout click-ingest 2 - click-counter bolt click-counter 2 - click-ingest persist-to-db
The metrics
command lists a wide variety of metrics about each component in a topology:
Here's an example command:
$ heron-explorer metrics \ us-east/analytics/staging \ ClickCounterTopology
And here's some example output:
'click-ingest' metrics: container id jvm-uptime-secs jvm-process-cpu-load jvm-memory-used-mb emit-count ack-count fail-count -------------------------- ----------------- ---------------------- -------------------- ------------ ----------- ------------ container_1_click-ingest_1 1012 0.510003 83 2.81582e+07 0 0 container_2_click-ingest_2 1012 0.467 71 2.34582e+07 0 0 'click-counter' metrics: container id jvm-uptime-secs jvm-process-cpu-load jvm-memory-used-mb emit-count ack-count fail-count ---------------------------- ----------------- ---------------------- -------------------- ------------ ----------- ------------ container_1_click-counter_1 1012 0.5201 83 2.81432e+07 0 0 container_2_click-counter_2 1012 0.481 71 2.14896e+07 0 0
The containers
command lists all of the containers in which a topology is running, and provides the following information about each container:
Here's an example command:
$ heron-explorer containers \ us-east/analytics/staging \ ClickCounterTopology
And here's some example output:
container host port pid #bolt #spout #instance ----------- ----------------- ------ ----- ------- -------- ----------- 1 us-west.1.acme.com 62915 47893 1 1 1 2 us-west.2.acme.com 62147 14390 1 1 1
The topologies
command lists all topologies for one of the following:
Here's an example command and output:
$ heron-explorer \ us-east/analytics/staging Topologies running in cluster 'us-east/analytics/staging' role env topology --------- ------- ------------------------- analytics staging ClickCounterTopology