Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/monitoring/constants.js')
-rw-r--r--app/assets/javascripts/monitoring/constants.js30
1 files changed, 30 insertions, 0 deletions
diff --git a/app/assets/javascripts/monitoring/constants.js b/app/assets/javascripts/monitoring/constants.js
index 50330046c99..afeb3318eb9 100644
--- a/app/assets/javascripts/monitoring/constants.js
+++ b/app/assets/javascripts/monitoring/constants.js
@@ -1,5 +1,12 @@
export const PROMETHEUS_TIMEOUT = 120000; // TWO_MINUTES
+export const dashboardEmptyStates = {
+ GETTING_STARTED: 'gettingStarted',
+ LOADING: 'loading',
+ NO_DATA: 'noData',
+ UNABLE_TO_CONNECT: 'unableToConnect',
+};
+
/**
* States and error states in Prometheus Queries (PromQL) for metrics
*/
@@ -208,6 +215,14 @@ export const annotationsSymbolIcon = 'path://m5 229 5 8h-10z';
*/
export const DEFAULT_DASHBOARD_PATH = 'config/prometheus/common_metrics.yml';
+/**
+ * GitLab provide metrics dashboards that are available to a user once
+ * the Prometheus managed app has been installed, without any extra setup
+ * required. These "out of the box" dashboards are defined under the
+ * `config/prometheus` path.
+ */
+export const OUT_OF_THE_BOX_DASHBOARDS_PATH_PREFIX = 'config/prometheus/';
+
export const OPERATORS = {
greaterThan: '>',
equalTo: '==',
@@ -230,6 +245,7 @@ export const OPERATORS = {
export const VARIABLE_TYPES = {
custom: 'custom',
text: 'text',
+ metric_label_values: 'metric_label_values',
};
/**
@@ -242,3 +258,17 @@ export const VARIABLE_TYPES = {
* before passing the data to the backend.
*/
export const VARIABLE_PREFIX = 'var-';
+
+/**
+ * All of the actions inside each panel dropdown can be accessed
+ * via keyboard shortcuts than can be activated via mouse hovers
+ * and or focus via tabs.
+ */
+
+export const keyboardShortcutKeys = {
+ EXPAND: 'e',
+ VISIT_LOGS: 'l',
+ SHOW_ALERT: 'a',
+ DOWNLOAD_CSV: 'd',
+ CHART_COPY: 'c',
+};