Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
Documentation for tagging metrics via task manifest
Browse files Browse the repository at this point in the history
  • Loading branch information
marcin-krolik committed Jun 29, 2016
1 parent 320ec8d commit e1459db
Showing 1 changed file with 41 additions and 0 deletions.
41 changes: 41 additions & 0 deletions docs/TASKS.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,11 @@ For more on tasks, visit [`SNAPCTL.md`](SNAPCTL.md).
/intel/mock:
user: "root"
password: "secret"
tags:
/intel/mock:
experiment: "experiment 11"
/intel/mock/bar:
os: "linux"
process:
-
plugin_name: "passthru"
Expand Down Expand Up @@ -85,6 +90,11 @@ Process and Publish nodes in the workflow can also target remote snap nodes via
/intel/mock:
user: "root"
password: "secret"
tags:
/intel/mock:
experiment: "experiment 11"
/intel/mock/bar:
os: "linux"
process:
-
plugin_name: "passthru"
Expand Down Expand Up @@ -143,6 +153,24 @@ config:

Applying the config at `/intel/perf` means that all leaves of `/intel/perf` (`/intel/perf/foo`, `/intel/perf/bar`, and `/intel/perf/baz` in this case) will receive the config.

The tag section describes additional meta data for metrics. Similary to config, tags can also be described at a branch, and all leaves of that branch will receive the given tag(s). For example, say a task is going to collect `/intel/perf/foo`, `/intel/perf/bar`, and `/intel/perf/baz`, all metrics should be tagged with experiment number, additonally one metric `/intel/perf/bar` should be tagged with OS name. That tags could be described like so:

```yaml
---
metrics:
/intel/perf/foo: {}
/intel/perf/bar: {}
/intel/perf/baz: {}
tags:
/intel/perf:
experiment: "experiment 11"
/intel/perf/bar:
os: "linux"
```

Applying the tags at `/intel/perf` means that all leaves of `/intel/perf` (`/intel/perf/foo`, `/intel/perf/bar`, and `/intel/perf/baz` in this case) will receive the tag `experiment: experiment 11`.
Applying the tags at `/intel/perf/bar` means that only `/intel/perf/bar` will receive the tag `os: linux`.

A collect node can also contain any number of process or publish nodes. These nodes describe what to do next.

#### process
Expand Down Expand Up @@ -179,6 +207,11 @@ Below is a complete example task.
/intel/mock:
user: "root"
password: "secret"
tags:
/intel/perf:
experiment: "experiment 11"
/intel/perf/bar:
os: "linux"
process:
-
plugin_name: "passthru"
Expand Down Expand Up @@ -212,6 +245,14 @@ Below is a complete example task.
"password": "secret"
}
},
"tags": {
"/intel/mock": {
"experiment": "experiment 11"
},
"/intel/mock/bar": {
"os": "linux"
}
},
"process": [
{
"plugin_name": "passthru",
Expand Down

0 comments on commit e1459db

Please sign in to comment.