Warning
This document is for an in-development version of Galaxy. You can alternatively view this page in the latest release if it exists or view the top of the latest release's documentation.
galaxy.job_metrics package
This module defines the job metrics collection framework for Galaxy jobs.
The framework consists of two parts - the JobMetrics class and
individual JobInstrumenter plugins.
A JobMetrics object reads any number of plugins from a configuration
source such as an XML file, a YAML file, or a dictionary.
Each JobInstrumenter plugin object describes how to inject a bits
of shell code into a job scripts (before and after tool commands run) and then
collect the output of these from a job directory.
- class galaxy.job_metrics.JobInstrumenter(plugin_classes, plugins_source, **kwargs)[source]
Bases:
JobInstrumenterI
- class galaxy.job_metrics.Safety(value)[source]
Bases:
EnumAn enumeration.
- UNSAFE = 2
- POTENTIALLY_SENSITVE = 4
- SAFE = 6
Subpackages
- galaxy.job_metrics.instrumenters package
ProvidesJobMetricsContextInstrumentPlugin- Submodules
- galaxy.job_metrics.instrumenters.cgroup module
- galaxy.job_metrics.instrumenters.core module
- galaxy.job_metrics.instrumenters.cpuinfo module
- galaxy.job_metrics.instrumenters.env module
- galaxy.job_metrics.instrumenters.hostname module
- galaxy.job_metrics.instrumenters.meminfo module
- galaxy.job_metrics.instrumenters.uname module
Submodules
galaxy.job_metrics.formatting module
Utilities related to formatting job metrics for human consumption.
- class galaxy.job_metrics.formatting.FormattedMetric(title, value)[source]
Bases:
NamedTuple
- class galaxy.job_metrics.formatting.JobMetricFormatter[source]
Bases:
objectFormat job metric key-value pairs for human consumption in Web UI.
- format(key: str, value: Any) FormattedMetric | None[source]
Render a metric for display, or None to record it without displaying it.
Returning None is how a plugin says “collected, but this particular value is not worth showing” – a metric that is uninteresting at some values and interesting at others. Safety levels are the other way to keep a metric out of the UI, but they decide per metric name rather than per value.