From 8f4f5f1d68b8d6f366f98dc17bd16fc513285c00 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Marc=20H=C3=B6rsken?=
Date: Sat, 7 May 2022 21:52:42 +0200
Subject: [PATCH 01/51] app/vmctl: add flag to handle Prometheus remote_write
to InfluxDB (#2545)
Make it possible to migrate timeseries while restoring the
original timeseries name previously written from Prometheus
to InfluxDB v1 via remote_write.
Fixes: https://github.com/VictoriaMetrics/vmctl/issues/8
---
app/vmctl/flags.go | 6 ++++++
app/vmctl/influx.go | 8 +++++++-
app/vmctl/main.go | 3 ++-
3 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/app/vmctl/flags.go b/app/vmctl/flags.go
index 0f7b891523..348d983b82 100644
--- a/app/vmctl/flags.go
+++ b/app/vmctl/flags.go
@@ -202,6 +202,7 @@ const (
influxFilterTimeEnd = "influx-filter-time-end"
influxMeasurementFieldSeparator = "influx-measurement-field-separator"
influxSkipDatabaseLabel = "influx-skip-database-label"
+ influxPrometheusMode = "influx-prometheus-mode"
)
var (
@@ -264,6 +265,11 @@ var (
Usage: "Wether to skip adding the label 'db' to timeseries.",
Value: false,
},
+ &cli.BoolFlag{
+ Name: influxPrometheusMode,
+ Usage: "Wether to restore the original timeseries name previously written from Prometheus to InfluxDB v1 via remote_write.",
+ Value: false,
+ },
}
)
diff --git a/app/vmctl/influx.go b/app/vmctl/influx.go
index b05b2a48ab..ee2462c5ee 100644
--- a/app/vmctl/influx.go
+++ b/app/vmctl/influx.go
@@ -17,9 +17,10 @@ type influxProcessor struct {
cc int
separator string
skipDbLabel bool
+ promMode bool
}
-func newInfluxProcessor(ic *influx.Client, im *vm.Importer, cc int, separator string, skipDbLabel bool) *influxProcessor {
+func newInfluxProcessor(ic *influx.Client, im *vm.Importer, cc int, separator string, skipDbLabel bool, promMode bool) *influxProcessor {
if cc < 1 {
cc = 1
}
@@ -29,6 +30,7 @@ func newInfluxProcessor(ic *influx.Client, im *vm.Importer, cc int, separator st
cc: cc,
separator: separator,
skipDbLabel: skipDbLabel,
+ promMode: promMode,
}
}
@@ -101,6 +103,8 @@ func (ip *influxProcessor) run(silent, verbose bool) error {
}
const dbLabel = "db"
+const nameLabel = "__name__"
+const valueField = "value"
func (ip *influxProcessor) do(s *influx.Series) error {
cr, err := ip.ic.FetchDataPoints(s)
@@ -122,6 +126,8 @@ func (ip *influxProcessor) do(s *influx.Series) error {
for i, lp := range s.LabelPairs {
if lp.Name == dbLabel {
containsDBLabel = true
+ } else if lp.Name == nameLabel && s.Field == valueField && ip.promMode {
+ name = lp.Value
}
labels[i] = vm.LabelPair{
Name: lp.Name,
diff --git a/app/vmctl/main.go b/app/vmctl/main.go
index 26d7ad3b35..3c37fdd24d 100644
--- a/app/vmctl/main.go
+++ b/app/vmctl/main.go
@@ -105,7 +105,8 @@ func main() {
importer,
c.Int(influxConcurrency),
c.String(influxMeasurementFieldSeparator),
- c.Bool(influxSkipDatabaseLabel))
+ c.Bool(influxSkipDatabaseLabel),
+ c.Bool(influxPrometheusMode))
return processor.run(c.Bool(globalSilent), c.Bool(globalVerbose))
},
},
From 3f78a609ac3bbee06a223f0859f54526ba94f29f Mon Sep 17 00:00:00 2001
From: Artem Navoiev
Date: Sun, 8 May 2022 15:18:39 +0300
Subject: [PATCH 02/51] docs: add flags list to vmbackupmanager (#2554)
docs: add flags list to vmbackupmanager docs
Signed-off-by: hagen1778
Co-authored-by: tenmozes
---
app/vmbackupmanager/README.md | 119 ++++++++++++++++++++++++++++++++++
docs/vmbackupmanager.md | 119 ++++++++++++++++++++++++++++++++++
2 files changed, 238 insertions(+)
diff --git a/app/vmbackupmanager/README.md b/app/vmbackupmanager/README.md
index 94f169a053..b1f5893c17 100644
--- a/app/vmbackupmanager/README.md
+++ b/app/vmbackupmanager/README.md
@@ -139,3 +139,122 @@ info app/vmbackupmanager/retention.go:106 daily backups to delete [daily/2
The result on the GCS bucket. We see only 3 daily backups:

+
+
+## Configuration
+
+### Flags
+
+Pass `-help` to `vmbackupmanager` in order to see the full list of supported
+command-line flags with their descriptions.
+
+The shortlist of configuration flags is the following:
+
+```
+vmbackupmanager performs regular backups according to the provided configs.
+
+ -concurrency int
+ The number of concurrent workers. Higher concurrency may reduce backup duration (default 10)
+ -configFilePath string
+ Path to file with S3 configs. Configs are loaded from default location if not set.
+ See https://docs.aws.amazon.com/general/latest/gr/aws-security-credentials.html
+ -configProfile string
+ Profile name for S3 configs. If no set, the value of the environment variable will be loaded (AWS_PROFILE or AWS_DEFAULT_PROFILE), or if both not set, DefaultSharedConfigProfile is used
+ -credsFilePath string
+ Path to file with GCS or S3 credentials. Credentials are loaded from default locations if not set.
+ See https://cloud.google.com/iam/docs/creating-managing-service-account-keys and https://docs.aws.amazon.com/general/latest/gr/aws-security-credentials.html
+ -customS3Endpoint string
+ Custom S3 endpoint for use with S3-compatible storages (e.g. MinIO). S3 is used if not set
+ -disableDaily
+ Disable daily run. Default false
+ -disableHourly
+ Disable hourly run. Default false
+ -disableMonthly
+ Disable monthly run. Default false
+ -disableWeekly
+ Disable weekly run. Default false
+ -dst string
+ The root folder of Victoria Metrics backups. Example: gs://bucket/path/to/backup/dir, s3://bucket/path/to/backup/dir or fs:///path/to/local/backup/dir
+ -enableTCP6
+ Whether to enable IPv6 for listening and dialing. By default only IPv4 TCP and UDP is used
+ -envflag.enable
+ Whether to enable reading flags from environment variables additionally to command line. Command line flag values have priority over values from environment vars. Flags are read only from command line if this flag isn't set. See https://docs.victoriametrics.com/#environment-variables for more details
+ -envflag.prefix string
+ Prefix for environment variables if -envflag.enable is set
+ -eula
+ By specifying this flag, you confirm that you have an enterprise license and accept the EULA https://victoriametrics.com/assets/VM_EULA.pdf
+ -fs.disableMmap
+ Whether to use pread() instead of mmap() for reading data files. By default mmap() is used for 64-bit arches and pread() is used for 32-bit arches, since they cannot read data files bigger than 2^32 bytes in memory. mmap() is usually faster for reading small data chunks than pread()
+ -http.connTimeout duration
+ Incoming http connections are closed after the configured timeout. This may help to spread the incoming load among a cluster of services behind a load balancer. Please note that the real timeout may be bigger by up to 10% as a protection against the thundering herd problem (default 2m0s)
+ -http.disableResponseCompression
+ Disable compression of HTTP responses to save CPU resources. By default compression is enabled to save network bandwidth
+ -http.idleConnTimeout duration
+ Timeout for incoming idle http connections (default 1m0s)
+ -http.maxGracefulShutdownDuration duration
+ The maximum duration for a graceful shutdown of the HTTP server. A highly loaded server may require increased value for a graceful shutdown (default 7s)
+ -http.pathPrefix string
+ An optional prefix to add to all the paths handled by http server. For example, if '-http.pathPrefix=/foo/bar' is set, then all the http requests will be handled on '/foo/bar/*' paths. This may be useful for proxied requests. See https://www.robustperception.io/using-external-urls-and-proxies-with-prometheus
+ -http.shutdownDelay duration
+ Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers
+ -httpAuth.password string
+ Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty
+ -httpAuth.username string
+ Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password
+ -httpListenAddr string
+ Address to listen for http connections (default ":8300")
+ -keepLastDaily int
+ Keep last N daily backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastHourly int
+ Keep last N hourly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastMonthly int
+ Keep last N monthly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastWeekly int
+ Keep last N weekly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -loggerDisableTimestamps
+ Whether to disable writing timestamps in logs
+ -loggerErrorsPerSecondLimit int
+ Per-second limit on the number of ERROR messages. If more than the given number of errors are emitted per second, the remaining errors are suppressed. Zero values disable the rate limit
+ -loggerFormat string
+ Format for logs. Possible values: default, json (default "default")
+ -loggerLevel string
+ Minimum level of errors to log. Possible values: INFO, WARN, ERROR, FATAL, PANIC (default "INFO")
+ -loggerOutput string
+ Output for the logs. Supported values: stderr, stdout (default "stderr")
+ -loggerTimezone string
+ Timezone to use for timestamps in logs. Timezone must be a valid IANA Time Zone. For example: America/New_York, Europe/Berlin, Etc/GMT+3 or Local (default "UTC")
+ -loggerWarnsPerSecondLimit int
+ Per-second limit on the number of WARN messages. If more than the given number of warns are emitted per second, then the remaining warns are suppressed. Zero values disable the rate limit
+ -maxBytesPerSecond int
+ The maximum upload speed. There is no limit if it is set to 0
+ -memory.allowedBytes size
+ Allowed size of system memory VictoriaMetrics caches may occupy. This option overrides -memory.allowedPercent if set to a non-zero value. Too low a value may increase the cache miss rate usually resulting in higher CPU and disk IO usage. Too high a value may evict too much data from OS page cache resulting in higher disk IO usage
+ Supports the following optional suffixes for size values: KB, MB, GB, KiB, MiB, GiB (default 0)
+ -memory.allowedPercent float
+ Allowed percent of system memory VictoriaMetrics caches may occupy. See also -memory.allowedBytes. Too low a value may increase cache miss rate usually resulting in higher CPU and disk IO usage. Too high a value may evict too much data from OS page cache which will result in higher disk IO usage (default 60)
+ -metricsAuthKey string
+ Auth key for /metrics. It must be passed via authKey query arg. It overrides httpAuth.* settings
+ -pprofAuthKey string
+ Auth key for /debug/pprof. It must be passed via authKey query arg. It overrides httpAuth.* settings
+ -runOnStart
+ Upload backups immediately after start of the service. Otherwise the backup starts on new hour
+ -s3ForcePathStyle
+ Prefixing endpoint with bucket name when set false, true by default. (default true)
+ -snapshot.createURL string
+ VictoriaMetrics create snapshot url. When this is given a snapshot will automatically be created during backup.Example: http://victoriametrics:8428/snapshot/create
+ -snapshot.deleteURL string
+ VictoriaMetrics delete snapshot url. Optional. Will be generated from snapshot.createURL if not provided. All created snaphosts will be automatically deleted.Example: http://victoriametrics:8428/snapshot/delete
+ -storageDataPath string
+ Path to VictoriaMetrics data. Must match -storageDataPath from VictoriaMetrics or vmstorage (default "victoria-metrics-data")
+ -tls
+ Whether to enable TLS for incoming HTTP requests at -httpListenAddr (aka https). -tlsCertFile and -tlsKeyFile must be set if -tls is set
+ -tlsCertFile string
+ Path to file with TLS certificate if -tls is set. Prefer ECDSA certs instead of RSA certs as RSA certs are slower. The provided certificate file is automatically re-read every second, so it can be dynamically updated
+ -tlsCipherSuites array
+ Optional list of TLS cipher suites for incoming requests over HTTPS if -tls is set. See the list of supported cipher suites at https://pkg.go.dev/crypto/tls#pkg-constants
+ Supports an array of values separated by comma or specified via multiple flags.
+ -tlsKeyFile string
+ Path to file with TLS key if -tls is set. The provided key file is automatically re-read every second, so it can be dynamically updated
+ -version
+ Show VictoriaMetrics version
+```
\ No newline at end of file
diff --git a/docs/vmbackupmanager.md b/docs/vmbackupmanager.md
index 68692a85b8..7ae6cdb7fa 100644
--- a/docs/vmbackupmanager.md
+++ b/docs/vmbackupmanager.md
@@ -143,3 +143,122 @@ info app/vmbackupmanager/retention.go:106 daily backups to delete [daily/2
The result on the GCS bucket. We see only 3 daily backups:

+
+
+## Configuration
+
+### Flags
+
+Pass `-help` to `vmbackupmanager` in order to see the full list of supported
+command-line flags with their descriptions.
+
+The shortlist of configuration flags is the following:
+
+```
+vmbackupmanager performs regular backups according to the provided configs.
+
+ -concurrency int
+ The number of concurrent workers. Higher concurrency may reduce backup duration (default 10)
+ -configFilePath string
+ Path to file with S3 configs. Configs are loaded from default location if not set.
+ See https://docs.aws.amazon.com/general/latest/gr/aws-security-credentials.html
+ -configProfile string
+ Profile name for S3 configs. If no set, the value of the environment variable will be loaded (AWS_PROFILE or AWS_DEFAULT_PROFILE), or if both not set, DefaultSharedConfigProfile is used
+ -credsFilePath string
+ Path to file with GCS or S3 credentials. Credentials are loaded from default locations if not set.
+ See https://cloud.google.com/iam/docs/creating-managing-service-account-keys and https://docs.aws.amazon.com/general/latest/gr/aws-security-credentials.html
+ -customS3Endpoint string
+ Custom S3 endpoint for use with S3-compatible storages (e.g. MinIO). S3 is used if not set
+ -disableDaily
+ Disable daily run. Default false
+ -disableHourly
+ Disable hourly run. Default false
+ -disableMonthly
+ Disable monthly run. Default false
+ -disableWeekly
+ Disable weekly run. Default false
+ -dst string
+ The root folder of Victoria Metrics backups. Example: gs://bucket/path/to/backup/dir, s3://bucket/path/to/backup/dir or fs:///path/to/local/backup/dir
+ -enableTCP6
+ Whether to enable IPv6 for listening and dialing. By default only IPv4 TCP and UDP is used
+ -envflag.enable
+ Whether to enable reading flags from environment variables additionally to command line. Command line flag values have priority over values from environment vars. Flags are read only from command line if this flag isn't set. See https://docs.victoriametrics.com/#environment-variables for more details
+ -envflag.prefix string
+ Prefix for environment variables if -envflag.enable is set
+ -eula
+ By specifying this flag, you confirm that you have an enterprise license and accept the EULA https://victoriametrics.com/assets/VM_EULA.pdf
+ -fs.disableMmap
+ Whether to use pread() instead of mmap() for reading data files. By default mmap() is used for 64-bit arches and pread() is used for 32-bit arches, since they cannot read data files bigger than 2^32 bytes in memory. mmap() is usually faster for reading small data chunks than pread()
+ -http.connTimeout duration
+ Incoming http connections are closed after the configured timeout. This may help to spread the incoming load among a cluster of services behind a load balancer. Please note that the real timeout may be bigger by up to 10% as a protection against the thundering herd problem (default 2m0s)
+ -http.disableResponseCompression
+ Disable compression of HTTP responses to save CPU resources. By default compression is enabled to save network bandwidth
+ -http.idleConnTimeout duration
+ Timeout for incoming idle http connections (default 1m0s)
+ -http.maxGracefulShutdownDuration duration
+ The maximum duration for a graceful shutdown of the HTTP server. A highly loaded server may require increased value for a graceful shutdown (default 7s)
+ -http.pathPrefix string
+ An optional prefix to add to all the paths handled by http server. For example, if '-http.pathPrefix=/foo/bar' is set, then all the http requests will be handled on '/foo/bar/*' paths. This may be useful for proxied requests. See https://www.robustperception.io/using-external-urls-and-proxies-with-prometheus
+ -http.shutdownDelay duration
+ Optional delay before http server shutdown. During this delay, the server returns non-OK responses from /health page, so load balancers can route new requests to other servers
+ -httpAuth.password string
+ Password for HTTP Basic Auth. The authentication is disabled if -httpAuth.username is empty
+ -httpAuth.username string
+ Username for HTTP Basic Auth. The authentication is disabled if empty. See also -httpAuth.password
+ -httpListenAddr string
+ Address to listen for http connections (default ":8300")
+ -keepLastDaily int
+ Keep last N daily backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastHourly int
+ Keep last N hourly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastMonthly int
+ Keep last N monthly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -keepLastWeekly int
+ Keep last N weekly backups. If 0 is specified next retention cycle removes all backups for given time period. (default -1)
+ -loggerDisableTimestamps
+ Whether to disable writing timestamps in logs
+ -loggerErrorsPerSecondLimit int
+ Per-second limit on the number of ERROR messages. If more than the given number of errors are emitted per second, the remaining errors are suppressed. Zero values disable the rate limit
+ -loggerFormat string
+ Format for logs. Possible values: default, json (default "default")
+ -loggerLevel string
+ Minimum level of errors to log. Possible values: INFO, WARN, ERROR, FATAL, PANIC (default "INFO")
+ -loggerOutput string
+ Output for the logs. Supported values: stderr, stdout (default "stderr")
+ -loggerTimezone string
+ Timezone to use for timestamps in logs. Timezone must be a valid IANA Time Zone. For example: America/New_York, Europe/Berlin, Etc/GMT+3 or Local (default "UTC")
+ -loggerWarnsPerSecondLimit int
+ Per-second limit on the number of WARN messages. If more than the given number of warns are emitted per second, then the remaining warns are suppressed. Zero values disable the rate limit
+ -maxBytesPerSecond int
+ The maximum upload speed. There is no limit if it is set to 0
+ -memory.allowedBytes size
+ Allowed size of system memory VictoriaMetrics caches may occupy. This option overrides -memory.allowedPercent if set to a non-zero value. Too low a value may increase the cache miss rate usually resulting in higher CPU and disk IO usage. Too high a value may evict too much data from OS page cache resulting in higher disk IO usage
+ Supports the following optional suffixes for size values: KB, MB, GB, KiB, MiB, GiB (default 0)
+ -memory.allowedPercent float
+ Allowed percent of system memory VictoriaMetrics caches may occupy. See also -memory.allowedBytes. Too low a value may increase cache miss rate usually resulting in higher CPU and disk IO usage. Too high a value may evict too much data from OS page cache which will result in higher disk IO usage (default 60)
+ -metricsAuthKey string
+ Auth key for /metrics. It must be passed via authKey query arg. It overrides httpAuth.* settings
+ -pprofAuthKey string
+ Auth key for /debug/pprof. It must be passed via authKey query arg. It overrides httpAuth.* settings
+ -runOnStart
+ Upload backups immediately after start of the service. Otherwise the backup starts on new hour
+ -s3ForcePathStyle
+ Prefixing endpoint with bucket name when set false, true by default. (default true)
+ -snapshot.createURL string
+ VictoriaMetrics create snapshot url. When this is given a snapshot will automatically be created during backup.Example: http://victoriametrics:8428/snapshot/create
+ -snapshot.deleteURL string
+ VictoriaMetrics delete snapshot url. Optional. Will be generated from snapshot.createURL if not provided. All created snaphosts will be automatically deleted.Example: http://victoriametrics:8428/snapshot/delete
+ -storageDataPath string
+ Path to VictoriaMetrics data. Must match -storageDataPath from VictoriaMetrics or vmstorage (default "victoria-metrics-data")
+ -tls
+ Whether to enable TLS for incoming HTTP requests at -httpListenAddr (aka https). -tlsCertFile and -tlsKeyFile must be set if -tls is set
+ -tlsCertFile string
+ Path to file with TLS certificate if -tls is set. Prefer ECDSA certs instead of RSA certs as RSA certs are slower. The provided certificate file is automatically re-read every second, so it can be dynamically updated
+ -tlsCipherSuites array
+ Optional list of TLS cipher suites for incoming requests over HTTPS if -tls is set. See the list of supported cipher suites at https://pkg.go.dev/crypto/tls#pkg-constants
+ Supports an array of values separated by comma or specified via multiple flags.
+ -tlsKeyFile string
+ Path to file with TLS key if -tls is set. The provided key file is automatically re-read every second, so it can be dynamically updated
+ -version
+ Show VictoriaMetrics version
+```
\ No newline at end of file
From 58c14723946a414ccddae9d00f451bbcfc51922b Mon Sep 17 00:00:00 2001
From: Manuel Polo
Date: Sun, 8 May 2022 21:43:42 +0200
Subject: [PATCH 03/51] docs: fix typo in quickstart
---
docs/Quick-Start.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/Quick-Start.md b/docs/Quick-Start.md
index 16fb659534..0dd9018de6 100644
--- a/docs/Quick-Start.md
+++ b/docs/Quick-Start.md
@@ -20,7 +20,7 @@ Single-server-VictoriaMetrics VictoriaMetrics is available as:
Just download VictoriaMetrics and follow [these instructions](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-start-victoriametrics).
Then read [Prometheus setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#prometheus-setup) and [Grafana setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#grafana-setup) docs.
-### Starting VM-Signle via Docker:
+### Starting VM-Single via Docker:
The following commands download the latest available [Docker image of VictoriaMetrics](https://hub.docker.com/r/victoriametrics/victoria-metrics) and start it at port 8428, while storing the ingested data at `victoria-metrics-data` subdirectory under the current directory:
From e9fa36348050bb34520cb8a6507da22ff3c53fdd Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Mon, 9 May 2022 08:11:06 +0000
Subject: [PATCH 04/51] Vmalert fix bugs in alerting evaluation (#2557)
* vmalert: calculate time for firing alert based on the given timestamp
Previously, current time was used for checking the `firing` threshold.
This is not correct, since alerts are evaluated at specific timestamps.
Hence, this specific timestamp supposed to be used in the calculation.
Signed-off-by: hagen1778
* vmalert: properly calculate evaluation timestamp for rules
Timestamp for rules evaluation should be calculated after
the artifical delay for groups start. Otherwise, evaluation
timestamp can fall back too far in time.
Signed-off-by: hagen1778
---
app/vmalert/alerting.go | 2 +-
app/vmalert/group.go | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/vmalert/alerting.go b/app/vmalert/alerting.go
index 0f819cbd64..64a86bbea6 100644
--- a/app/vmalert/alerting.go
+++ b/app/vmalert/alerting.go
@@ -323,7 +323,7 @@ func (ar *AlertingRule) Exec(ctx context.Context, ts time.Time) ([]prompbmarshal
}
continue
}
- if a.State == notifier.StatePending && time.Since(a.ActiveAt) >= ar.For {
+ if a.State == notifier.StatePending && ts.Sub(a.ActiveAt) >= ar.For {
a.State = notifier.StateFiring
a.Start = ts
alertsFired.Inc()
diff --git a/app/vmalert/group.go b/app/vmalert/group.go
index e218e4fc75..d89f5037c3 100644
--- a/app/vmalert/group.go
+++ b/app/vmalert/group.go
@@ -237,8 +237,6 @@ func (g *Group) start(ctx context.Context, nts func() []notifier.Notifier, rw *r
notifiers: nts,
previouslySentSeriesToRW: make(map[uint64]map[string][]prompbmarshal.Label)}
- evalTS := time.Now()
-
// Spread group rules evaluation over time in order to reduce load on VictoriaMetrics.
if !skipRandSleepOnGroupStart {
randSleep := uint64(float64(g.Interval) * (float64(g.ID()) / (1 << 64)))
@@ -259,6 +257,8 @@ func (g *Group) start(ctx context.Context, nts func() []notifier.Notifier, rw *r
}
}
+ evalTS := time.Now()
+
logger.Infof("group %q started; interval=%v; concurrency=%d", g.Name, g.Interval, g.Concurrency)
eval := func(ts time.Time) {
From 331a5d9a17b9f9870574093bb73a226ebf005214 Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Mon, 9 May 2022 08:11:56 +0000
Subject: [PATCH 05/51] Code check (#2558)
* vmstorage: make gofmt happy
Signed-off-by: hagen1778
* vmalert: make linter happy
Signed-off-by: hagen1778
---
app/vmalert/main.go | 2 +-
app/vmalert/notifier/alert_test.go | 2 +-
app/vmstorage/main.go | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/app/vmalert/main.go b/app/vmalert/main.go
index 9366ad3500..b3ffe17c83 100644
--- a/app/vmalert/main.go
+++ b/app/vmalert/main.go
@@ -170,7 +170,7 @@ func newManager(ctx context.Context) (*manager, error) {
return nil, fmt.Errorf("failed to init datasource: %w", err)
}
- labels := make(map[string]string, 0)
+ labels := make(map[string]string)
for _, s := range *externalLabels {
if len(s) == 0 {
continue
diff --git a/app/vmalert/notifier/alert_test.go b/app/vmalert/notifier/alert_test.go
index 9f5a932201..1a55b99f7a 100644
--- a/app/vmalert/notifier/alert_test.go
+++ b/app/vmalert/notifier/alert_test.go
@@ -11,7 +11,7 @@ import (
)
func TestAlert_ExecTemplate(t *testing.T) {
- extLabels := make(map[string]string, 0)
+ extLabels := make(map[string]string)
const (
extCluster = "prod"
extDC = "east"
diff --git a/app/vmstorage/main.go b/app/vmstorage/main.go
index 6269fd6364..e738ea3184 100644
--- a/app/vmstorage/main.go
+++ b/app/vmstorage/main.go
@@ -95,7 +95,7 @@ func InitWithoutMetrics(resetCacheIfNeeded func(mrs []storage.MetricRow)) {
mergeset.SetIndexBlocksCacheSize(cacheSizeIndexDBIndexBlocks.N)
mergeset.SetDataBlocksCacheSize(cacheSizeIndexDBDataBlocks.N)
- if retentionPeriod.Msecs < 24 * 3600 * 1000 {
+ if retentionPeriod.Msecs < 24*3600*1000 {
logger.Fatalf("-retentionPeriod cannot be smaller than a day; got %s", retentionPeriod)
}
logger.Infof("opening storage at %q with -retentionPeriod=%s", *DataPath, retentionPeriod)
From 84326eacd692ae5f6662c28e4af8f6c54a902f72 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Mon, 9 May 2022 15:27:38 +0300
Subject: [PATCH 06/51] docs/Release-Guide.md: typo fix: signle->single
---
docs/Release-Guide.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/Release-Guide.md b/docs/Release-Guide.md
index 5f133cc11b..8f103d4d4a 100644
--- a/docs/Release-Guide.md
+++ b/docs/Release-Guide.md
@@ -52,7 +52,7 @@ The helm chart repository [https://github.com/VictoriaMetrics/helm-charts/](http
3. Update `vmauth` chart version in [`values.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-auth/values.yaml) and [`Chart.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-auth/Chart.yaml)
4. Update `cluster` chart versions in [`values.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-cluster/values.yaml), bump version for `vmselect`, `vminsert` and `vmstorage` and [`Chart.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-cluster/Chart.yaml)
5. Update `k8s-stack` chart versions in [`values.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-k8s-stack/values.yaml), bump version for `vmselect`, `vminsert`, `vmstorage`, `vmsingle`, `vmalert`, `vmagent` and [`Chart.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-k8s-stack/Chart.yaml)
-6. Update `signle` chart version in [`values.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-single/values.yaml) and [`Chart.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-single/Chart.yaml)
+6. Update `single-node` chart version in [`values.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-single/values.yaml) and [`Chart.yaml`](https://github.com/VictoriaMetrics/helm-charts/blob/master/charts/victoria-metrics-single/Chart.yaml)
8. Run `make gen-doc`
9. Run `make package` that creates or updates zip file with the packed chart
10. Run `make merge`. It creates or updates metadata for charts in index.yaml
From 9ea3f0c0d354a752dd0af35d773a47f7960e19ce Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Mon, 9 May 2022 15:33:19 +0300
Subject: [PATCH 07/51] lib/awsapi: remove whitelist arg from
GetFiltersQueryString(), since it may break new filters in the future
Let users decide which filters to use. If users start using disallowed filters, then AWS will return an error.
---
lib/awsapi/config.go | 7 +------
lib/promscrape/discovery/ec2/az.go | 16 +---------------
lib/promscrape/discovery/ec2/instance.go | 2 +-
3 files changed, 3 insertions(+), 22 deletions(-)
diff --git a/lib/awsapi/config.go b/lib/awsapi/config.go
index 522c582da5..eb6dd5f225 100644
--- a/lib/awsapi/config.go
+++ b/lib/awsapi/config.go
@@ -427,15 +427,10 @@ func buildAPIEndpoint(customEndpoint, region, service string) string {
}
// GetFiltersQueryString returns query string formed from the given filters.
-//
-// If whitelist isn't nil, then filters which don't fall into whitelist isn't returned.
-func GetFiltersQueryString(filters []Filter, whitelist map[string]bool) string {
+func GetFiltersQueryString(filters []Filter) string {
// See how to build filters query string at examples at https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeInstances.html
var args []string
for i, f := range filters {
- if whitelist != nil && !whitelist[f.Name] {
- continue
- }
args = append(args, fmt.Sprintf("Filter.%d.Name=%s", i+1, url.QueryEscape(f.Name)))
for j, v := range f.Values {
args = append(args, fmt.Sprintf("Filter.%d.Value.%d=%s", i+1, j+1, url.QueryEscape(v)))
diff --git a/lib/promscrape/discovery/ec2/az.go b/lib/promscrape/discovery/ec2/az.go
index 42ce2fd847..e6ffb00e13 100644
--- a/lib/promscrape/discovery/ec2/az.go
+++ b/lib/promscrape/discovery/ec2/az.go
@@ -30,7 +30,7 @@ func getAZMap(cfg *apiConfig) map[string]string {
func getAvailabilityZones(cfg *apiConfig) ([]AvailabilityZone, error) {
// See https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeAvailabilityZones.html
- azFilters := awsapi.GetFiltersQueryString(cfg.azFilters, azFiltersWhitelist)
+ azFilters := awsapi.GetFiltersQueryString(cfg.azFilters)
data, err := cfg.awsConfig.GetEC2APIResponse("DescribeAvailabilityZones", azFilters, "")
if err != nil {
return nil, fmt.Errorf("cannot obtain availability zones: %w", err)
@@ -42,20 +42,6 @@ func getAvailabilityZones(cfg *apiConfig) ([]AvailabilityZone, error) {
return azr.AvailabilityZoneInfo.Items, nil
}
-// See https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeAvailabilityZones.html
-var azFiltersWhitelist = map[string]bool{
- "group-name": true,
- "message": true,
- "opt-in-status": true,
- "parent-zoneID": true,
- "parent-zoneName": true,
- "region-name": true,
- "state": true,
- "zone-id": true,
- "zone-type": true,
- "zone-name": true,
-}
-
// AvailabilityZonesResponse represents the response for https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeAvailabilityZones.html
type AvailabilityZonesResponse struct {
AvailabilityZoneInfo AvailabilityZoneInfo `xml:"availabilityZoneInfo"`
diff --git a/lib/promscrape/discovery/ec2/instance.go b/lib/promscrape/discovery/ec2/instance.go
index b7a219f0ba..c111aaf306 100644
--- a/lib/promscrape/discovery/ec2/instance.go
+++ b/lib/promscrape/discovery/ec2/instance.go
@@ -29,7 +29,7 @@ func getReservations(cfg *apiConfig) ([]Reservation, error) {
// See https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeInstances.html
var rs []Reservation
pageToken := ""
- instanceFilters := awsapi.GetFiltersQueryString(cfg.instanceFilters, nil)
+ instanceFilters := awsapi.GetFiltersQueryString(cfg.instanceFilters)
for {
data, err := cfg.awsConfig.GetEC2APIResponse("DescribeInstances", instanceFilters, pageToken)
if err != nil {
From f901788c7fe3d22705f9eb551fa7be76a4a23d12 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Mon, 9 May 2022 17:32:51 +0300
Subject: [PATCH 08/51] docs/CHANGELOG.md: document
8f4f5f1d68b8d6f366f98dc17bd16fc513285c00
---
docs/CHANGELOG.md | 3 +++
1 file changed, 3 insertions(+)
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 85e7ee2d96..a90863cf60 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -15,6 +15,9 @@ The following tip changes can be tested by building VictoriaMetrics components f
## tip
+* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
+
+
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
Released at 07-05-2022
From e4bbcc29c2d4aae41e3dcd164b86c1b65e07a46f Mon Sep 17 00:00:00 2001
From: Denys Holius <5650611+denisgolius@users.noreply.github.com>
Date: Mon, 9 May 2022 17:52:36 +0300
Subject: [PATCH 09/51] Update golangci version to latest v1.46.0 (#2560)
Update golangci version to latest https://github.com/golangci/golangci-lint/tree/v1.46.0
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index d19a5d1138..25d397b7da 100644
--- a/Makefile
+++ b/Makefile
@@ -283,7 +283,7 @@ golangci-lint: install-golangci-lint
golangci-lint run --exclude '(SA4003|SA1019|SA5011):' -D errcheck -D structcheck --timeout 2m
install-golangci-lint:
- which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.45.1
+ which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.46.0
install-wwhrd:
which wwhrd || GO111MODULE=off go get github.com/frapposelli/wwhrd
From a7f18f8cb2fa03a3df3d858ecf9b07cda6dd94eb Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Mon, 9 May 2022 17:57:02 +0300
Subject: [PATCH 10/51] app/vmselect/promql: do not return values from
`label_value()` if the original time series has no values at the selected
timestamps
---
app/vmselect/promql/exec_test.go | 4 ++--
app/vmselect/promql/transform.go | 6 ++++--
docs/CHANGELOG.md | 1 +
3 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/app/vmselect/promql/exec_test.go b/app/vmselect/promql/exec_test.go
index c157948482..c08616df52 100644
--- a/app/vmselect/promql/exec_test.go
+++ b/app/vmselect/promql/exec_test.go
@@ -2069,7 +2069,7 @@ func TestExecSuccess(t *testing.T) {
t.Parallel()
q := `with (
x = (
- label_set(time(), "foo", "123.456", "__name__", "aaa"),
+ label_set(time() > 1500, "foo", "123.456", "__name__", "aaa"),
label_set(-time(), "foo", "bar", "__name__", "bbb"),
label_set(-time(), "__name__", "bxs"),
label_set(-time(), "foo", "45", "bar", "xs"),
@@ -2093,7 +2093,7 @@ func TestExecSuccess(t *testing.T) {
}
r2 := netstorage.Result{
MetricName: metricNameExpected,
- Values: []float64{1123.456, 1323.456, 1523.456, 1723.456, 1923.456, 2123.456},
+ Values: []float64{nan, nan, nan, 1723.456, 1923.456, 2123.456},
Timestamps: timestampsExpected,
}
r2.MetricName.Tags = []storage.Tag{
diff --git a/app/vmselect/promql/transform.go b/app/vmselect/promql/transform.go
index a941e0a3ff..52eafd2b4a 100644
--- a/app/vmselect/promql/transform.go
+++ b/app/vmselect/promql/transform.go
@@ -1715,8 +1715,10 @@ func transformLabelValue(tfa *transformFuncArg) ([]*timeseries, error) {
v = nan
}
values := ts.Values
- for i := range values {
- values[i] = v
+ for i, vOrig := range values {
+ if !math.IsNaN(vOrig) {
+ values[i] = v
+ }
}
}
// Do not remove timeseries with only NaN values, so `default` could be applied to them:
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index a90863cf60..bff9aa8d4c 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -17,6 +17,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
+* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) functionif the original time series has no values at the selected timestamps.
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
From c8af625bcc05c24557ebcd145d5f813036915dea Mon Sep 17 00:00:00 2001
From: Dmytro Kozlov
Date: Mon, 9 May 2022 22:36:18 +0300
Subject: [PATCH 11/51] vmctl: fix build for solaris os (#2555)
* vmctl: fix build for solaris os
* vmctl: updated dependency (using Syscall instead of Syscall6)
* vmctl: updated dependency
* vmctl: updated dependency
---
app/vmalert/replay.go | 3 +-
app/vmctl/barpool/pool.go | 2 +-
app/vmctl/opentsdb.go | 2 +-
app/vmctl/vm/vm.go | 3 +-
go.mod | 2 +-
go.sum | 4 +--
vendor/github.com/cheggaaa/pb/v3/preset.go | 15 ----------
.../cheggaaa/pb/v3/termutil/term_nix.go | 8 -----
.../{cheggaaa => dmitryk-dk}/pb/v3/LICENSE | 0
.../{cheggaaa => dmitryk-dk}/pb/v3/element.go | 0
.../{cheggaaa => dmitryk-dk}/pb/v3/io.go | 0
.../{cheggaaa => dmitryk-dk}/pb/v3/pb.go | 2 +-
.../{cheggaaa => dmitryk-dk}/pb/v3/pool.go | 4 +--
.../pb/v3/pool_win.go | 6 ++--
.../{cheggaaa => dmitryk-dk}/pb/v3/pool_x.go | 4 +--
vendor/github.com/dmitryk-dk/pb/v3/preset.go | 15 ++++++++++
.../{cheggaaa => dmitryk-dk}/pb/v3/speed.go | 0
.../pb/v3/template.go | 0
.../pb/v3/termutil/term.go | 0
.../pb/v3/termutil/term_appengine.go | 2 +-
.../pb/v3/termutil/term_bsd.go | 3 +-
.../pb/v3/termutil/term_linux.go | 3 +-
.../dmitryk-dk/pb/v3/termutil/term_nix.go | 7 +++++
.../pb/v3/termutil/term_plan9.go | 0
.../pb/v3/termutil/term_solaris.go | 3 +-
.../pb/v3/termutil/term_win.go | 2 +-
.../pb/v3/termutil/term_x.go | 29 +++++++++----------
.../{cheggaaa => dmitryk-dk}/pb/v3/util.go | 0
vendor/modules.txt | 8 ++---
29 files changed, 59 insertions(+), 68 deletions(-)
delete mode 100644 vendor/github.com/cheggaaa/pb/v3/preset.go
delete mode 100644 vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/LICENSE (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/element.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/io.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/pb.go (99%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/pool.go (92%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/pool_win.go (86%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/pool_x.go (84%)
create mode 100644 vendor/github.com/dmitryk-dk/pb/v3/preset.go
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/speed.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/template.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_appengine.go (92%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_bsd.go (60%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_linux.go (76%)
create mode 100644 vendor/github.com/dmitryk-dk/pb/v3/termutil/term_nix.go
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_plan9.go (100%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_solaris.go (78%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_win.go (99%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/termutil/term_x.go (55%)
rename vendor/github.com/{cheggaaa => dmitryk-dk}/pb/v3/util.go (100%)
diff --git a/app/vmalert/replay.go b/app/vmalert/replay.go
index c021122414..16f1829026 100644
--- a/app/vmalert/replay.go
+++ b/app/vmalert/replay.go
@@ -7,13 +7,12 @@ import (
"strings"
"time"
- "github.com/cheggaaa/pb/v3"
-
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/config"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/datasource"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/remotewrite"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/logger"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/prompbmarshal"
+ "github.com/dmitryk-dk/pb/v3"
)
var (
diff --git a/app/vmctl/barpool/pool.go b/app/vmctl/barpool/pool.go
index 4f095d8acf..c81c81ceee 100644
--- a/app/vmctl/barpool/pool.go
+++ b/app/vmctl/barpool/pool.go
@@ -3,7 +3,7 @@
// altogether.
package barpool
-import "github.com/cheggaaa/pb/v3"
+import "github.com/dmitryk-dk/pb/v3"
var pool = pb.NewPool()
diff --git a/app/vmctl/opentsdb.go b/app/vmctl/opentsdb.go
index e31de67f0f..b54f7fd8a0 100644
--- a/app/vmctl/opentsdb.go
+++ b/app/vmctl/opentsdb.go
@@ -8,7 +8,7 @@ import (
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmctl/opentsdb"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmctl/vm"
- "github.com/cheggaaa/pb/v3"
+ "github.com/dmitryk-dk/pb/v3"
)
type otsdbProcessor struct {
diff --git a/app/vmctl/vm/vm.go b/app/vmctl/vm/vm.go
index 8809db7a23..481258532a 100644
--- a/app/vmctl/vm/vm.go
+++ b/app/vmctl/vm/vm.go
@@ -13,11 +13,10 @@ import (
"sync"
"time"
- "github.com/cheggaaa/pb/v3"
-
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmctl/barpool"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmctl/limiter"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/decimal"
+ "github.com/dmitryk-dk/pb/v3"
)
// Config contains list of params to configure
diff --git a/go.mod b/go.mod
index ffa2f44cc8..38cafc8151 100644
--- a/go.mod
+++ b/go.mod
@@ -13,7 +13,7 @@ require (
github.com/VictoriaMetrics/metricsql v0.43.0
github.com/aws/aws-sdk-go v1.44.9
github.com/cespare/xxhash/v2 v2.1.2
- github.com/cheggaaa/pb/v3 v3.0.9-0.20211222075416-90c02fa07ea4
+ github.com/dmitryk-dk/pb/v3 v3.0.9
github.com/golang/snappy v0.0.4
github.com/influxdata/influxdb v1.9.6
github.com/klauspost/compress v1.15.3
diff --git a/go.sum b/go.sum
index 698abb12ba..416971a242 100644
--- a/go.sum
+++ b/go.sum
@@ -198,8 +198,6 @@ github.com/cespare/xxhash/v2 v2.1.0/go.mod h1:dgIUBU3pDso/gPgZ1osOZ0iQf77oPR28Tj
github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE=
github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
-github.com/cheggaaa/pb/v3 v3.0.9-0.20211222075416-90c02fa07ea4 h1:sbHAiGddrdLsd3i9/RYsm0OKOEh+UDFOONxai8YMMcw=
-github.com/cheggaaa/pb/v3 v3.0.9-0.20211222075416-90c02fa07ea4/go.mod h1:UICbiLec/XO6Hw6k+BHEtHeQFzzBH4i2/qk/ow1EJTA=
github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI=
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI=
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU=
@@ -244,6 +242,8 @@ github.com/dgryski/go-sip13 v0.0.0-20190329191031-25c5027a8c7b/go.mod h1:vAd38F8
github.com/dgryski/go-sip13 v0.0.0-20200911182023-62edffca9245/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/digitalocean/godo v1.52.0/go.mod h1:p7dOjjtSBqCTUksqtA5Fd3uaKs9kyTq2xcz76ulEJRU=
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
+github.com/dmitryk-dk/pb/v3 v3.0.9 h1:wpWkldo8V6NeONVgmuCvsDIDjSRkJfbTbdoVigKYJ2I=
+github.com/dmitryk-dk/pb/v3 v3.0.9/go.mod h1:o9xpZcwYZHNdNaAlJVvWTA+YH+IlPciBs1myroBOxyM=
github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w=
github.com/docker/docker v17.12.0-ce-rc1.0.20200706150819-a40b877fbb9e+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk=
github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec=
diff --git a/vendor/github.com/cheggaaa/pb/v3/preset.go b/vendor/github.com/cheggaaa/pb/v3/preset.go
deleted file mode 100644
index f5e2fff57e..0000000000
--- a/vendor/github.com/cheggaaa/pb/v3/preset.go
+++ /dev/null
@@ -1,15 +0,0 @@
-package pb
-
-var (
- // Full - preset with all default available elements
- // Example: 'Prefix 20/100 [-->______] 20% 1 p/s ETA 1m Suffix'
- Full ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }} {{speed . }} {{rtime . "ETA %s"}}{{string . "suffix"}}`
-
- // Default - preset like Full but without elapsed time
- // Example: 'Prefix 20/100 [-->______] 20% 1 p/s ETA 1m Suffix'
- Default ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }} {{speed . }}{{string . "suffix"}}`
-
- // Simple - preset without speed and any timers. Only counters, bar and percents
- // Example: 'Prefix 20/100 [-->______] 20% Suffix'
- Simple ProgressBarTemplate = `{{string . "prefix"}}{{counters . }} {{bar . }} {{percent . }}{{string . "suffix"}}`
-)
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go b/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go
deleted file mode 100644
index 14277e71ff..0000000000
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_nix.go
+++ /dev/null
@@ -1,8 +0,0 @@
-// +build linux darwin freebsd netbsd openbsd dragonfly
-// +build !appengine
-
-package termutil
-
-import "syscall"
-
-const sysIoctl = syscall.SYS_IOCTL
diff --git a/vendor/github.com/cheggaaa/pb/v3/LICENSE b/vendor/github.com/dmitryk-dk/pb/v3/LICENSE
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/LICENSE
rename to vendor/github.com/dmitryk-dk/pb/v3/LICENSE
diff --git a/vendor/github.com/cheggaaa/pb/v3/element.go b/vendor/github.com/dmitryk-dk/pb/v3/element.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/element.go
rename to vendor/github.com/dmitryk-dk/pb/v3/element.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/io.go b/vendor/github.com/dmitryk-dk/pb/v3/io.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/io.go
rename to vendor/github.com/dmitryk-dk/pb/v3/io.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/pb.go b/vendor/github.com/dmitryk-dk/pb/v3/pb.go
similarity index 99%
rename from vendor/github.com/cheggaaa/pb/v3/pb.go
rename to vendor/github.com/dmitryk-dk/pb/v3/pb.go
index 76440e1727..3ace32ef2a 100644
--- a/vendor/github.com/cheggaaa/pb/v3/pb.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/pb.go
@@ -17,7 +17,7 @@ import (
"github.com/mattn/go-colorable"
"github.com/mattn/go-isatty"
- "github.com/cheggaaa/pb/v3/termutil"
+ "github.com/dmitryk-dk/pb/v3/termutil"
)
// Version of ProgressBar library
diff --git a/vendor/github.com/cheggaaa/pb/v3/pool.go b/vendor/github.com/dmitryk-dk/pb/v3/pool.go
similarity index 92%
rename from vendor/github.com/cheggaaa/pb/v3/pool.go
rename to vendor/github.com/dmitryk-dk/pb/v3/pool.go
index 69cc825b6c..6f66099899 100644
--- a/vendor/github.com/cheggaaa/pb/v3/pool.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/pool.go
@@ -1,4 +1,4 @@
-// +build linux darwin freebsd netbsd openbsd solaris dragonfly windows plan9 aix
+//go:build linux || darwin || freebsd || netbsd || openbsd || solaris || dragonfly || windows || plan9 || aix
package pb
@@ -7,7 +7,7 @@ import (
"sync"
"time"
- "github.com/cheggaaa/pb/v3/termutil"
+ "github.com/dmitryk-dk/pb/v3/termutil"
)
// Create and start new pool with given bars
diff --git a/vendor/github.com/cheggaaa/pb/v3/pool_win.go b/vendor/github.com/dmitryk-dk/pb/v3/pool_win.go
similarity index 86%
rename from vendor/github.com/cheggaaa/pb/v3/pool_win.go
rename to vendor/github.com/dmitryk-dk/pb/v3/pool_win.go
index 35a61474a9..dcdfa9fa40 100644
--- a/vendor/github.com/cheggaaa/pb/v3/pool_win.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/pool_win.go
@@ -1,4 +1,4 @@
-// +build windows
+//go:build windows
package pb
@@ -6,7 +6,7 @@ import (
"fmt"
"log"
- "github.com/cheggaaa/pb/v3/termutil"
+ "github.com/dmitryk-dk/pb/v3/termutil"
)
func (p *Pool) print(first bool) bool {
@@ -24,7 +24,7 @@ func (p *Pool) print(first bool) bool {
}
coords.X = 0
- err = termutil.SetCursorPos(coords)
+ err = termutil.SetCursorPos(coords)
if err != nil {
log.Panic(err)
}
diff --git a/vendor/github.com/cheggaaa/pb/v3/pool_x.go b/vendor/github.com/dmitryk-dk/pb/v3/pool_x.go
similarity index 84%
rename from vendor/github.com/cheggaaa/pb/v3/pool_x.go
rename to vendor/github.com/dmitryk-dk/pb/v3/pool_x.go
index 4350301555..552289be76 100644
--- a/vendor/github.com/cheggaaa/pb/v3/pool_x.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/pool_x.go
@@ -1,4 +1,4 @@
-// +build linux darwin freebsd netbsd openbsd solaris dragonfly plan9 aix
+//go:build linux || darwin || freebsd || netbsd || openbsd || solaris || dragonfly || plan9 || aix
package pb
@@ -6,7 +6,7 @@ import (
"fmt"
"os"
- "github.com/cheggaaa/pb/v3/termutil"
+ "github.com/dmitryk-dk/pb/v3/termutil"
)
func (p *Pool) print(first bool) bool {
diff --git a/vendor/github.com/dmitryk-dk/pb/v3/preset.go b/vendor/github.com/dmitryk-dk/pb/v3/preset.go
new file mode 100644
index 0000000000..f3ca193985
--- /dev/null
+++ b/vendor/github.com/dmitryk-dk/pb/v3/preset.go
@@ -0,0 +1,15 @@
+package pb
+
+var (
+ // Full - preset with all default available elements
+ // Example: 'Prefix 20/100 [-->______] 20% 1 p/s ETA 1m Suffix'
+ Full ProgressBarTemplate = `{{with string . "prefix"}}{{.}} {{end}}{{counters . }} {{bar . }} {{percent . }} {{speed . }} {{rtime . "ETA %s"}}{{with string . "suffix"}} {{.}}{{end}}`
+
+ // Default - preset like Full but without elapsed time
+ // Example: 'Prefix 20/100 [-->______] 20% 1 p/s Suffix'
+ Default ProgressBarTemplate = `{{with string . "prefix"}}{{.}} {{end}}{{counters . }} {{bar . }} {{percent . }} {{speed . }}{{with string . "suffix"}} {{.}}{{end}}`
+
+ // Simple - preset without speed and any timers. Only counters, bar and percents
+ // Example: 'Prefix 20/100 [-->______] 20% Suffix'
+ Simple ProgressBarTemplate = `{{with string . "prefix"}}{{.}} {{end}}{{counters . }} {{bar . }} {{percent . }}{{with string . "suffix"}} {{.}}{{end}}`
+)
diff --git a/vendor/github.com/cheggaaa/pb/v3/speed.go b/vendor/github.com/dmitryk-dk/pb/v3/speed.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/speed.go
rename to vendor/github.com/dmitryk-dk/pb/v3/speed.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/template.go b/vendor/github.com/dmitryk-dk/pb/v3/template.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/template.go
rename to vendor/github.com/dmitryk-dk/pb/v3/template.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_appengine.go
similarity index 92%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_appengine.go
index 4b7b20e6b6..765ff2bdfc 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_appengine.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_appengine.go
@@ -1,4 +1,4 @@
-// +build appengine
+//go:build appengine
package termutil
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_bsd.go
similarity index 60%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_bsd.go
index 272659a125..d29404a393 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_bsd.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_bsd.go
@@ -1,5 +1,4 @@
-// +build darwin freebsd netbsd openbsd dragonfly
-// +build !appengine
+//go:build (darwin || freebsd || netbsd || openbsd || dragonfly) && !appengine
package termutil
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_linux.go
similarity index 76%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_linux.go
index 2f59e53e16..bec62af6cf 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_linux.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_linux.go
@@ -1,5 +1,4 @@
-// +build linux
-// +build !appengine
+//go:build linux && !appengine
package termutil
diff --git a/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_nix.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_nix.go
new file mode 100644
index 0000000000..4513e37d40
--- /dev/null
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_nix.go
@@ -0,0 +1,7 @@
+//go:build (linux || darwin || freebsd || netbsd || openbsd || dragonfly) && !appengine
+
+package termutil
+
+import "syscall"
+
+const sysIoctl = syscall.SYS_IOCTL
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_plan9.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_plan9.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_plan9.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_plan9.go
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_solaris.go
similarity index 78%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_solaris.go
index fc96c2b7f8..02cfabf442 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_solaris.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_solaris.go
@@ -1,5 +1,4 @@
-// +build solaris
-// +build !appengine
+//go:build solaris && !appengine
package termutil
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_win.go
similarity index 99%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_win.go
index 3150dfd31c..1ccf131e98 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_win.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_win.go
@@ -1,4 +1,4 @@
-// +build windows
+//go:build windows
package termutil
diff --git a/vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_x.go
similarity index 55%
rename from vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go
rename to vendor/github.com/dmitryk-dk/pb/v3/termutil/term_x.go
index 1674d3e5ec..0b48aae937 100644
--- a/vendor/github.com/cheggaaa/pb/v3/termutil/term_x.go
+++ b/vendor/github.com/dmitryk-dk/pb/v3/termutil/term_x.go
@@ -1,5 +1,4 @@
-// +build linux darwin freebsd netbsd openbsd solaris dragonfly
-// +build !appengine
+//go:build (linux || darwin || freebsd || netbsd || openbsd || solaris || dragonfly) && !appengine
package termutil
@@ -16,6 +15,7 @@ var (
unlockSignals = []os.Signal{
os.Interrupt, syscall.SIGQUIT, syscall.SIGTERM, syscall.SIGKILL,
}
+ oldState syscall.Termios
)
type window struct {
@@ -53,30 +53,27 @@ func TerminalSize() (rows, cols int, err error) {
return int(w.Row), int(w.Col), nil
}
-var oldState syscall.Termios
-
-func lockEcho() (err error) {
+func lockEcho() error {
fd := tty.Fd()
- if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&oldState)), 0, 0, 0); e != 0 {
- err = fmt.Errorf("Can't get terminal settings: %v", e)
- return
+
+ if _, _, err := syscall.Syscall(sysIoctl, fd, ioctlReadTermios, uintptr(unsafe.Pointer(&oldState))); err != 0 {
+ return fmt.Errorf("error when puts the terminal connected to the given file descriptor: %v", err)
}
newState := oldState
newState.Lflag &^= syscall.ECHO
newState.Lflag |= syscall.ICANON | syscall.ISIG
newState.Iflag |= syscall.ICRNL
- if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&newState)), 0, 0, 0); e != 0 {
- err = fmt.Errorf("Can't set terminal settings: %v", e)
- return
+ if _, _, e := syscall.Syscall(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&newState))); e != 0 {
+ return fmt.Errorf("error update terminal settings: %v", e)
}
- return
+ return nil
}
-func unlockEcho() (err error) {
+func unlockEcho() error {
fd := tty.Fd()
- if _, _, e := syscall.Syscall6(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&oldState)), 0, 0, 0); e != 0 {
- err = fmt.Errorf("Can't set terminal settings")
+ if _, _, err := syscall.Syscall(sysIoctl, fd, ioctlWriteTermios, uintptr(unsafe.Pointer(&oldState))); err != 0 {
+ return fmt.Errorf("error restores the terminal connected to the given file descriptor: %w", err)
}
- return
+ return nil
}
diff --git a/vendor/github.com/cheggaaa/pb/v3/util.go b/vendor/github.com/dmitryk-dk/pb/v3/util.go
similarity index 100%
rename from vendor/github.com/cheggaaa/pb/v3/util.go
rename to vendor/github.com/dmitryk-dk/pb/v3/util.go
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 55a60e3d9c..2f6093d396 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -93,13 +93,13 @@ github.com/beorn7/perks/quantile
# github.com/cespare/xxhash/v2 v2.1.2
## explicit; go 1.11
github.com/cespare/xxhash/v2
-# github.com/cheggaaa/pb/v3 v3.0.9-0.20211222075416-90c02fa07ea4
-## explicit; go 1.12
-github.com/cheggaaa/pb/v3
-github.com/cheggaaa/pb/v3/termutil
# github.com/cpuguy83/go-md2man/v2 v2.0.2
## explicit; go 1.11
github.com/cpuguy83/go-md2man/v2/md2man
+# github.com/dmitryk-dk/pb/v3 v3.0.9
+## explicit; go 1.18
+github.com/dmitryk-dk/pb/v3
+github.com/dmitryk-dk/pb/v3/termutil
# github.com/fatih/color v1.13.0
## explicit; go 1.13
github.com/fatih/color
From 3dbdd4ef8a1125550150f284be2ff18795238cc4 Mon Sep 17 00:00:00 2001
From: Denys Holius <5650611+denisgolius@users.noreply.github.com>
Date: Tue, 10 May 2022 14:16:17 +0300
Subject: [PATCH 12/51] docs: fixed typos in CHANGELOG.md (#2565)
---
docs/CHANGELOG.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index bff9aa8d4c..7e919d26de 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -17,7 +17,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
-* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) functionif the original time series has no values at the selected timestamps.
+* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
@@ -48,7 +48,7 @@ Released at 05-05-2022
* FEATURE: [vmagent](https://docs.victoriametrics.com/vmagent.html): add ability to attach node-level labels and annotations to discovered Kubernetes pod targets in the same way as Prometheus 2.35 does. See [this feature request](https://github.com/prometheus/prometheus/issues/9510) and [this pull request](https://github.com/prometheus/prometheus/pull/10080).
* FEATURE: [vmagent](https://docs.victoriametrics.com/vmagent.html): add support for `tls_config` and `proxy_url` options at `oauth2` section in the same way as Prometheus does. See [oauth2 docs](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#oauth2).
* FEATURE: [vmagent](https://docs.victoriametrics.com/vmagent.html): add support for `min_version` option at `tls_config` section in the same way as Prometheus does. See [tls_config docs](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#tls_config).
-* FEATURE: [vmagent](): expose `vmagent_remotewrite_rate_limit` metric at `http://vmagent:8429/metrics`, which can be used for alerting rules such as `rate(vmagent_remotewrite_conn_bytes_written_total) / vmagent_remotewrite_rate_limit > 0.8` when `-remoteWrite.rateLimit` command-line flag is set. See [this pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2521).
+* FEATURE: [vmagent](https://docs.victoriametrics.com/vmagent.html): expose `vmagent_remotewrite_rate_limit` metric at `http://vmagent:8429/metrics`, which can be used for alerting rules such as `rate(vmagent_remotewrite_conn_bytes_written_total) / vmagent_remotewrite_rate_limit > 0.8` when `-remoteWrite.rateLimit` command-line flag is set. See [this pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2521).
* FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): add support for DNS-based discovery for notifiers in the same way as Prometheus does (aka `dns_sd_configs`). See [these docs](https://docs.victoriametrics.com/vmalert.html#notifier-configuration-file) and [this feature request](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2460).
* FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): add `-replay.disableProgressBar` command-line flag, which allows disabling progressbar in [rules' backfilling mode](https://docs.victoriametrics.com/vmalert.html#rules-backfilling). See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1761).
* FEATURE: allow specifying TLS cipher suites for incoming https requests via `-tlsCipherSuites` command-line flag. See [this feature request](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2404).
From 991688ea651e3728e9a2dc1363cc777732ff574d Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 13:57:54 +0300
Subject: [PATCH 13/51] deployment/docker: pass `-buildvs=false` to `go build`
for production builds
This should resolve the `error obtaining VCS status: exit status 128` error
when the environment contains incorrect version of git or has incorrect access rights
to the directory with VictoriaMetrics source code.
See the following links for additional info:
- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2508#issuecomment-1117126702 ,
- https://github.com/google/ko/issues/672
- https://github.com/golang/go/issues/49004
---
deployment/docker/Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/deployment/docker/Makefile b/deployment/docker/Makefile
index a4eceaa5c7..00b3956069 100644
--- a/deployment/docker/Makefile
+++ b/deployment/docker/Makefile
@@ -34,7 +34,7 @@ app-via-docker: package-builder
--env GO111MODULE=on \
$(DOCKER_OPTS) \
$(BUILDER_IMAGE) \
- go build $(RACE) -mod=vendor -trimpath \
+ go build $(RACE) -mod=vendor -trimpath -buildvcs=false \
-ldflags "-extldflags '-static' $(GO_BUILDINFO)" \
-tags 'netgo osusergo nethttpomithttp2 musl' \
-o bin/$(APP_NAME)$(APP_SUFFIX)-prod $(PKG_PREFIX)/app/$(APP_NAME)
@@ -50,7 +50,7 @@ app-via-docker-windows: package-builder
--env GO111MODULE=on \
$(DOCKER_OPTS) \
$(BUILDER_IMAGE) \
- go build $(RACE) -mod=vendor -trimpath \
+ go build $(RACE) -mod=vendor -trimpath -buildvcs=false \
-ldflags "-s -w -extldflags '-static' $(GO_BUILDINFO)" \
-tags 'netgo osusergo nethttpomithttp2' \
-o bin/$(APP_NAME)-windows$(APP_SUFFIX)-prod.exe $(PKG_PREFIX)/app/$(APP_NAME)
From 19f019d0d50ab8088837a4e50bc9bb4673394b80 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 14:11:03 +0300
Subject: [PATCH 14/51] lib/netutil: limit the number of concurrently
established connections when calling ConnPool.Get()
This should reduce potential spikes in the number of established connections in the following cases:
- when the connection establishing procedure becomes temporarily slow
- after a temporary spike in the rate of ConnPool.Get() calls
See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552
---
docs/CHANGELOG.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 7e919d26de..70cbdea066 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -18,6 +18,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
+* BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): limit the number of concurrently established connections from vmselect to vmstorage. This should prevent from potentially high spikes in the number of established connections after temporary slowdown in connection handshake procedure between vmselect and vmstorage because of spikes in workload. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552).
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
From 3f6a7bff8590aaead3cbab59e12b96ebd38656f8 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 14:30:10 +0300
Subject: [PATCH 15/51] docs/CHANGELOG.md: document
c8af625bcc05c24557ebcd145d5f813036915dea
See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146
---
docs/CHANGELOG.md | 1 +
go.mod | 4 ++++
2 files changed, 5 insertions(+)
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 70cbdea066..5dc1b3c4e5 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -19,6 +19,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
* BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): limit the number of concurrently established connections from vmselect to vmstorage. This should prevent from potentially high spikes in the number of established connections after temporary slowdown in connection handshake procedure between vmselect and vmstorage because of spikes in workload. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552).
+* BUGFIX: [vmctl](https://docs.victoriametrics.com/vmctl.html): fix build for Solaris / SmartOS. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146).
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
diff --git a/go.mod b/go.mod
index 38cafc8151..605aaa3fed 100644
--- a/go.mod
+++ b/go.mod
@@ -13,6 +13,10 @@ require (
github.com/VictoriaMetrics/metricsql v0.43.0
github.com/aws/aws-sdk-go v1.44.9
github.com/cespare/xxhash/v2 v2.1.2
+
+ // TODO: switch back to https://github.com/cheggaaa/pb/v3 when v3-pooling branch
+ // is merged into main branch.
+ // See https://github.com/cheggaaa/pb/pull/192#issuecomment-1121285954 for details.
github.com/dmitryk-dk/pb/v3 v3.0.9
github.com/golang/snappy v0.0.4
github.com/influxdata/influxdb v1.9.6
From b828c6e1ffcda2977e85cace4be110135df63c1b Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 18:05:05 +0300
Subject: [PATCH 16/51] docs/Cluster-VictoriaMetrics.md: typo fix: `by by` ->
`by`
---
docs/Cluster-VictoriaMetrics.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/Cluster-VictoriaMetrics.md b/docs/Cluster-VictoriaMetrics.md
index 61bed29c41..4051846bee 100644
--- a/docs/Cluster-VictoriaMetrics.md
+++ b/docs/Cluster-VictoriaMetrics.md
@@ -326,7 +326,7 @@ Some capacity planning tips for VictoriaMetrics cluster:
- The [replication](#replication-and-data-safety) increases the amounts of needed resources for the cluster by up to `N` times where `N` is replication factor. This is because `vminsert` stores `N` copies of every ingested sample on distinct `vmstorage` nodes. These copies are de-duplicated by `vmselect` during querying. The most cost-efficient and performant solution for data durability is to rely on replicated durable persistent disks such as [Google Compute persistent disks](https://cloud.google.com/compute/docs/disks#pdspecs) instead of using the [replication at VictoriaMetrics level](#replication-and-data-safety).
- It is recommended to run a cluster with big number of small `vmstorage` nodes instead of a cluster with small number of big `vmstorage` nodes. This increases chances that the cluster remains available and stable when some of `vmstorage` nodes are temporarily unavailable during maintenance events such as upgrades, configuration changes or migrations. For example, when a cluster contains 10 `vmstorage` nodes and a single node becomes temporarily unavailable, then the workload on the remaining 9 nodes increases by `1/9=11%`. When a cluster contains 3 `vmstorage` nodes and a single node becomes temporarily unavailable, then the workload on the remaining 2 nodes increases by `1/2=50%`. The remaining `vmstorage` nodes may have no enough free capacity for handling the increased workload. In this case the cluster may become overloaded, which may result to decreased availability and stability.
-- Cluster capacity for [active time series](https://docs.victoriametrics.com/FAQ.html#what-is-an-active-time-series) can be increased by increasing RAM and CPU resources per each `vmstorage` node or by by adding new `vmstorage` nodes.
+- Cluster capacity for [active time series](https://docs.victoriametrics.com/FAQ.html#what-is-an-active-time-series) can be increased by increasing RAM and CPU resources per each `vmstorage` node or by adding new `vmstorage` nodes.
- Query latency can be reduced by increasing CPU resources per each `vmselect` node, since each incoming query is processed by a single `vmselect` node. Performance for heavy queries scales with the number of available CPU cores at `vmselect` node, since `vmselect` processes time series referred by the query on all the available CPU cores.
- If the cluster needs to process incoming queries at a high rate, then its capacity can be increased by adding more `vmselect` nodes, so incoming queries could be spread among bigger number of `vmselect` nodes.
- By default `vminsert` compresses the data it sends to `vmstorage` in order to reduce network bandwidth usage. The compression takes additional CPU resources at `vminsert`. If `vminsert` nodes have limited CPU, then the compression can be disabled by passing `-rpc.disableCompression` command-line flag at `vminsert` nodes.
From 73cbc87dbbdbefc27baba99f187b548c44381fd1 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 19:52:03 +0300
Subject: [PATCH 17/51] docs: add `resource usage limits` docs, which describe
fine-grained tuning for various resource usage limits
---
README.md | 19 +++++++++++++++++++
docs/Cluster-VictoriaMetrics.md | 18 ++++++++++++++++++
docs/FAQ.md | 4 ++--
docs/README.md | 19 +++++++++++++++++++
docs/Single-server-VictoriaMetrics.md | 19 +++++++++++++++++++
5 files changed, 77 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 3e7455ef1d..045fe9aa7b 100644
--- a/README.md
+++ b/README.md
@@ -1055,6 +1055,25 @@ It is recommended leaving the following amounts of spare resources:
* 50% of spare CPU for reducing the probability of slowdowns during temporary spikes in workload.
* At least 30% of free storage space at the directory pointed by `-storageDataPath` command-line flag. See also `-storage.minFreeDiskSpaceBytes` command-line flag description [here](#list-of-command-line-flags).
+See also [resource usage limits docs](#resource-usage-limits).
+
+## Resource usage limits
+
+By default VictoriaMetrics is tuned for an optimal resource usage under typical workloads. Some workloads may need fine-grained resource usage limits. In these cases the following command-line flags may be useful:
+
+- `-memory.allowedPercent` and `-search.allowedBytes` limit the amounts of memory, which may be used for various internal caches at VictoriaMetrics. Note that VictoriaMetrics may use more memory, since these flags don't limit additional memory, which may be needed on a per-query basis.
+- `-search.maxUniqueTimeseries` limits the number of unique time series a single query can find and process. VictoriaMetrics keeps in memory some metainformation about the time series located by each query and spends some CPU time for processing the found time series. This means that the maximum memory usage and CPU usage a single query can use is proportional to `-search.maxUniqueTimeseries`.
+- `-search.maxQueryDuration` limits the duration of a single query. If the query takes longer than the given duration, then it is canceled. This allows saving CPU and RAM when executing unexpected heavy queries.
+- `-search.maxConcurrentRequests` limits the number of concurrent requests VictoriaMetrics can process. Bigger number of concurrent requests usually means bigger memory usage. For example, if a single query needs 100 MiB of additional memory during its execution, then 100 concurrent queries may need `100 * 100 MiB = 10 GiB` of additional memory. So it is better to limit the number of concurrent queries, while suspending additional incoming queries if the concurrency limit is reached. VictoriaMetrics provides `-search.maxQueueDuration` command-line flag for limiting the max wait time for suspended queries.
+- `-search.maxSamplesPerSeries` limits the number of raw samples the query can process per each time series. VictoriaMetrics sequentially processes raw samples per each found time series during the query. It unpacks raw samples on the selected time range per each time series into memory and then applies the given [rollup function](https://docs.victoriametrics.com/MetricsQL.html#rollup-functions). The `-search.maxSamplesPerSeries` command-line flag allows limiting memory usage in the case when the query is executed on a time range, which contains hundreds of millions of raw samples per each located time series.
+- `-search.maxSamplesPerQuery` limits the number of raw samples a single query can process. This allows limiting CPU usage for heavy queries.
+- `-search.maxSeries` limits the number of time series, which may be returned from [/api/v1/series](https://prometheus.io/docs/prometheus/latest/querying/api/#finding-series-by-label-matchers). This endpoint is used mostly by Grafana for auto-completion of metric names, label names and label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxSeries` to quite low value in order limit CPU and memory usage.
+- `-search.maxTagKeys` limits the number of items, which may be returned from [/api/v1/labels](https://prometheus.io/docs/prometheus/latest/querying/api/#getting-label-names). This endpoint is used mostly by Grafana for auto-completion of label names. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagKeys` to quite low value in order to limit CPU and memory usage.
+- `-search.maxTagValues` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
+
+See also [capacity planning docs](#capacity-planning).
+
+
## High availability
* Install multiple VictoriaMetrics instances in distinct datacenters (availability zones).
diff --git a/docs/Cluster-VictoriaMetrics.md b/docs/Cluster-VictoriaMetrics.md
index 4051846bee..4f8bff5d80 100644
--- a/docs/Cluster-VictoriaMetrics.md
+++ b/docs/Cluster-VictoriaMetrics.md
@@ -332,6 +332,24 @@ Some capacity planning tips for VictoriaMetrics cluster:
- By default `vminsert` compresses the data it sends to `vmstorage` in order to reduce network bandwidth usage. The compression takes additional CPU resources at `vminsert`. If `vminsert` nodes have limited CPU, then the compression can be disabled by passing `-rpc.disableCompression` command-line flag at `vminsert` nodes.
- By default `vmstorage` compresses the data it sends to `vmselect` during queries in order to reduce network bandwidth usage. The compression takes additional CPU resources at `vmstorage`. If `vmstorage` nodes have limited CPU, then the compression can be disabled by passing `-rpc.disableCompression` command-line flag at `vmstorage` nodes.
+See also [resource usage limits docs](#resource-usage-limits).
+
+## Resource usage limits
+
+By default cluster components of VictoriaMetrics are tuned for an optimal resource usage under typical workloads. Some workloads may need fine-grained resource usage limits. In these cases the following command-line flags may be useful:
+
+- `-memory.allowedPercent` and `-search.allowedBytes` limit the amounts of memory, which may be used for various internal caches at all the cluster components of VictoriaMetrics - `vminsert`, `vmselect` and `vmstorage`. Note that VictoriaMetrics components may use more memory, since these flags don't limit additional memory, which may be needed on a per-query basis.
+- `-search.maxUniqueTimeseries` at `vmselect` component limits the number of unique time series a single query can find and process. `vmselect` passes the limit to `vmstorage` component, which keeps in memory some metainformation about the time series located by each query and spends some CPU time for processing the found time series. This means that the maximum memory usage and CPU usage a single query can use at `vmstorage` is proportional to `-search.maxUniqueTimeseries`.
+- `-search.maxQueryDuration` at `vmselect` limits the duration of a single query. If the query takes longer than the given duration, then it is canceled. This allows saving CPU and RAM at `vmselect` and `vmstorage` when executing unexpected heavy queries.
+- `-search.maxConcurrentRequests` at `vmselect` limits the number of concurrent requests a single `vmselect` node can process. Bigger number of concurrent requests usually means bigger memory usage at both `vmselect` and `vmstorage`. For example, if a single query needs 100 MiB of additional memory during its execution, then 100 concurrent queries may need `100 * 100 MiB = 10 GiB` of additional memory. So it is better to limit the number of concurrent queries, while suspending additional incoming queries if the concurrency limit is reached. `vmselect` provides `-search.maxQueueDuration` command-line flag for limiting the max wait time for suspended queries.
+- `-search.maxSamplesPerSeries` at `vmselect` limits the number of raw samples the query can process per each time series. `vmselect` sequentially processes raw samples per each found time series during the query. It unpacks raw samples on the selected time range per each time series into memory and then applies the given [rollup function](https://docs.victoriametrics.com/MetricsQL.html#rollup-functions). The `-search.maxSamplesPerSeries` command-line flag allows limiting memory usage at `vmselect` in the case when the query is executed on a time range, which contains hundreds of millions of raw samples per each located time series.
+- `-search.maxSamplesPerQuery` at `vmselect` limits the number of raw samples a single query can process. This allows limiting CPU usage at `vmselect` for heavy queries.
+- `-search.maxSeries` at `vmselect` limits the number of time series, which may be returned from [/api/v1/series](https://prometheus.io/docs/prometheus/latest/querying/api/#finding-series-by-label-matchers). This endpoint is used mostly by Grafana for auto-completion of metric names, label names and label values. Queries to this endpoint may take big amounts of CPU time and memory at `vmstorage` and `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxSeries` to quite low value in order limit CPU and memory usage.
+- `-search.maxTagKeys` at `vmselect` limits the number of items, which may be returned from [/api/v1/labels](https://prometheus.io/docs/prometheus/latest/querying/api/#getting-label-names). This endpoint is used mostly by Grafana for auto-completion of label names. Queries to this endpoint may take big amounts of CPU time and memory at `vmstorage` and `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagKeys` to quite low value in order to limit CPU and memory usage.
+- `-search.maxTagValues` at `vmselect` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory at `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
+
+See also [capacity planning docs](#capacity-planning).
+
## High availability
The database is considered highly available if it continues accepting new data and processing incoming queries when some of its components are temporarily unavailable.
diff --git a/docs/FAQ.md b/docs/FAQ.md
index e47986560b..f7713f2b41 100644
--- a/docs/FAQ.md
+++ b/docs/FAQ.md
@@ -250,8 +250,8 @@ All the VictoriaMetrics components provide command-line flags to control the siz
Memory usage for VictoriaMetrics components can be tuned according to the following docs:
-* [Capacity planning for single-node VictoriaMetrics](https://docs.victoriametrics.com/#capacity-planning)
-* [Capacity planning for cluster VictoriaMetrics](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#capacity-planning)
+* [Resource usage limits for single-node VictoriaMetrics](https://docs.victoriametrics.com/#resource-usage-limits)
+* [Resource usage limits for cluster VictoriaMetrics](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#resource-usage-limits)
* [Troubleshooting for vmagent](https://docs.victoriametrics.com/vmagent.html#troubleshooting)
* [Troubleshooting for single-node VictoriaMetrics](https://docs.victoriametrics.com/#troubleshooting)
diff --git a/docs/README.md b/docs/README.md
index 3e7455ef1d..045fe9aa7b 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -1055,6 +1055,25 @@ It is recommended leaving the following amounts of spare resources:
* 50% of spare CPU for reducing the probability of slowdowns during temporary spikes in workload.
* At least 30% of free storage space at the directory pointed by `-storageDataPath` command-line flag. See also `-storage.minFreeDiskSpaceBytes` command-line flag description [here](#list-of-command-line-flags).
+See also [resource usage limits docs](#resource-usage-limits).
+
+## Resource usage limits
+
+By default VictoriaMetrics is tuned for an optimal resource usage under typical workloads. Some workloads may need fine-grained resource usage limits. In these cases the following command-line flags may be useful:
+
+- `-memory.allowedPercent` and `-search.allowedBytes` limit the amounts of memory, which may be used for various internal caches at VictoriaMetrics. Note that VictoriaMetrics may use more memory, since these flags don't limit additional memory, which may be needed on a per-query basis.
+- `-search.maxUniqueTimeseries` limits the number of unique time series a single query can find and process. VictoriaMetrics keeps in memory some metainformation about the time series located by each query and spends some CPU time for processing the found time series. This means that the maximum memory usage and CPU usage a single query can use is proportional to `-search.maxUniqueTimeseries`.
+- `-search.maxQueryDuration` limits the duration of a single query. If the query takes longer than the given duration, then it is canceled. This allows saving CPU and RAM when executing unexpected heavy queries.
+- `-search.maxConcurrentRequests` limits the number of concurrent requests VictoriaMetrics can process. Bigger number of concurrent requests usually means bigger memory usage. For example, if a single query needs 100 MiB of additional memory during its execution, then 100 concurrent queries may need `100 * 100 MiB = 10 GiB` of additional memory. So it is better to limit the number of concurrent queries, while suspending additional incoming queries if the concurrency limit is reached. VictoriaMetrics provides `-search.maxQueueDuration` command-line flag for limiting the max wait time for suspended queries.
+- `-search.maxSamplesPerSeries` limits the number of raw samples the query can process per each time series. VictoriaMetrics sequentially processes raw samples per each found time series during the query. It unpacks raw samples on the selected time range per each time series into memory and then applies the given [rollup function](https://docs.victoriametrics.com/MetricsQL.html#rollup-functions). The `-search.maxSamplesPerSeries` command-line flag allows limiting memory usage in the case when the query is executed on a time range, which contains hundreds of millions of raw samples per each located time series.
+- `-search.maxSamplesPerQuery` limits the number of raw samples a single query can process. This allows limiting CPU usage for heavy queries.
+- `-search.maxSeries` limits the number of time series, which may be returned from [/api/v1/series](https://prometheus.io/docs/prometheus/latest/querying/api/#finding-series-by-label-matchers). This endpoint is used mostly by Grafana for auto-completion of metric names, label names and label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxSeries` to quite low value in order limit CPU and memory usage.
+- `-search.maxTagKeys` limits the number of items, which may be returned from [/api/v1/labels](https://prometheus.io/docs/prometheus/latest/querying/api/#getting-label-names). This endpoint is used mostly by Grafana for auto-completion of label names. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagKeys` to quite low value in order to limit CPU and memory usage.
+- `-search.maxTagValues` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
+
+See also [capacity planning docs](#capacity-planning).
+
+
## High availability
* Install multiple VictoriaMetrics instances in distinct datacenters (availability zones).
diff --git a/docs/Single-server-VictoriaMetrics.md b/docs/Single-server-VictoriaMetrics.md
index a001b922bf..c718f5db36 100644
--- a/docs/Single-server-VictoriaMetrics.md
+++ b/docs/Single-server-VictoriaMetrics.md
@@ -1059,6 +1059,25 @@ It is recommended leaving the following amounts of spare resources:
* 50% of spare CPU for reducing the probability of slowdowns during temporary spikes in workload.
* At least 30% of free storage space at the directory pointed by `-storageDataPath` command-line flag. See also `-storage.minFreeDiskSpaceBytes` command-line flag description [here](#list-of-command-line-flags).
+See also [resource usage limits docs](#resource-usage-limits).
+
+## Resource usage limits
+
+By default VictoriaMetrics is tuned for an optimal resource usage under typical workloads. Some workloads may need fine-grained resource usage limits. In these cases the following command-line flags may be useful:
+
+- `-memory.allowedPercent` and `-search.allowedBytes` limit the amounts of memory, which may be used for various internal caches at VictoriaMetrics. Note that VictoriaMetrics may use more memory, since these flags don't limit additional memory, which may be needed on a per-query basis.
+- `-search.maxUniqueTimeseries` limits the number of unique time series a single query can find and process. VictoriaMetrics keeps in memory some metainformation about the time series located by each query and spends some CPU time for processing the found time series. This means that the maximum memory usage and CPU usage a single query can use is proportional to `-search.maxUniqueTimeseries`.
+- `-search.maxQueryDuration` limits the duration of a single query. If the query takes longer than the given duration, then it is canceled. This allows saving CPU and RAM when executing unexpected heavy queries.
+- `-search.maxConcurrentRequests` limits the number of concurrent requests VictoriaMetrics can process. Bigger number of concurrent requests usually means bigger memory usage. For example, if a single query needs 100 MiB of additional memory during its execution, then 100 concurrent queries may need `100 * 100 MiB = 10 GiB` of additional memory. So it is better to limit the number of concurrent queries, while suspending additional incoming queries if the concurrency limit is reached. VictoriaMetrics provides `-search.maxQueueDuration` command-line flag for limiting the max wait time for suspended queries.
+- `-search.maxSamplesPerSeries` limits the number of raw samples the query can process per each time series. VictoriaMetrics sequentially processes raw samples per each found time series during the query. It unpacks raw samples on the selected time range per each time series into memory and then applies the given [rollup function](https://docs.victoriametrics.com/MetricsQL.html#rollup-functions). The `-search.maxSamplesPerSeries` command-line flag allows limiting memory usage in the case when the query is executed on a time range, which contains hundreds of millions of raw samples per each located time series.
+- `-search.maxSamplesPerQuery` limits the number of raw samples a single query can process. This allows limiting CPU usage for heavy queries.
+- `-search.maxSeries` limits the number of time series, which may be returned from [/api/v1/series](https://prometheus.io/docs/prometheus/latest/querying/api/#finding-series-by-label-matchers). This endpoint is used mostly by Grafana for auto-completion of metric names, label names and label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxSeries` to quite low value in order limit CPU and memory usage.
+- `-search.maxTagKeys` limits the number of items, which may be returned from [/api/v1/labels](https://prometheus.io/docs/prometheus/latest/querying/api/#getting-label-names). This endpoint is used mostly by Grafana for auto-completion of label names. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagKeys` to quite low value in order to limit CPU and memory usage.
+- `-search.maxTagValues` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
+
+See also [capacity planning docs](#capacity-planning).
+
+
## High availability
* Install multiple VictoriaMetrics instances in distinct datacenters (availability zones).
From 7ddf9f07008bdb9675aa97f9ac06c2ec337b136c Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Wed, 11 May 2022 20:00:36 +0300
Subject: [PATCH 18/51] docs/Cluster-VictoriaMetrics.md: the
`/api/v1/label/.../values` query can take CPU and ram at both vmstorage and
vmselect
---
docs/Cluster-VictoriaMetrics.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/Cluster-VictoriaMetrics.md b/docs/Cluster-VictoriaMetrics.md
index 4f8bff5d80..cda1277a4e 100644
--- a/docs/Cluster-VictoriaMetrics.md
+++ b/docs/Cluster-VictoriaMetrics.md
@@ -346,7 +346,7 @@ By default cluster components of VictoriaMetrics are tuned for an optimal resour
- `-search.maxSamplesPerQuery` at `vmselect` limits the number of raw samples a single query can process. This allows limiting CPU usage at `vmselect` for heavy queries.
- `-search.maxSeries` at `vmselect` limits the number of time series, which may be returned from [/api/v1/series](https://prometheus.io/docs/prometheus/latest/querying/api/#finding-series-by-label-matchers). This endpoint is used mostly by Grafana for auto-completion of metric names, label names and label values. Queries to this endpoint may take big amounts of CPU time and memory at `vmstorage` and `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxSeries` to quite low value in order limit CPU and memory usage.
- `-search.maxTagKeys` at `vmselect` limits the number of items, which may be returned from [/api/v1/labels](https://prometheus.io/docs/prometheus/latest/querying/api/#getting-label-names). This endpoint is used mostly by Grafana for auto-completion of label names. Queries to this endpoint may take big amounts of CPU time and memory at `vmstorage` and `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagKeys` to quite low value in order to limit CPU and memory usage.
-- `-search.maxTagValues` at `vmselect` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory at `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
+- `-search.maxTagValues` at `vmselect` limits the number of items, which may be returned from [/api/v1/label/.../values](https://prometheus.io/docs/prometheus/latest/querying/api/#querying-label-values). This endpoint is used mostly by Grafana for auto-completion of label values. Queries to this endpoint may take big amounts of CPU time and memory at `vmstorage` and `vmselect` when the database contains big number of unique time series because of [high churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate). In this case it might be useful to set the `-search.maxTagValues` to quite low value in order to limit CPU and memory usage.
See also [capacity planning docs](#capacity-planning).
From a0727ab1b11bde58193c71dc54bc95e4629bf550 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Thu, 12 May 2022 18:50:29 +0300
Subject: [PATCH 19/51] docs/vmagent.md: typo fix in the description for
`-promscrape.cluster.replicationFactor` command-line flag
---
README.md | 2 +-
app/vmagent/README.md | 2 +-
docs/README.md | 2 +-
docs/Single-server-VictoriaMetrics.md | 2 +-
docs/vmagent.md | 2 +-
lib/promscrape/config.go | 2 +-
6 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index 045fe9aa7b..b2a61c22b2 100644
--- a/README.md
+++ b/README.md
@@ -1764,7 +1764,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-promscrape.cluster.membersCount int
The number of members in a cluster of scrapers. Each member must have an unique -promscrape.cluster.memberNum in the range 0 ... promscrape.cluster.membersCount-1 . Each member then scrapes roughly 1/N of all the targets. By default cluster scraping is disabled, i.e. a single scraper scrapes all the targets
-promscrape.cluster.replicationFactor int
- The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
+ The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
-promscrape.config string
Optional path to Prometheus config file with 'scrape_configs' section containing targets to scrape. The path can point to local file and to http url. See https://docs.victoriametrics.com/#how-to-scrape-prometheus-exporters-such-as-node-exporter for details
-promscrape.config.dryRun
diff --git a/app/vmagent/README.md b/app/vmagent/README.md
index 395e57beb7..55038b71f1 100644
--- a/app/vmagent/README.md
+++ b/app/vmagent/README.md
@@ -846,7 +846,7 @@ See the docs at https://docs.victoriametrics.com/vmagent.html .
-promscrape.cluster.membersCount int
The number of members in a cluster of scrapers. Each member must have an unique -promscrape.cluster.memberNum in the range 0 ... promscrape.cluster.membersCount-1 . Each member then scrapes roughly 1/N of all the targets. By default cluster scraping is disabled, i.e. a single scraper scrapes all the targets
-promscrape.cluster.replicationFactor int
- The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
+ The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
-promscrape.config string
Optional path to Prometheus config file with 'scrape_configs' section containing targets to scrape. The path can point to local file and to http url. See https://docs.victoriametrics.com/#how-to-scrape-prometheus-exporters-such-as-node-exporter for details
-promscrape.config.dryRun
diff --git a/docs/README.md b/docs/README.md
index 045fe9aa7b..b2a61c22b2 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -1764,7 +1764,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-promscrape.cluster.membersCount int
The number of members in a cluster of scrapers. Each member must have an unique -promscrape.cluster.memberNum in the range 0 ... promscrape.cluster.membersCount-1 . Each member then scrapes roughly 1/N of all the targets. By default cluster scraping is disabled, i.e. a single scraper scrapes all the targets
-promscrape.cluster.replicationFactor int
- The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
+ The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
-promscrape.config string
Optional path to Prometheus config file with 'scrape_configs' section containing targets to scrape. The path can point to local file and to http url. See https://docs.victoriametrics.com/#how-to-scrape-prometheus-exporters-such-as-node-exporter for details
-promscrape.config.dryRun
diff --git a/docs/Single-server-VictoriaMetrics.md b/docs/Single-server-VictoriaMetrics.md
index c718f5db36..1d356d5d1a 100644
--- a/docs/Single-server-VictoriaMetrics.md
+++ b/docs/Single-server-VictoriaMetrics.md
@@ -1768,7 +1768,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-promscrape.cluster.membersCount int
The number of members in a cluster of scrapers. Each member must have an unique -promscrape.cluster.memberNum in the range 0 ... promscrape.cluster.membersCount-1 . Each member then scrapes roughly 1/N of all the targets. By default cluster scraping is disabled, i.e. a single scraper scrapes all the targets
-promscrape.cluster.replicationFactor int
- The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
+ The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
-promscrape.config string
Optional path to Prometheus config file with 'scrape_configs' section containing targets to scrape. The path can point to local file and to http url. See https://docs.victoriametrics.com/#how-to-scrape-prometheus-exporters-such-as-node-exporter for details
-promscrape.config.dryRun
diff --git a/docs/vmagent.md b/docs/vmagent.md
index b5931fb036..21deb827da 100644
--- a/docs/vmagent.md
+++ b/docs/vmagent.md
@@ -850,7 +850,7 @@ See the docs at https://docs.victoriametrics.com/vmagent.html .
-promscrape.cluster.membersCount int
The number of members in a cluster of scrapers. Each member must have an unique -promscrape.cluster.memberNum in the range 0 ... promscrape.cluster.membersCount-1 . Each member then scrapes roughly 1/N of all the targets. By default cluster scraping is disabled, i.e. a single scraper scrapes all the targets
-promscrape.cluster.replicationFactor int
- The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
+ The number of members in the cluster, which scrape the same targets. If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication (default 1)
-promscrape.config string
Optional path to Prometheus config file with 'scrape_configs' section containing targets to scrape. The path can point to local file and to http url. See https://docs.victoriametrics.com/#how-to-scrape-prometheus-exporters-such-as-node-exporter for details
-promscrape.config.dryRun
diff --git a/lib/promscrape/config.go b/lib/promscrape/config.go
index 55385a64e6..bea401b873 100644
--- a/lib/promscrape/config.go
+++ b/lib/promscrape/config.go
@@ -55,7 +55,7 @@ var (
"It must be an unique value in the range 0 ... promscrape.cluster.membersCount-1 across scrapers in the cluster. "+
"Can be specified as pod name of Kubernetes StatefulSet - pod-name-Num, where Num is a numeric part of pod name")
clusterReplicationFactor = flag.Int("promscrape.cluster.replicationFactor", 1, "The number of members in the cluster, which scrape the same targets. "+
- "If the replication factor is greater than 2, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication")
+ "If the replication factor is greater than 1, then the deduplication must be enabled at remote storage side. See https://docs.victoriametrics.com/#deduplication")
)
var clusterMemberID int
From 20cef877a116701f930b29addaa3d5d712b064d7 Mon Sep 17 00:00:00 2001
From: Yurii Kravets <30324382+YuriKravetc@users.noreply.github.com>
Date: Thu, 12 May 2022 20:22:13 +0300
Subject: [PATCH 20/51] Update docs (#2566)
* deployment/docker: pass `-buildvs=false` to `go build` for production builds
This should resolve the `error obtaining VCS status: exit status 128` error
when the environment contains incorrect version of git or has incorrect access rights
to the directory with VictoriaMetrics source code.
See the following links for additional info:
- https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2508#issuecomment-1117126702 ,
- https://github.com/google/ko/issues/672
- https://github.com/golang/go/issues/49004
* lib/netutil: limit the number of concurrently established connections when calling ConnPool.Get()
This should reduce potential spikes in the number of established connections in the following cases:
- when the connection establishing procedure becomes temporarily slow
- after a temporary spike in the rate of ConnPool.Get() calls
See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552
* docs/CHANGELOG.md: document c8af625bcc05c24557ebcd145d5f813036915dea
See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146
* docs/Cluster-VictoriaMetrics.md: typo fix: `by by` -> `by`
* docs: add `resource usage limits` docs, which describe fine-grained tuning for various resource usage limits
* docs/Cluster-VictoriaMetrics.md: the `/api/v1/label/.../values` query can take CPU and ram at both vmstorage and vmselect
* Update root Readme and root vmagent readme
Co-authored-by: Aliaksandr Valialkin
---
README.md | 2 +-
app/vmagent/README.md | 2 +-
docs/Cluster-VictoriaMetrics.md | 2 +-
docs/README.md | 2 +-
docs/Single-server-VictoriaMetrics.md | 2 +-
docs/vmagent.md | 2 +-
6 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/README.md b/README.md
index b2a61c22b2..37c14ea022 100644
--- a/README.md
+++ b/README.md
@@ -1701,7 +1701,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
diff --git a/app/vmagent/README.md b/app/vmagent/README.md
index 55038b71f1..7bc2bbb6f8 100644
--- a/app/vmagent/README.md
+++ b/app/vmagent/README.md
@@ -765,7 +765,7 @@ See the docs at https://docs.victoriametrics.com/vmagent.html .
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8429/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8429/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
diff --git a/docs/Cluster-VictoriaMetrics.md b/docs/Cluster-VictoriaMetrics.md
index cda1277a4e..167deff951 100644
--- a/docs/Cluster-VictoriaMetrics.md
+++ b/docs/Cluster-VictoriaMetrics.md
@@ -563,7 +563,7 @@ Below is the output for `/path/to/vminsert -help`:
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
diff --git a/docs/README.md b/docs/README.md
index b2a61c22b2..37c14ea022 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -1701,7 +1701,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
diff --git a/docs/Single-server-VictoriaMetrics.md b/docs/Single-server-VictoriaMetrics.md
index 1d356d5d1a..d6ab05e44c 100644
--- a/docs/Single-server-VictoriaMetrics.md
+++ b/docs/Single-server-VictoriaMetrics.md
@@ -1705,7 +1705,7 @@ Pass `-help` to VictoriaMetrics in order to see the list of supported command-li
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
diff --git a/docs/vmagent.md b/docs/vmagent.md
index 21deb827da..395d5a5330 100644
--- a/docs/vmagent.md
+++ b/docs/vmagent.md
@@ -769,7 +769,7 @@ See the docs at https://docs.victoriametrics.com/vmagent.html .
-influxDBLabel string
Default label for the DB name sent over '?db={db_name}' query parameter (default "db")
-influxListenAddr string
- TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8429/write
+ TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. This flag isn't needed when ingesting data over HTTP - just send it to http://:8429/write
-influxMeasurementFieldSeparator string
Separator for '{measurement}{separator}{field_name}' metric name when inserted via InfluxDB line protocol (default "_")
-influxSkipMeasurement
From 071f7c24d4acac8b90c75b19440a3a328a97dbfe Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Fri, 13 May 2022 09:55:27 +0200
Subject: [PATCH 21/51] vmctl: make linter happy (#2578)
Signed-off-by: hagen1778
---
app/vmctl/opentsdb.go | 2 +-
app/vmctl/opentsdb/opentsdb.go | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/app/vmctl/opentsdb.go b/app/vmctl/opentsdb.go
index b54f7fd8a0..fdbb7d9c37 100644
--- a/app/vmctl/opentsdb.go
+++ b/app/vmctl/opentsdb.go
@@ -67,7 +67,7 @@ func (op *otsdbProcessor) run(silent, verbose bool) error {
queryRanges += len(rt.QueryRanges)
}
for _, metric := range metrics {
- log.Println(fmt.Sprintf("Starting work on %s", metric))
+ log.Printf("Starting work on %s", metric)
serieslist, err := op.oc.FindSeries(metric)
if err != nil {
return fmt.Errorf("couldn't retrieve series list for %s : %s", metric, err)
diff --git a/app/vmctl/opentsdb/opentsdb.go b/app/vmctl/opentsdb/opentsdb.go
index df446fc437..f6700eb8a6 100644
--- a/app/vmctl/opentsdb/opentsdb.go
+++ b/app/vmctl/opentsdb/opentsdb.go
@@ -196,7 +196,7 @@ func (c Client) GetData(series Meta, rt RetentionMeta, start int64, end int64, m
3. bad format of response body
*/
if resp.StatusCode != 200 {
- log.Println(fmt.Sprintf("bad response code from OpenTSDB query %v for %q...skipping", resp.StatusCode, q))
+ log.Printf("bad response code from OpenTSDB query %v for %q...skipping", resp.StatusCode, q)
return Metric{}, nil
}
defer func() { _ = resp.Body.Close() }()
@@ -208,7 +208,7 @@ func (c Client) GetData(series Meta, rt RetentionMeta, start int64, end int64, m
var output []OtsdbMetric
err = json.Unmarshal(body, &output)
if err != nil {
- log.Println(fmt.Sprintf("couldn't marshall response body from OpenTSDB query (%s)...skipping", body))
+ log.Printf("couldn't marshall response body from OpenTSDB query (%s)...skipping", body)
return Metric{}, nil
}
/*
@@ -309,7 +309,7 @@ func NewClient(cfg Config) (*Client, error) {
*/
offsetPrint = offsetPrint - offsetSecs
}
- log.Println(fmt.Sprintf("Will collect data starting at TS %v", offsetPrint))
+ log.Printf("Will collect data starting at TS %v", offsetPrint)
for _, r := range cfg.Retentions {
ret, err := convertRetention(r, offsetSecs, cfg.MsecsTime)
if err != nil {
From 3f0ecee12882d476dbfa03ddae81ef075e9254a4 Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Fri, 13 May 2022 10:04:49 +0200
Subject: [PATCH 22/51] vmalert: properly cleanup stale series tracker on rules
update (#2577)
Rules executor within group tracks series sent to remote write
in order to mark them as stale if they had disappeared in next
evaluation round.
The executor uses rules ID as a key to identifies series which belong to rule.
On config reload, executor remains active but the set of rules could change.
Hence, we need to properly cleanup the tracker for rules which has been disappeared
on config reload.
Signed-off-by: hagen1778
---
app/vmalert/group.go | 28 +++++++++++++++++++
app/vmalert/group_test.go | 58 +++++++++++++++++++++++++++++++++++++++
2 files changed, 86 insertions(+)
diff --git a/app/vmalert/group.go b/app/vmalert/group.go
index d89f5037c3..3009a76507 100644
--- a/app/vmalert/group.go
+++ b/app/vmalert/group.go
@@ -303,6 +303,10 @@ func (g *Group) start(ctx context.Context, nts func() []notifier.Notifier, rw *r
g.mu.Unlock()
continue
}
+
+ // ensure that staleness is tracked or existing rules only
+ e.purgeStaleSeries(g.Rules)
+
if g.Interval != ng.Interval {
g.Interval = ng.Interval
t.Stop()
@@ -457,6 +461,30 @@ func (e *executor) getStaleSeries(rule Rule, tss []prompbmarshal.TimeSeries, tim
return staleS
}
+// purgeStaleSeries deletes references in tracked
+// previouslySentSeriesToRW list to Rules which aren't present
+// in the given activeRules list. The method is used when the list
+// of loaded rules has changed and executor has to remove
+// references to non-existing rules.
+func (e *executor) purgeStaleSeries(activeRules []Rule) {
+ newPreviouslySentSeriesToRW := make(map[uint64]map[string][]prompbmarshal.Label)
+
+ e.previouslySentSeriesToRWMu.Lock()
+
+ for _, rule := range activeRules {
+ id := rule.ID()
+ prev, ok := e.previouslySentSeriesToRW[id]
+ if ok {
+ // keep previous series for staleness detection
+ newPreviouslySentSeriesToRW[id] = prev
+ }
+ }
+ e.previouslySentSeriesToRW = nil
+ e.previouslySentSeriesToRW = newPreviouslySentSeriesToRW
+
+ e.previouslySentSeriesToRWMu.Unlock()
+}
+
func labelsToString(labels []prompbmarshal.Label) string {
var b strings.Builder
b.WriteRune('{')
diff --git a/app/vmalert/group_test.go b/app/vmalert/group_test.go
index 8322e65d02..ab2cfe9511 100644
--- a/app/vmalert/group_test.go
+++ b/app/vmalert/group_test.go
@@ -355,3 +355,61 @@ func TestGetStaleSeries(t *testing.T) {
[][]prompbmarshal.Label{toPromLabels(t, "__name__", "job:foo", "job", "bar")},
nil)
}
+
+func TestPurgeStaleSeries(t *testing.T) {
+ ts := time.Now()
+ labels := toPromLabels(t, "__name__", "job:foo", "job", "foo")
+ tss := []prompbmarshal.TimeSeries{newTimeSeriesPB([]float64{1}, []int64{ts.Unix()}, labels)}
+
+ f := func(curRules, newRules, expStaleRules []Rule) {
+ t.Helper()
+ e := &executor{
+ previouslySentSeriesToRW: make(map[uint64]map[string][]prompbmarshal.Label),
+ }
+ // seed executor with series for
+ // current rules
+ for _, rule := range curRules {
+ e.getStaleSeries(rule, tss, ts)
+ }
+
+ e.purgeStaleSeries(newRules)
+
+ if len(e.previouslySentSeriesToRW) != len(expStaleRules) {
+ t.Fatalf("expected to get %d stale series, got %d",
+ len(expStaleRules), len(e.previouslySentSeriesToRW))
+ }
+
+ for _, exp := range expStaleRules {
+ if _, ok := e.previouslySentSeriesToRW[exp.ID()]; !ok {
+ t.Fatalf("expected to have rule %d; got nil instead", exp.ID())
+ }
+ }
+ }
+
+ f(nil, nil, nil)
+ f(
+ nil,
+ []Rule{&AlertingRule{RuleID: 1}},
+ nil,
+ )
+ f(
+ []Rule{&AlertingRule{RuleID: 1}},
+ nil,
+ nil,
+ )
+ f(
+ []Rule{&AlertingRule{RuleID: 1}},
+ []Rule{&AlertingRule{RuleID: 2}},
+ nil,
+ )
+ f(
+ []Rule{&AlertingRule{RuleID: 1}, &AlertingRule{RuleID: 2}},
+ []Rule{&AlertingRule{RuleID: 2}},
+ []Rule{&AlertingRule{RuleID: 2}},
+ )
+ f(
+ []Rule{&AlertingRule{RuleID: 1}, &AlertingRule{RuleID: 2}},
+ []Rule{&AlertingRule{RuleID: 1}, &AlertingRule{RuleID: 2}},
+ []Rule{&AlertingRule{RuleID: 1}, &AlertingRule{RuleID: 2}},
+ )
+}
From b68f0fe7419485dde556b02ea487b9f0a46f119b Mon Sep 17 00:00:00 2001
From: Denys Holius <5650611+denisgolius@users.noreply.github.com>
Date: Fri, 13 May 2022 15:07:23 +0300
Subject: [PATCH 23/51] Update golangci version to latest v1.46.1 (#2579)
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index 25d397b7da..45fc269f74 100644
--- a/Makefile
+++ b/Makefile
@@ -283,7 +283,7 @@ golangci-lint: install-golangci-lint
golangci-lint run --exclude '(SA4003|SA1019|SA5011):' -D errcheck -D structcheck --timeout 2m
install-golangci-lint:
- which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.46.0
+ which golangci-lint || curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.46.1
install-wwhrd:
which wwhrd || GO111MODULE=off go get github.com/frapposelli/wwhrd
From c448d2fcbb626a43f7c2fd4f2e0d9666e134751b Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Fri, 13 May 2022 16:19:32 +0300
Subject: [PATCH 24/51] app/vmalert: apply `-remoteRead.disablePathAppend` to
`-datasource.url` in the same way as for the `-remoteRead.url`
This is a follow-up for 0e2486df5631d8c8ed8dab51de070dc8c3c2ab33
The related pull requests:
- https://github.com/VictoriaMetrics/VictoriaMetrics/pull/1536
- https://github.com/VictoriaMetrics/VictoriaMetrics/pull/1712
---
app/vmalert/datasource/init.go | 2 +-
app/vmalert/datasource/vm.go | 33 +++++++--------
app/vmalert/datasource/vm_prom_api.go | 24 +++++------
app/vmalert/datasource/vm_test.go | 58 +++-----------------------
app/vmalert/remoteread/init.go | 4 +-
app/vmalert/remotewrite/init.go | 2 -
app/vmalert/remotewrite/remotewrite.go | 41 +++++++++---------
docs/CHANGELOG.md | 1 +
8 files changed, 57 insertions(+), 108 deletions(-)
diff --git a/app/vmalert/datasource/init.go b/app/vmalert/datasource/init.go
index 891e7f991e..d18dad2208 100644
--- a/app/vmalert/datasource/init.go
+++ b/app/vmalert/datasource/init.go
@@ -12,7 +12,7 @@ import (
var (
addr = flag.String("datasource.url", "", "VictoriaMetrics or vmselect url. Required parameter. "+
- "E.g. http://127.0.0.1:8428")
+ "E.g. http://127.0.0.1:8428 . See also -remoteRead.disablePathAppend")
appendTypePrefix = flag.Bool("datasource.appendTypePrefix", false, "Whether to add type prefix to -datasource.url based on the query type. Set to true if sending different query types to the vmselect URL.")
basicAuthUsername = flag.String("datasource.basicAuth.username", "", "Optional basic auth username for -datasource.url")
diff --git a/app/vmalert/datasource/vm.go b/app/vmalert/datasource/vm.go
index 73d16fd8ad..0b60bbcde9 100644
--- a/app/vmalert/datasource/vm.go
+++ b/app/vmalert/datasource/vm.go
@@ -24,20 +24,18 @@ type VMStorage struct {
dataSourceType Type
evaluationInterval time.Duration
extraParams url.Values
- disablePathAppend bool
}
// Clone makes clone of VMStorage, shares http client.
func (s *VMStorage) Clone() *VMStorage {
return &VMStorage{
- c: s.c,
- authCfg: s.authCfg,
- datasourceURL: s.datasourceURL,
- lookBack: s.lookBack,
- queryStep: s.queryStep,
- appendTypePrefix: s.appendTypePrefix,
- dataSourceType: s.dataSourceType,
- disablePathAppend: s.disablePathAppend,
+ c: s.c,
+ authCfg: s.authCfg,
+ datasourceURL: s.datasourceURL,
+ lookBack: s.lookBack,
+ queryStep: s.queryStep,
+ appendTypePrefix: s.appendTypePrefix,
+ dataSourceType: s.dataSourceType,
}
}
@@ -57,16 +55,15 @@ func (s *VMStorage) BuildWithParams(params QuerierParams) Querier {
}
// NewVMStorage is a constructor for VMStorage
-func NewVMStorage(baseURL string, authCfg *promauth.Config, lookBack time.Duration, queryStep time.Duration, appendTypePrefix bool, c *http.Client, disablePathAppend bool) *VMStorage {
+func NewVMStorage(baseURL string, authCfg *promauth.Config, lookBack time.Duration, queryStep time.Duration, appendTypePrefix bool, c *http.Client) *VMStorage {
return &VMStorage{
- c: c,
- authCfg: authCfg,
- datasourceURL: strings.TrimSuffix(baseURL, "/"),
- appendTypePrefix: appendTypePrefix,
- lookBack: lookBack,
- queryStep: queryStep,
- dataSourceType: NewPrometheusType(),
- disablePathAppend: disablePathAppend,
+ c: c,
+ authCfg: authCfg,
+ datasourceURL: strings.TrimSuffix(baseURL, "/"),
+ appendTypePrefix: appendTypePrefix,
+ lookBack: lookBack,
+ queryStep: queryStep,
+ dataSourceType: NewPrometheusType(),
}
}
diff --git a/app/vmalert/datasource/vm_prom_api.go b/app/vmalert/datasource/vm_prom_api.go
index 5411fa1813..6b72efca86 100644
--- a/app/vmalert/datasource/vm_prom_api.go
+++ b/app/vmalert/datasource/vm_prom_api.go
@@ -2,12 +2,18 @@ package datasource
import (
"encoding/json"
+ "flag"
"fmt"
"net/http"
"strconv"
"time"
)
+var (
+ disablePathAppend = flag.Bool("remoteRead.disablePathAppend", false, "Whether to disable automatic appending of '/api/v1/query' path "+
+ "to the configured -datasource.url and -remoteRead.url")
+)
+
type promResponse struct {
Status string `json:"status"`
ErrorType string `json:"errorType"`
@@ -108,18 +114,12 @@ func parsePrometheusResponse(req *http.Request, resp *http.Response) ([]Metric,
}
}
-const (
- prometheusInstantPath = "/api/v1/query"
- prometheusRangePath = "/api/v1/query_range"
- prometheusPrefix = "/prometheus"
-)
-
func (s *VMStorage) setPrometheusInstantReqParams(r *http.Request, query string, timestamp time.Time) {
if s.appendTypePrefix {
- r.URL.Path += prometheusPrefix
+ r.URL.Path += "/prometheus"
}
- if !s.disablePathAppend {
- r.URL.Path += prometheusInstantPath
+ if !*disablePathAppend {
+ r.URL.Path += "/api/v1/query"
}
q := r.URL.Query()
if s.lookBack > 0 {
@@ -136,10 +136,10 @@ func (s *VMStorage) setPrometheusInstantReqParams(r *http.Request, query string,
func (s *VMStorage) setPrometheusRangeReqParams(r *http.Request, query string, start, end time.Time) {
if s.appendTypePrefix {
- r.URL.Path += prometheusPrefix
+ r.URL.Path += "/prometheus"
}
- if !s.disablePathAppend {
- r.URL.Path += prometheusRangePath
+ if !*disablePathAppend {
+ r.URL.Path += "/api/v1/query_range"
}
q := r.URL.Query()
q.Add("start", fmt.Sprintf("%d", start.Unix()))
diff --git a/app/vmalert/datasource/vm_test.go b/app/vmalert/datasource/vm_test.go
index f15bf57403..09bf4fe044 100644
--- a/app/vmalert/datasource/vm_test.go
+++ b/app/vmalert/datasource/vm_test.go
@@ -85,7 +85,7 @@ func TestVMInstantQuery(t *testing.T) {
if err != nil {
t.Fatalf("unexpected: %s", err)
}
- s := NewVMStorage(srv.URL, authCfg, time.Minute, 0, false, srv.Client(), false)
+ s := NewVMStorage(srv.URL, authCfg, time.Minute, 0, false, srv.Client())
p := NewPrometheusType()
pq := s.BuildWithParams(QuerierParams{DataSourceType: &p, EvaluationInterval: 15 * time.Second})
@@ -196,7 +196,7 @@ func TestVMRangeQuery(t *testing.T) {
if err != nil {
t.Fatalf("unexpected: %s", err)
}
- s := NewVMStorage(srv.URL, authCfg, time.Minute, 0, false, srv.Client(), false)
+ s := NewVMStorage(srv.URL, authCfg, time.Minute, 0, false, srv.Client())
p := NewPrometheusType()
pq := s.BuildWithParams(QuerierParams{DataSourceType: &p, EvaluationInterval: 15 * time.Second})
@@ -252,18 +252,7 @@ func TestRequestParams(t *testing.T) {
dataSourceType: NewPrometheusType(),
},
func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusInstantPath, r.URL.Path)
- },
- },
- {
- "prometheus path with disablePathAppend",
- false,
- &VMStorage{
- dataSourceType: NewPrometheusType(),
- disablePathAppend: true,
- },
- func(t *testing.T, r *http.Request) {
- checkEqualString(t, "", r.URL.Path)
+ checkEqualString(t, "/api/v1/query", r.URL.Path)
},
},
{
@@ -274,19 +263,7 @@ func TestRequestParams(t *testing.T) {
appendTypePrefix: true,
},
func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusPrefix+prometheusInstantPath, r.URL.Path)
- },
- },
- {
- "prometheus prefix with disablePathAppend",
- false,
- &VMStorage{
- dataSourceType: NewPrometheusType(),
- appendTypePrefix: true,
- disablePathAppend: true,
- },
- func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusPrefix, r.URL.Path)
+ checkEqualString(t, "/prometheus/api/v1/query", r.URL.Path)
},
},
{
@@ -296,18 +273,7 @@ func TestRequestParams(t *testing.T) {
dataSourceType: NewPrometheusType(),
},
func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusRangePath, r.URL.Path)
- },
- },
- {
- "prometheus range path with disablePathAppend",
- true,
- &VMStorage{
- dataSourceType: NewPrometheusType(),
- disablePathAppend: true,
- },
- func(t *testing.T, r *http.Request) {
- checkEqualString(t, "", r.URL.Path)
+ checkEqualString(t, "/api/v1/query_range", r.URL.Path)
},
},
{
@@ -318,19 +284,7 @@ func TestRequestParams(t *testing.T) {
appendTypePrefix: true,
},
func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusPrefix+prometheusRangePath, r.URL.Path)
- },
- },
- {
- "prometheus range prefix with disablePathAppend",
- true,
- &VMStorage{
- dataSourceType: NewPrometheusType(),
- appendTypePrefix: true,
- disablePathAppend: true,
- },
- func(t *testing.T, r *http.Request) {
- checkEqualString(t, prometheusPrefix, r.URL.Path)
+ checkEqualString(t, "/prometheus/api/v1/query_range", r.URL.Path)
},
},
{
diff --git a/app/vmalert/remoteread/init.go b/app/vmalert/remoteread/init.go
index d5f9e0a4a4..1b765e1244 100644
--- a/app/vmalert/remoteread/init.go
+++ b/app/vmalert/remoteread/init.go
@@ -34,8 +34,6 @@ var (
oauth2ClientSecretFile = flag.String("remoteRead.oauth2.clientSecretFile", "", "Optional OAuth2 clientSecretFile to use for -remoteRead.url.")
oauth2TokenURL = flag.String("remoteRead.oauth2.tokenUrl", "", "Optional OAuth2 tokenURL to use for -remoteRead.url. ")
oauth2Scopes = flag.String("remoteRead.oauth2.scopes", "", "Optional OAuth2 scopes to use for -remoteRead.url. Scopes must be delimited by ';'.")
-
- disablePathAppend = flag.Bool("remoteRead.disablePathAppend", false, "Whether to disable automatic appending of '/api/v1/query' path to the configured -remoteRead.url.")
)
// Init creates a Querier from provided flag values.
@@ -57,5 +55,5 @@ func Init() (datasource.QuerierBuilder, error) {
return nil, fmt.Errorf("failed to configure auth: %w", err)
}
c := &http.Client{Transport: tr}
- return datasource.NewVMStorage(*addr, authCfg, 0, 0, false, c, *disablePathAppend), nil
+ return datasource.NewVMStorage(*addr, authCfg, 0, 0, false, c), nil
}
diff --git a/app/vmalert/remotewrite/init.go b/app/vmalert/remotewrite/init.go
index 1f927f8a96..de5c0abdbd 100644
--- a/app/vmalert/remotewrite/init.go
+++ b/app/vmalert/remotewrite/init.go
@@ -39,8 +39,6 @@ var (
oauth2ClientSecretFile = flag.String("remoteWrite.oauth2.clientSecretFile", "", "Optional OAuth2 clientSecretFile to use for -remoteWrite.url.")
oauth2TokenURL = flag.String("remoteWrite.oauth2.tokenUrl", "", "Optional OAuth2 tokenURL to use for -notifier.url.")
oauth2Scopes = flag.String("remoteWrite.oauth2.scopes", "", "Optional OAuth2 scopes to use for -notifier.url. Scopes must be delimited by ';'.")
-
- disablePathAppend = flag.Bool("remoteWrite.disablePathAppend", false, "Whether to disable automatic appending of '/api/v1/write' path to the configured -remoteWrite.url.")
)
// Init creates Client object from given flags.
diff --git a/app/vmalert/remotewrite/remotewrite.go b/app/vmalert/remotewrite/remotewrite.go
index 35fa56ebdf..992cea22bf 100644
--- a/app/vmalert/remotewrite/remotewrite.go
+++ b/app/vmalert/remotewrite/remotewrite.go
@@ -3,6 +3,7 @@ package remotewrite
import (
"bytes"
"context"
+ "flag"
"fmt"
"io/ioutil"
"net/http"
@@ -19,17 +20,20 @@ import (
"github.com/VictoriaMetrics/metrics"
)
+var (
+ disablePathAppend = flag.Bool("remoteWrite.disablePathAppend", false, "Whether to disable automatic appending of '/api/v1/write' path to the configured -remoteWrite.url.")
+)
+
// Client is an asynchronous HTTP client for writing
// timeseries via remote write protocol.
type Client struct {
- addr string
- c *http.Client
- authCfg *promauth.Config
- input chan prompbmarshal.TimeSeries
- flushInterval time.Duration
- maxBatchSize int
- maxQueueSize int
- disablePathAppend bool
+ addr string
+ c *http.Client
+ authCfg *promauth.Config
+ input chan prompbmarshal.TimeSeries
+ flushInterval time.Duration
+ maxBatchSize int
+ maxQueueSize int
wg sync.WaitGroup
doneCh chan struct{}
@@ -70,8 +74,6 @@ const (
defaultWriteTimeout = 30 * time.Second
)
-const writePath = "/api/v1/write"
-
// NewClient returns asynchronous client for
// writing timeseries via remotewrite protocol.
func NewClient(ctx context.Context, cfg Config) (*Client, error) {
@@ -102,14 +104,13 @@ func NewClient(ctx context.Context, cfg Config) (*Client, error) {
Timeout: cfg.WriteTimeout,
Transport: cfg.Transport,
},
- addr: strings.TrimSuffix(cfg.Addr, "/"),
- authCfg: cfg.AuthCfg,
- flushInterval: cfg.FlushInterval,
- maxBatchSize: cfg.MaxBatchSize,
- maxQueueSize: cfg.MaxQueueSize,
- doneCh: make(chan struct{}),
- input: make(chan prompbmarshal.TimeSeries, cfg.MaxQueueSize),
- disablePathAppend: cfg.DisablePathAppend,
+ addr: strings.TrimSuffix(cfg.Addr, "/"),
+ authCfg: cfg.AuthCfg,
+ flushInterval: cfg.FlushInterval,
+ maxBatchSize: cfg.MaxBatchSize,
+ maxQueueSize: cfg.MaxQueueSize,
+ doneCh: make(chan struct{}),
+ input: make(chan prompbmarshal.TimeSeries, cfg.MaxQueueSize),
}
for i := 0; i < cc; i++ {
@@ -240,8 +241,8 @@ func (c *Client) send(ctx context.Context, data []byte) error {
req.Header.Set("Authorization", auth)
}
}
- if !c.disablePathAppend {
- req.URL.Path = path.Join(req.URL.Path, writePath)
+ if !*disablePathAppend {
+ req.URL.Path = path.Join(req.URL.Path, "/api/v1/write")
}
resp, err := c.c.Do(req.WithContext(ctx))
if err != nil {
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 5dc1b3c4e5..c5ed9a965b 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -20,6 +20,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
* BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): limit the number of concurrently established connections from vmselect to vmstorage. This should prevent from potentially high spikes in the number of established connections after temporary slowdown in connection handshake procedure between vmselect and vmstorage because of spikes in workload. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552).
* BUGFIX: [vmctl](https://docs.victoriametrics.com/vmctl.html): fix build for Solaris / SmartOS. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146).
+* BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): do not add `/api/v1/query` suffix to `-datasource.url` if `-remoteRead.disablePathAppend` command-line flag is set. Previously this flag was applied only to `-remoteRead.url`, which could confuse users.
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
From ce47d1805285b3522dd8f3206ef4037e1d033ef5 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Fri, 13 May 2022 16:49:22 +0300
Subject: [PATCH 25/51] app/{vmagent,vminsert}: mention port 8089 instead of
8189 in the description for -influxListenAddr flag
InfluxDB uses 8089 port for sending plain Influx line protocol data over TCP and UDP.
See https://docs.influxdata.com/influxdb/v1.8/administration/ports/
This is a follow-up for 20cef877a116701f930b29addaa3d5d712b064d7
---
app/vmagent/main.go | 2 +-
app/vminsert/main.go | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/app/vmagent/main.go b/app/vmagent/main.go
index 384de4c116..30b70de00a 100644
--- a/app/vmagent/main.go
+++ b/app/vmagent/main.go
@@ -43,7 +43,7 @@ var (
httpListenAddr = flag.String("httpListenAddr", ":8429", "TCP address to listen for http connections. "+
"Set this flag to empty value in order to disable listening on any port. This mode may be useful for running multiple vmagent instances on the same server. "+
"Note that /targets and /metrics pages aren't available if -httpListenAddr=''")
- influxListenAddr = flag.String("influxListenAddr", "", "TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. "+
+ influxListenAddr = flag.String("influxListenAddr", "", "TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. "+
"This flag isn't needed when ingesting data over HTTP - just send it to http://:8429/write")
graphiteListenAddr = flag.String("graphiteListenAddr", "", "TCP and UDP address to listen for Graphite plaintext data. Usually :2003 must be set. Doesn't work if empty")
opentsdbListenAddr = flag.String("opentsdbListenAddr", "", "TCP and UDP address to listen for OpentTSDB metrics. "+
diff --git a/app/vminsert/main.go b/app/vminsert/main.go
index 1302545cc9..0e1bb10336 100644
--- a/app/vminsert/main.go
+++ b/app/vminsert/main.go
@@ -36,7 +36,7 @@ import (
var (
graphiteListenAddr = flag.String("graphiteListenAddr", "", "TCP and UDP address to listen for Graphite plaintext data. Usually :2003 must be set. Doesn't work if empty")
- influxListenAddr = flag.String("influxListenAddr", "", "TCP and UDP address to listen for InfluxDB line protocol data. Usually :8189 must be set. Doesn't work if empty. "+
+ influxListenAddr = flag.String("influxListenAddr", "", "TCP and UDP address to listen for InfluxDB line protocol data. Usually :8089 must be set. Doesn't work if empty. "+
"This flag isn't needed when ingesting data over HTTP - just send it to http://:8428/write")
opentsdbListenAddr = flag.String("opentsdbListenAddr", "", "TCP and UDP address to listen for OpentTSDB metrics. "+
"Telnet put messages and HTTP /api/put messages are simultaneously served on TCP port. "+
From 9d7da130b5a873be334b38c8d8dec702c9e8fac5 Mon Sep 17 00:00:00 2001
From: Aliaksandr Valialkin
Date: Fri, 13 May 2022 16:55:48 +0300
Subject: [PATCH 26/51] docs/CHANGELOG.md: document
3f0ecee12882d476dbfa03ddae81ef075e9254a4
See https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2577
---
docs/CHANGELOG.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index c5ed9a965b..23be8f5d97 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -21,6 +21,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): limit the number of concurrently established connections from vmselect to vmstorage. This should prevent from potentially high spikes in the number of established connections after temporary slowdown in connection handshake procedure between vmselect and vmstorage because of spikes in workload. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552).
* BUGFIX: [vmctl](https://docs.victoriametrics.com/vmctl.html): fix build for Solaris / SmartOS. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146).
* BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): do not add `/api/v1/query` suffix to `-datasource.url` if `-remoteRead.disablePathAppend` command-line flag is set. Previously this flag was applied only to `-remoteRead.url`, which could confuse users.
+* BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): prevent from possible resource leak on config update, which could lead to the slowdown of `vmalert` over time. See [this pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2577).
## [v1.77.1](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.77.1)
From a531a96193596b9079f2bd75e55cc487298d3596 Mon Sep 17 00:00:00 2001
From: Andrii Chubatiuk
Date: Sat, 14 May 2022 12:38:44 +0300
Subject: [PATCH 27/51] added reusable templates support (#2532)
Signed-off-by: Andrii Chubatiuk
---
app/vmalert/Makefile | 1 +
app/vmalert/alerting.go | 5 +-
app/vmalert/config/config_test.go | 13 +-
.../testdata/{ => rules}/kube-good.rules | 0
.../{ => rules}/rules-query-good.rules | 0
.../{ => rules}/rules-replay-good.rules | 0
.../testdata/{ => rules}/rules0-bad.rules | 0
.../testdata/{ => rules}/rules0-good.rules | 0
.../testdata/{ => rules}/rules1-bad.rules | 0
.../testdata/{ => rules}/rules1-good.rules | 0
.../testdata/{ => rules}/rules2-good.rules | 0
.../testdata/{ => rules}/rules3-good.rules | 0
.../testdata/{ => rules}/rules4-good.rules | 0
.../{ => rules}/rules_interval_good.rules | 0
.../testdata/templates/templates0-good.tmpl | 3 +
.../testdata/templates/templates1-good.tmpl | 3 +
.../testdata/templates/templates2-good.tmpl | 3 +
.../testdata/templates/templates3-good.tmpl | 3 +
.../testdata/templates/templates4-good-tmpl | 3 +
app/vmalert/group_test.go | 2 +-
app/vmalert/main.go | 33 ++-
app/vmalert/manager_test.go | 35 +--
app/vmalert/notifier/alert.go | 45 ++-
app/vmalert/notifier/init.go | 9 +-
app/vmalert/notifier/package_test.go | 7 +-
.../template.go} | 184 ++++++++++--
app/vmalert/templates/template_test.go | 275 ++++++++++++++++++
.../templates/other/nested/bad0-test.tpl | 3 +
.../templates/other/nested/good0-test.tpl | 9 +
.../templates/templates/test/good0-test.tpl | 9 +
docs/vmalert.md | 55 +++-
31 files changed, 624 insertions(+), 76 deletions(-)
rename app/vmalert/config/testdata/{ => rules}/kube-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules-query-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules-replay-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules0-bad.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules0-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules1-bad.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules1-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules2-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules3-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules4-good.rules (100%)
rename app/vmalert/config/testdata/{ => rules}/rules_interval_good.rules (100%)
create mode 100644 app/vmalert/config/testdata/templates/templates0-good.tmpl
create mode 100644 app/vmalert/config/testdata/templates/templates1-good.tmpl
create mode 100644 app/vmalert/config/testdata/templates/templates2-good.tmpl
create mode 100644 app/vmalert/config/testdata/templates/templates3-good.tmpl
create mode 100644 app/vmalert/config/testdata/templates/templates4-good-tmpl
rename app/vmalert/{notifier/template_func.go => templates/template.go} (70%)
create mode 100644 app/vmalert/templates/template_test.go
create mode 100644 app/vmalert/templates/templates/other/nested/bad0-test.tpl
create mode 100644 app/vmalert/templates/templates/other/nested/good0-test.tpl
create mode 100644 app/vmalert/templates/templates/test/good0-test.tpl
diff --git a/app/vmalert/Makefile b/app/vmalert/Makefile
index eebac7f01f..c96708456c 100644
--- a/app/vmalert/Makefile
+++ b/app/vmalert/Makefile
@@ -62,6 +62,7 @@ publish-vmalert:
test-vmalert:
go test -v -race -cover ./app/vmalert -loggerLevel=ERROR
+ go test -v -race -cover ./app/vmalert/templates
go test -v -race -cover ./app/vmalert/datasource
go test -v -race -cover ./app/vmalert/notifier
go test -v -race -cover ./app/vmalert/config
diff --git a/app/vmalert/alerting.go b/app/vmalert/alerting.go
index 64a86bbea6..855843df52 100644
--- a/app/vmalert/alerting.go
+++ b/app/vmalert/alerting.go
@@ -12,6 +12,7 @@ import (
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/config"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/datasource"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/notifier"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/utils"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/logger"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/prompbmarshal"
@@ -152,7 +153,7 @@ type labelSet struct {
// toLabels converts labels from given Metric
// to labelSet which contains original and processed labels.
-func (ar *AlertingRule) toLabels(m datasource.Metric, qFn notifier.QueryFn) (*labelSet, error) {
+func (ar *AlertingRule) toLabels(m datasource.Metric, qFn templates.QueryFn) (*labelSet, error) {
ls := &labelSet{
origin: make(map[string]string, len(m.Labels)),
processed: make(map[string]string),
@@ -382,7 +383,7 @@ func hash(labels map[string]string) uint64 {
return hash.Sum64()
}
-func (ar *AlertingRule) newAlert(m datasource.Metric, ls *labelSet, start time.Time, qFn notifier.QueryFn) (*notifier.Alert, error) {
+func (ar *AlertingRule) newAlert(m datasource.Metric, ls *labelSet, start time.Time, qFn templates.QueryFn) (*notifier.Alert, error) {
var err error
if ls == nil {
ls, err = ar.toLabels(m, qFn)
diff --git a/app/vmalert/config/config_test.go b/app/vmalert/config/config_test.go
index 2b84c3effc..c81717ed01 100644
--- a/app/vmalert/config/config_test.go
+++ b/app/vmalert/config/config_test.go
@@ -10,18 +10,19 @@ import (
"gopkg.in/yaml.v2"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/datasource"
- "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/notifier"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/promutils"
)
func TestMain(m *testing.M) {
- u, _ := url.Parse("https://victoriametrics.com/path")
- notifier.InitTemplateFunc(u)
+ if err := templates.Load([]string{"testdata/templates/*good.tmpl"}, true); err != nil {
+ os.Exit(1)
+ }
os.Exit(m.Run())
}
func TestParseGood(t *testing.T) {
- if _, err := Parse([]string{"testdata/*good.rules", "testdata/dir/*good.*"}, true, true); err != nil {
+ if _, err := Parse([]string{"testdata/rules/*good.rules", "testdata/dir/*good.*"}, true, true); err != nil {
t.Errorf("error parsing files %s", err)
}
}
@@ -32,7 +33,7 @@ func TestParseBad(t *testing.T) {
expErr string
}{
{
- []string{"testdata/rules0-bad.rules"},
+ []string{"testdata/rules/rules0-bad.rules"},
"unexpected token",
},
{
@@ -56,7 +57,7 @@ func TestParseBad(t *testing.T) {
"either `record` or `alert` must be set",
},
{
- []string{"testdata/rules1-bad.rules"},
+ []string{"testdata/rules/rules1-bad.rules"},
"bad graphite expr",
},
}
diff --git a/app/vmalert/config/testdata/kube-good.rules b/app/vmalert/config/testdata/rules/kube-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/kube-good.rules
rename to app/vmalert/config/testdata/rules/kube-good.rules
diff --git a/app/vmalert/config/testdata/rules-query-good.rules b/app/vmalert/config/testdata/rules/rules-query-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules-query-good.rules
rename to app/vmalert/config/testdata/rules/rules-query-good.rules
diff --git a/app/vmalert/config/testdata/rules-replay-good.rules b/app/vmalert/config/testdata/rules/rules-replay-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules-replay-good.rules
rename to app/vmalert/config/testdata/rules/rules-replay-good.rules
diff --git a/app/vmalert/config/testdata/rules0-bad.rules b/app/vmalert/config/testdata/rules/rules0-bad.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules0-bad.rules
rename to app/vmalert/config/testdata/rules/rules0-bad.rules
diff --git a/app/vmalert/config/testdata/rules0-good.rules b/app/vmalert/config/testdata/rules/rules0-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules0-good.rules
rename to app/vmalert/config/testdata/rules/rules0-good.rules
diff --git a/app/vmalert/config/testdata/rules1-bad.rules b/app/vmalert/config/testdata/rules/rules1-bad.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules1-bad.rules
rename to app/vmalert/config/testdata/rules/rules1-bad.rules
diff --git a/app/vmalert/config/testdata/rules1-good.rules b/app/vmalert/config/testdata/rules/rules1-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules1-good.rules
rename to app/vmalert/config/testdata/rules/rules1-good.rules
diff --git a/app/vmalert/config/testdata/rules2-good.rules b/app/vmalert/config/testdata/rules/rules2-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules2-good.rules
rename to app/vmalert/config/testdata/rules/rules2-good.rules
diff --git a/app/vmalert/config/testdata/rules3-good.rules b/app/vmalert/config/testdata/rules/rules3-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules3-good.rules
rename to app/vmalert/config/testdata/rules/rules3-good.rules
diff --git a/app/vmalert/config/testdata/rules4-good.rules b/app/vmalert/config/testdata/rules/rules4-good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules4-good.rules
rename to app/vmalert/config/testdata/rules/rules4-good.rules
diff --git a/app/vmalert/config/testdata/rules_interval_good.rules b/app/vmalert/config/testdata/rules/rules_interval_good.rules
similarity index 100%
rename from app/vmalert/config/testdata/rules_interval_good.rules
rename to app/vmalert/config/testdata/rules/rules_interval_good.rules
diff --git a/app/vmalert/config/testdata/templates/templates0-good.tmpl b/app/vmalert/config/testdata/templates/templates0-good.tmpl
new file mode 100644
index 0000000000..617b712d8c
--- /dev/null
+++ b/app/vmalert/config/testdata/templates/templates0-good.tmpl
@@ -0,0 +1,3 @@
+{{ define "template0" }}
+Visit {{ externalURL }}
+{{ end }}
\ No newline at end of file
diff --git a/app/vmalert/config/testdata/templates/templates1-good.tmpl b/app/vmalert/config/testdata/templates/templates1-good.tmpl
new file mode 100644
index 0000000000..69448a65f5
--- /dev/null
+++ b/app/vmalert/config/testdata/templates/templates1-good.tmpl
@@ -0,0 +1,3 @@
+{{ define "template1" }}
+{{ 1048576 | humanize1024 }}
+{{ end }}
\ No newline at end of file
diff --git a/app/vmalert/config/testdata/templates/templates2-good.tmpl b/app/vmalert/config/testdata/templates/templates2-good.tmpl
new file mode 100644
index 0000000000..d0cf31764c
--- /dev/null
+++ b/app/vmalert/config/testdata/templates/templates2-good.tmpl
@@ -0,0 +1,3 @@
+{{ define "template2" }}
+{{ 1048576 | humanize1024 }}
+{{ end }}
\ No newline at end of file
diff --git a/app/vmalert/config/testdata/templates/templates3-good.tmpl b/app/vmalert/config/testdata/templates/templates3-good.tmpl
new file mode 100644
index 0000000000..05e26ac484
--- /dev/null
+++ b/app/vmalert/config/testdata/templates/templates3-good.tmpl
@@ -0,0 +1,3 @@
+{{ define "template3" }}
+{{ printf "%s to %s!" "welcome" "hell" | toUpper }}
+{{ end }}
\ No newline at end of file
diff --git a/app/vmalert/config/testdata/templates/templates4-good-tmpl b/app/vmalert/config/testdata/templates/templates4-good-tmpl
new file mode 100644
index 0000000000..312eed6db3
--- /dev/null
+++ b/app/vmalert/config/testdata/templates/templates4-good-tmpl
@@ -0,0 +1,3 @@
+{{ define "template3" }}
+{{ 1230912039102391023.0 | humanizeDuration }}
+{{ end }}
\ No newline at end of file
diff --git a/app/vmalert/group_test.go b/app/vmalert/group_test.go
index ab2cfe9511..95e50c43e9 100644
--- a/app/vmalert/group_test.go
+++ b/app/vmalert/group_test.go
@@ -157,7 +157,7 @@ func TestUpdateWith(t *testing.T) {
func TestGroupStart(t *testing.T) {
// TODO: make parsing from string instead of file
- groups, err := config.Parse([]string{"config/testdata/rules1-good.rules"}, true, true)
+ groups, err := config.Parse([]string{"config/testdata/rules/rules1-good.rules"}, true, true)
if err != nil {
t.Fatalf("failed to parse rules: %s", err)
}
diff --git a/app/vmalert/main.go b/app/vmalert/main.go
index b3ffe17c83..eccf4ef3e4 100644
--- a/app/vmalert/main.go
+++ b/app/vmalert/main.go
@@ -15,6 +15,7 @@ import (
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/notifier"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/remoteread"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/remotewrite"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/buildinfo"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/envflag"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/fasttime"
@@ -34,6 +35,13 @@ Examples:
absolute path to all .yaml files in root.
Rule files may contain %{ENV_VAR} placeholders, which are substituted by the corresponding env vars.`)
+ ruleTemplatesPath = flagutil.NewArray("rule.templates", `Path or glob pattern to location with go template definitions
+ for rules annotations templating. Flag can be specified multiple times.
+Examples:
+ -rule.templates="/path/to/file". Path to a single file with go templates
+ -rule.templates="dir/*.tpl" -rule.templates="/*.tpl". Relative path to all .tpl files in "dir" folder,
+absolute path to all .tpl files in root.`)
+
rulesCheckInterval = flag.Duration("rule.configCheckInterval", 0, "Interval for checking for changes in '-rule' files. "+
"By default the checking is disabled. Send SIGHUP signal in order to force config check for changes. DEPRECATED - see '-configCheckInterval' instead")
@@ -73,10 +81,12 @@ func main() {
envflag.Parse()
buildinfo.Init()
logger.Init()
+ err := templates.Load(*ruleTemplatesPath, true)
+ if err != nil {
+ logger.Fatalf("failed to parse %q: %s", *ruleTemplatesPath, err)
+ }
if *dryRun {
- u, _ := url.Parse("https://victoriametrics.com/")
- notifier.InitTemplateFunc(u)
groups, err := config.Parse(*rulePath, true, true)
if err != nil {
logger.Fatalf("failed to parse %q: %s", *rulePath, err)
@@ -91,7 +101,7 @@ func main() {
if err != nil {
logger.Fatalf("failed to init `external.url`: %s", err)
}
- notifier.InitTemplateFunc(eu)
+
alertURLGeneratorFn, err = getAlertURLGenerator(eu, *externalAlertSource, *validateTemplates)
if err != nil {
logger.Fatalf("failed to init `external.alert.source`: %s", err)
@@ -105,7 +115,6 @@ func main() {
if rw == nil {
logger.Fatalf("remoteWrite.url can't be empty in replay mode")
}
- notifier.InitTemplateFunc(eu)
groupsCfg, err := config.Parse(*rulePath, *validateTemplates, *validateExpressions)
if err != nil {
logger.Fatalf("cannot parse configuration file: %s", err)
@@ -127,7 +136,6 @@ func main() {
if err != nil {
logger.Fatalf("failed to init: %s", err)
}
-
logger.Infof("reading rules configuration file from %q", strings.Join(*rulePath, ";"))
groupsCfg, err := config.Parse(*rulePath, *validateTemplates, *validateExpressions)
if err != nil {
@@ -281,7 +289,11 @@ func configReload(ctx context.Context, m *manager, groupsCfg []config.Group, sig
case <-ctx.Done():
return
case <-sighupCh:
- logger.Infof("SIGHUP received. Going to reload rules %q ...", *rulePath)
+ tmplMsg := ""
+ if len(*ruleTemplatesPath) > 0 {
+ tmplMsg = fmt.Sprintf("and templates %q ", *ruleTemplatesPath)
+ }
+ logger.Infof("SIGHUP received. Going to reload rules %q %s...", *rulePath, tmplMsg)
configReloads.Inc()
case <-configCheckCh:
}
@@ -291,6 +303,13 @@ func configReload(ctx context.Context, m *manager, groupsCfg []config.Group, sig
logger.Errorf("failed to reload notifier config: %s", err)
continue
}
+ err := templates.Load(*ruleTemplatesPath, false)
+ if err != nil {
+ configReloadErrors.Inc()
+ configSuccess.Set(0)
+ logger.Errorf("failed to load new templates: %s", err)
+ continue
+ }
newGroupsCfg, err := config.Parse(*rulePath, *validateTemplates, *validateExpressions)
if err != nil {
configReloadErrors.Inc()
@@ -299,6 +318,7 @@ func configReload(ctx context.Context, m *manager, groupsCfg []config.Group, sig
continue
}
if configsEqual(newGroupsCfg, groupsCfg) {
+ templates.Reload()
// set success to 1 since previous reload
// could have been unsuccessful
configSuccess.Set(1)
@@ -311,6 +331,7 @@ func configReload(ctx context.Context, m *manager, groupsCfg []config.Group, sig
logger.Errorf("error while reloading rules: %s", err)
continue
}
+ templates.Reload()
groupsCfg = newGroupsCfg
configSuccess.Set(1)
configTimestamp.Set(fasttime.UnixTimestamp())
diff --git a/app/vmalert/manager_test.go b/app/vmalert/manager_test.go
index 9b7b1faf15..2ac3574caa 100644
--- a/app/vmalert/manager_test.go
+++ b/app/vmalert/manager_test.go
@@ -3,7 +3,6 @@ package main
import (
"context"
"math/rand"
- "net/url"
"os"
"strings"
"sync"
@@ -14,11 +13,13 @@ import (
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/datasource"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/notifier"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/remotewrite"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
)
func TestMain(m *testing.M) {
- u, _ := url.Parse("https://victoriametrics.com/path")
- notifier.InitTemplateFunc(u)
+ if err := templates.Load([]string{"testdata/templates/*good.tmpl"}, true); err != nil {
+ os.Exit(1)
+ }
os.Exit(m.Run())
}
@@ -47,9 +48,9 @@ func TestManagerUpdateConcurrent(t *testing.T) {
"config/testdata/dir/rules0-bad.rules",
"config/testdata/dir/rules1-good.rules",
"config/testdata/dir/rules1-bad.rules",
- "config/testdata/rules0-good.rules",
- "config/testdata/rules1-good.rules",
- "config/testdata/rules2-good.rules",
+ "config/testdata/rules/rules0-good.rules",
+ "config/testdata/rules/rules1-good.rules",
+ "config/testdata/rules/rules2-good.rules",
}
evalInterval := *evaluationInterval
defer func() { *evaluationInterval = evalInterval }()
@@ -125,7 +126,7 @@ func TestManagerUpdate(t *testing.T) {
}{
{
name: "update good rules",
- initPath: "config/testdata/rules0-good.rules",
+ initPath: "config/testdata/rules/rules0-good.rules",
updatePath: "config/testdata/dir/rules1-good.rules",
want: []*Group{
{
@@ -150,18 +151,18 @@ func TestManagerUpdate(t *testing.T) {
},
{
name: "update good rules from 1 to 2 groups",
- initPath: "config/testdata/dir/rules1-good.rules",
- updatePath: "config/testdata/rules0-good.rules",
+ initPath: "config/testdata/dir/rules/rules1-good.rules",
+ updatePath: "config/testdata/rules/rules0-good.rules",
want: []*Group{
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Name: "groupGorSingleAlert",
Type: datasource.NewPrometheusType(),
Rules: []Rule{VMRows},
Interval: defaultEvalInterval,
},
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Interval: defaultEvalInterval,
Type: datasource.NewPrometheusType(),
Name: "TestGroup", Rules: []Rule{
@@ -172,18 +173,18 @@ func TestManagerUpdate(t *testing.T) {
},
{
name: "update with one bad rule file",
- initPath: "config/testdata/rules0-good.rules",
+ initPath: "config/testdata/rules/rules0-good.rules",
updatePath: "config/testdata/dir/rules2-bad.rules",
want: []*Group{
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Name: "groupGorSingleAlert",
Type: datasource.NewPrometheusType(),
Interval: defaultEvalInterval,
Rules: []Rule{VMRows},
},
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Interval: defaultEvalInterval,
Name: "TestGroup",
Type: datasource.NewPrometheusType(),
@@ -196,17 +197,17 @@ func TestManagerUpdate(t *testing.T) {
{
name: "update empty dir rules from 0 to 2 groups",
initPath: "config/testdata/empty/*",
- updatePath: "config/testdata/rules0-good.rules",
+ updatePath: "config/testdata/rules/rules0-good.rules",
want: []*Group{
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Name: "groupGorSingleAlert",
Type: datasource.NewPrometheusType(),
Interval: defaultEvalInterval,
Rules: []Rule{VMRows},
},
{
- File: "config/testdata/rules0-good.rules",
+ File: "config/testdata/rules/rules0-good.rules",
Interval: defaultEvalInterval,
Type: datasource.NewPrometheusType(),
Name: "TestGroup", Rules: []Rule{
diff --git a/app/vmalert/notifier/alert.go b/app/vmalert/notifier/alert.go
index 96f5e5d1a1..8c3e7f2f5a 100644
--- a/app/vmalert/notifier/alert.go
+++ b/app/vmalert/notifier/alert.go
@@ -5,9 +5,10 @@ import (
"fmt"
"io"
"strings"
- "text/template"
+ textTpl "text/template"
"time"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/utils"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/prompbmarshal"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/promrelabel"
@@ -90,26 +91,38 @@ var tplHeaders = []string{
// map of annotations.
// Every alert could have a different datasource, so function
// requires a queryFunction as an argument.
-func (a *Alert) ExecTemplate(q QueryFn, labels, annotations map[string]string) (map[string]string, error) {
+func (a *Alert) ExecTemplate(q templates.QueryFn, labels, annotations map[string]string) (map[string]string, error) {
tplData := AlertTplData{Value: a.Value, Labels: labels, Expr: a.Expr}
- return templateAnnotations(annotations, tplData, funcsWithQuery(q), true)
+ tmpl, err := templates.GetWithFuncs(templates.FuncsWithQuery(q))
+ if err != nil {
+ return nil, fmt.Errorf("error getting a template: %w", err)
+ }
+ return templateAnnotations(annotations, tplData, tmpl, true)
}
// ExecTemplate executes the given template for given annotations map.
-func ExecTemplate(q QueryFn, annotations map[string]string, tpl AlertTplData) (map[string]string, error) {
- return templateAnnotations(annotations, tpl, funcsWithQuery(q), true)
+func ExecTemplate(q templates.QueryFn, annotations map[string]string, tplData AlertTplData) (map[string]string, error) {
+ tmpl, err := templates.GetWithFuncs(templates.FuncsWithQuery(q))
+ if err != nil {
+ return nil, fmt.Errorf("error cloning template: %w", err)
+ }
+ return templateAnnotations(annotations, tplData, tmpl, true)
}
// ValidateTemplates validate annotations for possible template error, uses empty data for template population
func ValidateTemplates(annotations map[string]string) error {
- _, err := templateAnnotations(annotations, AlertTplData{
+ tmpl, err := templates.Get()
+ if err != nil {
+ return err
+ }
+ _, err = templateAnnotations(annotations, AlertTplData{
Labels: map[string]string{},
Value: 0,
- }, tmplFunc, false)
+ }, tmpl, false)
return err
}
-func templateAnnotations(annotations map[string]string, data AlertTplData, funcs template.FuncMap, execute bool) (map[string]string, error) {
+func templateAnnotations(annotations map[string]string, data AlertTplData, tmpl *textTpl.Template, execute bool) (map[string]string, error) {
var builder strings.Builder
var buf bytes.Buffer
eg := new(utils.ErrGroup)
@@ -122,7 +135,7 @@ func templateAnnotations(annotations map[string]string, data AlertTplData, funcs
builder.Grow(len(header) + len(text))
builder.WriteString(header)
builder.WriteString(text)
- if err := templateAnnotation(&buf, builder.String(), tData, funcs, execute); err != nil {
+ if err := templateAnnotation(&buf, builder.String(), tData, tmpl, execute); err != nil {
r[key] = text
eg.Add(fmt.Errorf("key %q, template %q: %w", key, text, err))
continue
@@ -138,11 +151,17 @@ type tplData struct {
ExternalURL string
}
-func templateAnnotation(dst io.Writer, text string, data tplData, funcs template.FuncMap, execute bool) error {
- t := template.New("").Funcs(funcs).Option("missingkey=zero")
- tpl, err := t.Parse(text)
+func templateAnnotation(dst io.Writer, text string, data tplData, tmpl *textTpl.Template, execute bool) error {
+ tpl, err := tmpl.Clone()
if err != nil {
- return fmt.Errorf("error parsing annotation: %w", err)
+ return fmt.Errorf("error cloning template before parse annotation: %w", err)
+ }
+ tpl, err = tpl.Parse(text)
+ if err != nil {
+ return fmt.Errorf("error parsing annotation template: %w", err)
+ }
+ if !execute {
+ return nil
}
if !execute {
return nil
diff --git a/app/vmalert/notifier/init.go b/app/vmalert/notifier/init.go
index 99892d2b48..fdc49af1a7 100644
--- a/app/vmalert/notifier/init.go
+++ b/app/vmalert/notifier/init.go
@@ -3,9 +3,11 @@ package notifier
import (
"flag"
"fmt"
+ "net/url"
"strings"
"time"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/flagutil"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/promauth"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/prompbmarshal"
@@ -83,6 +85,12 @@ func Init(gen AlertURLGenerator, extLabels map[string]string, extURL string) (fu
externalURL = extURL
externalLabels = extLabels
+ eu, err := url.Parse(externalURL)
+ if err != nil {
+ return nil, fmt.Errorf("failed to parse external URL: %s", err)
+ }
+
+ templates.UpdateWithFuncs(templates.FuncsWithExternalURL(eu))
if *configPath == "" && len(*addrs) == 0 {
return nil, nil
@@ -102,7 +110,6 @@ func Init(gen AlertURLGenerator, extLabels map[string]string, extURL string) (fu
return staticNotifiersFn, nil
}
- var err error
cw, err = newWatcher(*configPath, gen)
if err != nil {
return nil, fmt.Errorf("failed to init config watcher: %s", err)
diff --git a/app/vmalert/notifier/package_test.go b/app/vmalert/notifier/package_test.go
index 11876ee3ac..3da0a93066 100644
--- a/app/vmalert/notifier/package_test.go
+++ b/app/vmalert/notifier/package_test.go
@@ -1,13 +1,14 @@
package notifier
import (
- "net/url"
+ "github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/templates"
"os"
"testing"
)
func TestMain(m *testing.M) {
- u, _ := url.Parse("https://victoriametrics.com/path")
- InitTemplateFunc(u)
+ if err := templates.Load([]string{"testdata/templates/*good.tmpl"}, true); err != nil {
+ os.Exit(1)
+ }
os.Exit(m.Run())
}
diff --git a/app/vmalert/notifier/template_func.go b/app/vmalert/templates/template.go
similarity index 70%
rename from app/vmalert/notifier/template_func.go
rename to app/vmalert/templates/template.go
index c217bc6ff5..12de9b3c17 100644
--- a/app/vmalert/notifier/template_func.go
+++ b/app/vmalert/templates/template.go
@@ -11,26 +11,117 @@
// See the License for the specific language governing permissions and
// limitations under the License.
-package notifier
+package templates
import (
"errors"
"fmt"
+ htmlTpl "html/template"
+ "io/ioutil"
"math"
"net"
"net/url"
+ "path/filepath"
"regexp"
"sort"
"strings"
+ "sync"
"time"
- htmlTpl "html/template"
textTpl "text/template"
"github.com/VictoriaMetrics/VictoriaMetrics/app/vmalert/datasource"
"github.com/VictoriaMetrics/VictoriaMetrics/lib/promutils"
)
+// go template execution fails when it's tree is empty
+const defaultTemplate = `{{- define "default.template" -}}{{- end -}}`
+
+var tplMu sync.RWMutex
+
+type textTemplate struct {
+ current *textTpl.Template
+ replacement *textTpl.Template
+}
+
+var masterTmpl textTemplate
+
+func newTemplate() *textTpl.Template {
+ tmpl := textTpl.New("").Option("missingkey=zero").Funcs(templateFuncs())
+ return textTpl.Must(tmpl.Parse(defaultTemplate))
+}
+
+// Load func loads templates from multiple globs specified in pathPatterns and either
+// sets them directly to current template if it's undefined or with overwrite=true
+// or sets replacement templates and adds templates with new names to a current
+func Load(pathPatterns []string, overwrite bool) error {
+ var err error
+ tmpl := newTemplate()
+ for _, tp := range pathPatterns {
+ p, err := filepath.Glob(tp)
+ if err != nil {
+ return fmt.Errorf("failed to retrieve a template glob %q: %w", tp, err)
+ }
+ if len(p) > 0 {
+ tmpl, err = tmpl.ParseGlob(tp)
+ if err != nil {
+ return fmt.Errorf("failed to parse template glob %q: %w", tp, err)
+ }
+ }
+ }
+ if len(tmpl.Templates()) > 0 {
+ err := tmpl.Execute(ioutil.Discard, nil)
+ if err != nil {
+ return fmt.Errorf("failed to execute template: %w", err)
+ }
+ }
+ tplMu.Lock()
+ defer tplMu.Unlock()
+ if masterTmpl.current == nil || overwrite {
+ masterTmpl.replacement = nil
+ masterTmpl.current = newTemplate()
+ } else {
+ masterTmpl.replacement = newTemplate()
+ if err = copyTemplates(tmpl, masterTmpl.replacement, overwrite); err != nil {
+ return err
+ }
+ }
+ return copyTemplates(tmpl, masterTmpl.current, overwrite)
+}
+
+func copyTemplates(from *textTpl.Template, to *textTpl.Template, overwrite bool) error {
+ if from == nil {
+ return nil
+ }
+ if to == nil {
+ to = newTemplate()
+ }
+ tmpl, err := from.Clone()
+ if err != nil {
+ return err
+ }
+ for _, t := range tmpl.Templates() {
+ if to.Lookup(t.Name()) == nil || overwrite {
+ to, err = to.AddParseTree(t.Name(), t.Tree)
+ if err != nil {
+ return fmt.Errorf("failed to add template %q: %w", t.Name(), err)
+ }
+ }
+ }
+ return nil
+}
+
+// Reload func replaces current template with a replacement template
+// which was set by Load with override=false
+func Reload() {
+ tplMu.Lock()
+ defer tplMu.Unlock()
+ if masterTmpl.replacement != nil {
+ masterTmpl.current = masterTmpl.replacement
+ masterTmpl.replacement = nil
+ }
+}
+
// metric is private copy of datasource.Metric,
// it is used for templating annotations,
// Labels as map simplifies templates evaluation.
@@ -60,12 +151,62 @@ func datasourceMetricsToTemplateMetrics(ms []datasource.Metric) []metric {
// for templating functions.
type QueryFn func(query string) ([]datasource.Metric, error)
-var tmplFunc textTpl.FuncMap
+// UpdateWithFuncs updates existing or sets a new function map for a template
+func UpdateWithFuncs(funcs textTpl.FuncMap) {
+ tplMu.Lock()
+ defer tplMu.Unlock()
+ masterTmpl.current = masterTmpl.current.Funcs(funcs)
+}
-// InitTemplateFunc initiates template helper functions
-func InitTemplateFunc(externalURL *url.URL) {
+// GetWithFuncs returns a copy of current template with additional FuncMap
+// provided with funcs argument
+func GetWithFuncs(funcs textTpl.FuncMap) (*textTpl.Template, error) {
+ tplMu.RLock()
+ defer tplMu.RUnlock()
+ tmpl, err := masterTmpl.current.Clone()
+ if err != nil {
+ return nil, err
+ }
+ return tmpl.Funcs(funcs), nil
+}
+
+// Get returns a copy of a template
+func Get() (*textTpl.Template, error) {
+ tplMu.RLock()
+ defer tplMu.RUnlock()
+ return masterTmpl.current.Clone()
+}
+
+// FuncsWithQuery returns a function map that depends on metric data
+func FuncsWithQuery(query QueryFn) textTpl.FuncMap {
+ return textTpl.FuncMap{
+ "query": func(q string) ([]metric, error) {
+ result, err := query(q)
+ if err != nil {
+ return nil, err
+ }
+ return datasourceMetricsToTemplateMetrics(result), nil
+ },
+ }
+}
+
+// FuncsWithExternalURL returns a function map that depends on externalURL value
+func FuncsWithExternalURL(externalURL *url.URL) textTpl.FuncMap {
+ return textTpl.FuncMap{
+ "externalURL": func() string {
+ return externalURL.String()
+ },
+
+ "pathPrefix": func() string {
+ return externalURL.Path
+ },
+ }
+}
+
+// templateFuncs initiates template helper functions
+func templateFuncs() textTpl.FuncMap {
// See https://prometheus.io/docs/prometheus/latest/configuration/template_reference/
- tmplFunc = textTpl.FuncMap{
+ return textTpl.FuncMap{
/* Strings */
// reReplaceAll ReplaceAllString returns a copy of src, replacing matches of the Regexp with
@@ -219,12 +360,22 @@ func InitTemplateFunc(externalURL *url.URL) {
// externalURL returns value of `external.url` flag
"externalURL": func() string {
- return externalURL.String()
+ // externalURL function supposed to be substituted at FuncsWithExteralURL().
+ // it is present here only for validation purposes, when there is no
+ // provided datasource.
+ //
+ // return non-empty slice to pass validation with chained functions in template
+ return ""
},
// pathPrefix returns a Path segment from the URL value in `external.url` flag
"pathPrefix": func() string {
- return externalURL.Path
+ // pathPrefix function supposed to be substituted at FuncsWithExteralURL().
+ // it is present here only for validation purposes, when there is no
+ // provided datasource.
+ //
+ // return non-empty slice to pass validation with chained functions in template
+ return ""
},
// pathEscape escapes the string so it can be safely placed inside a URL path segment,
@@ -259,7 +410,7 @@ func InitTemplateFunc(externalURL *url.URL) {
// execute "/api/v1/query?query=foo" request and will return
// the first value in response.
"query": func(q string) ([]metric, error) {
- // query function supposed to be substituted at funcsWithQuery().
+ // query function supposed to be substituted at FuncsWithQuery().
// it is present here only for validation purposes, when there is no
// provided datasource.
//
@@ -316,21 +467,6 @@ func InitTemplateFunc(externalURL *url.URL) {
}
}
-func funcsWithQuery(query QueryFn) textTpl.FuncMap {
- fm := make(textTpl.FuncMap)
- for k, fn := range tmplFunc {
- fm[k] = fn
- }
- fm["query"] = func(q string) ([]metric, error) {
- result, err := query(q)
- if err != nil {
- return nil, err
- }
- return datasourceMetricsToTemplateMetrics(result), nil
- }
- return fm
-}
-
// Time is the number of milliseconds since the epoch
// (1970-01-01 00:00 UTC) excluding leap seconds.
type Time int64
diff --git a/app/vmalert/templates/template_test.go b/app/vmalert/templates/template_test.go
new file mode 100644
index 0000000000..dc2cb09ce3
--- /dev/null
+++ b/app/vmalert/templates/template_test.go
@@ -0,0 +1,275 @@
+package templates
+
+import (
+ "strings"
+ "testing"
+ textTpl "text/template"
+)
+
+func mkTemplate(current, replacement interface{}) textTemplate {
+ tmpl := textTemplate{}
+ if current != nil {
+ switch val := current.(type) {
+ case string:
+ tmpl.current = textTpl.Must(newTemplate().Parse(val))
+ }
+ }
+ if replacement != nil {
+ switch val := replacement.(type) {
+ case string:
+ tmpl.replacement = textTpl.Must(newTemplate().Parse(val))
+ }
+ }
+ return tmpl
+}
+
+func equalTemplates(t *testing.T, tmpls ...*textTpl.Template) bool {
+ var cmp *textTpl.Template
+ for i, tmpl := range tmpls {
+ if i == 0 {
+ cmp = tmpl
+ } else {
+ if cmp == nil || tmpl == nil {
+ if cmp != tmpl {
+ return false
+ }
+ continue
+ }
+ if len(tmpl.Templates()) != len(cmp.Templates()) {
+ return false
+ }
+ for _, t := range tmpl.Templates() {
+ tp := cmp.Lookup(t.Name())
+ if tp == nil {
+ return false
+ }
+ if tp.Root.String() != t.Root.String() {
+ return false
+ }
+ }
+ }
+ }
+ return true
+}
+
+func TestTemplates_Load(t *testing.T) {
+ testCases := []struct {
+ name string
+ initialTemplate textTemplate
+ pathPatterns []string
+ overwrite bool
+ expectedTemplate textTemplate
+ expErr string
+ }{
+ {
+ "non existing path undefined template override",
+ mkTemplate(nil, nil),
+ []string{
+ "templates/non-existing/good-*.tpl",
+ "templates/absent/good-*.tpl",
+ },
+ true,
+ mkTemplate(``, nil),
+ "",
+ },
+ {
+ "non existing path defined template override",
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ `, nil),
+ []string{
+ "templates/non-existing/good-*.tpl",
+ "templates/absent/good-*.tpl",
+ },
+ true,
+ mkTemplate(``, nil),
+ "",
+ },
+ {
+ "existing path undefined template override",
+ mkTemplate(nil, nil),
+ []string{
+ "templates/other/nested/good0-*.tpl",
+ "templates/test/good0-*.tpl",
+ },
+ false,
+ mkTemplate(`
+ {{- define "good0-test.tpl" -}}{{- end -}}
+ {{- define "test.0" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.2" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.3" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ `, nil),
+ "",
+ },
+ {
+ "existing path defined template override",
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" "world" }}
+ {{- end -}}
+ `, nil),
+ []string{
+ "templates/other/nested/good0-*.tpl",
+ "templates/test/good0-*.tpl",
+ },
+ false,
+ mkTemplate(`
+ {{- define "good0-test.tpl" -}}{{- end -}}
+ {{- define "test.0" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" "world" }}
+ {{- end -}}
+ {{- define "test.2" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.3" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ `, `
+ {{- define "good0-test.tpl" -}}{{- end -}}
+ {{- define "test.0" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.2" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ {{- define "test.3" -}}
+ {{ printf "Hello %s!" externalURL }}
+ {{- end -}}
+ `),
+ "",
+ },
+ {
+ "load template with syntax error",
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" "world" }}
+ {{- end -}}
+ `, nil),
+ []string{
+ "templates/other/nested/bad0-*.tpl",
+ "templates/test/good0-*.tpl",
+ },
+ false,
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{ printf "Hello %s!" "world" }}
+ {{- end -}}
+ `, nil),
+ "failed to parse template glob",
+ },
+ }
+
+ for _, tc := range testCases {
+ t.Run(tc.name, func(t *testing.T) {
+ masterTmpl = tc.initialTemplate
+ err := Load(tc.pathPatterns, tc.overwrite)
+ if tc.expErr == "" && err != nil {
+ t.Error("happened error that wasn't expected: %w", err)
+ }
+ if tc.expErr != "" && err == nil {
+ t.Error("%+w", err)
+ t.Error("expected error that didn't happend")
+ }
+ if err != nil && !strings.Contains(err.Error(), tc.expErr) {
+ t.Error("%+w", err)
+ t.Error("expected string doesn't exist in error message")
+ }
+ if !equalTemplates(t, masterTmpl.replacement, tc.expectedTemplate.replacement) {
+ t.Fatalf("replacement template is not as expected")
+ }
+ if !equalTemplates(t, masterTmpl.current, tc.expectedTemplate.current) {
+ t.Fatalf("current template is not as expected")
+ }
+ })
+ }
+}
+
+func TestTemplates_Reload(t *testing.T) {
+ testCases := []struct {
+ name string
+ initialTemplate textTemplate
+ expectedTemplate textTemplate
+ }{
+ {
+ "empty current and replacement templates",
+ mkTemplate(nil, nil),
+ mkTemplate(nil, nil),
+ },
+ {
+ "empty current template only",
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ `, nil),
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ `, nil),
+ },
+ {
+ "empty replacement template only",
+ mkTemplate(nil, `
+ {{- define "test.1" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ `),
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ `, nil),
+ },
+ {
+ "defined both templates",
+ mkTemplate(`
+ {{- define "test.0" -}}
+ {{- printf "value" -}}
+ {{- end -}}
+ {{- define "test.1" -}}
+ {{- printf "before" -}}
+ {{- end -}}
+ `, `
+ {{- define "test.1" -}}
+ {{- printf "after" -}}
+ {{- end -}}
+ `),
+ mkTemplate(`
+ {{- define "test.1" -}}
+ {{- printf "after" -}}
+ {{- end -}}
+ `, nil),
+ },
+ }
+
+ for _, tc := range testCases {
+ t.Run(tc.name, func(t *testing.T) {
+ masterTmpl = tc.initialTemplate
+ Reload()
+ if !equalTemplates(t, masterTmpl.replacement, tc.expectedTemplate.replacement) {
+ t.Fatalf("replacement template is not as expected")
+ }
+ if !equalTemplates(t, masterTmpl.current, tc.expectedTemplate.current) {
+ t.Fatalf("current template is not as expected")
+ }
+ })
+ }
+}
diff --git a/app/vmalert/templates/templates/other/nested/bad0-test.tpl b/app/vmalert/templates/templates/other/nested/bad0-test.tpl
new file mode 100644
index 0000000000..4ed6658825
--- /dev/null
+++ b/app/vmalert/templates/templates/other/nested/bad0-test.tpl
@@ -0,0 +1,3 @@
+{{- define "test.1" -}}
+ {{ printf "Hello %s!" externalURL" }}
+{{- end -}}
\ No newline at end of file
diff --git a/app/vmalert/templates/templates/other/nested/good0-test.tpl b/app/vmalert/templates/templates/other/nested/good0-test.tpl
new file mode 100644
index 0000000000..7c8b2924d7
--- /dev/null
+++ b/app/vmalert/templates/templates/other/nested/good0-test.tpl
@@ -0,0 +1,9 @@
+{{- define "test.1" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
+{{- define "test.0" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
+{{- define "test.3" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
\ No newline at end of file
diff --git a/app/vmalert/templates/templates/test/good0-test.tpl b/app/vmalert/templates/templates/test/good0-test.tpl
new file mode 100644
index 0000000000..2b33463eac
--- /dev/null
+++ b/app/vmalert/templates/templates/test/good0-test.tpl
@@ -0,0 +1,9 @@
+{{- define "test.2" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
+{{- define "test.0" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
+{{- define "test.3" -}}
+ {{ printf "Hello %s!" externalURL }}
+{{- end -}}
\ No newline at end of file
diff --git a/docs/vmalert.md b/docs/vmalert.md
index 88155089b9..244c7737a0 100644
--- a/docs/vmalert.md
+++ b/docs/vmalert.md
@@ -25,6 +25,7 @@ implementation and aims to be compatible with its syntax.
* Graphite datasource can be used for alerting and recording rules. See [these docs](#graphite);
* Recording and Alerting rules backfilling (aka `replay`). See [these docs](#rules-backfilling);
* Lightweight without extra dependencies.
+* Supports [reusable templates](#reusable-templates) for annotations.
## Limitations
@@ -188,10 +189,53 @@ annotations:
[ : ]
```
-It is allowed to use [Go templating](https://golang.org/pkg/text/template/) in annotations
-to format data, iterate over it or execute expressions.
+It is allowed to use [Go templating](https://golang.org/pkg/text/template/) in annotations to format data, iterate over it or execute expressions.
Additionally, `vmalert` provides some extra templating functions
-listed [here](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/template_func.go).
+listed [here](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/template_func.go) and [reusable templates](#reusable-templates).
+
+#### Reusable templates
+
+Like in Alertmanager you can use reusable templates to share same templates across anotations. Path to files with templates is provided with `-rule.templates` cli argument. E.g:
+
+`/etc/vmalert/templates/global/common.tpl`
+
+```
+{{ define "grafana.filter" -}}
+ {{- $labels := .arg0 -}}
+ {{- range $name, $label := . -}}
+ {{- if (ne $name "arg0") -}}
+ {{- ( or (index $labels $label) "All" ) | printf "&var-%s=%s" $label -}}
+ {{- end -}}
+ {{- end -}}
+{{- end -}}
+```
+
+`/etc/vmalert/rules/project/rule.yaml`
+
+```yaml
+groups:
+ - name: AlertGroupName
+ rules:
+ - alert: AlertName
+ expr: any_metric > 100
+ for: 30s
+ labels:
+ alertname: 'Any metric is too high'
+ severity: 'warning'
+ annotations:
+ dashboard: '{{ $externalURL }}/d/dashboard?orgId=1{{ template "grafana.filter" (args .CommonLabels "account_id" "any_label") }}'
+```
+
+`vmalert` configuration flags:
+
+```
+./bin/vmalert -rule=/etc/vmalert/rules/**/*.yaml \ # Path to the fules with rules configuration
+ -rule.templates=/etc/vmalert/templates/**/*.tpl \ # Path to the files with rule templates
+ -datasource.url=http://victoriametrics:8428 \ # VM-single addr for executing rules expressions
+ -remoteWrite.url=http://victoriametrics:8428 \ # VM-single addr to persist alerts state and recording rules results
+ -remoteRead.url=http://victoriametrics:8428 \ # VM-single addr for restoring alerts state after restart
+ -notifier.url=http://alertmanager:9093 # AlertManager addr to send alerts when they trigger
+```
#### Recording rules
@@ -796,6 +840,11 @@ The shortlist of configuration flags is the following:
absolute path to all .yaml files in root.
Rule files may contain %{ENV_VAR} placeholders, which are substituted by the corresponding env vars.
Supports an array of values separated by comma or specified via multiple flags.
+ -rule.templates
+ Path or glob pattern to location with go template definitions for rules annotations templating. Flag can be specified multiple times.
+ Examples:
+ -rule.templates="/path/to/file". Path to a single file with go templates
+ -rule.templates="dir/*.tpl" -rule.templates="/*.tpl". Relative path to all .tpl files in "dir" folder, absolute path to all .tpl files in root.
-rule.configCheckInterval duration
Interval for checking for changes in '-rule' files. By default the checking is disabled. Send SIGHUP signal in order to force config check for changes. DEPRECATED - see '-configCheckInterval' instead
-rule.maxResolveDuration duration
From 9bc03f6b042148bbe26f47d1ad30a015d1302caa Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Sat, 14 May 2022 18:56:31 +0200
Subject: [PATCH 28/51] vmalert: follow-up after
0ac1cdfff59f6285ed4750c2cb030587cd8b0f65 (#2586)
Signed-off-by: hagen1778
---
app/vmalert/README.md | 110 ++++++++++++++++++++++++++++++------------
docs/CHANGELOG.md | 1 +
docs/vmalert.md | 75 ++++++++++++++--------------
3 files changed, 117 insertions(+), 69 deletions(-)
diff --git a/app/vmalert/README.md b/app/vmalert/README.md
index 50ffe39b32..2b12c8011f 100644
--- a/app/vmalert/README.md
+++ b/app/vmalert/README.md
@@ -13,23 +13,24 @@ implementation and aims to be compatible with its syntax.
* Integration with [VictoriaMetrics](https://github.com/VictoriaMetrics/VictoriaMetrics) TSDB;
* VictoriaMetrics [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html)
- support and expressions validation;
+ support and expressions validation;
* Prometheus [alerting rules definition format](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/#defining-alerting-rules)
- support;
+ support;
* Integration with [Alertmanager](https://github.com/prometheus/alertmanager) starting from [Alertmanager v0.16.0-aplha](https://github.com/prometheus/alertmanager/releases/tag/v0.16.0-alpha.0);
* Keeps the alerts [state on restarts](#alerts-state-on-restarts);
* Graphite datasource can be used for alerting and recording rules. See [these docs](#graphite);
* Recording and Alerting rules backfilling (aka `replay`). See [these docs](#rules-backfilling);
* Lightweight without extra dependencies.
+* Supports [reusable templates](#reusable-templates) for annotations.
## Limitations
* `vmalert` execute queries against remote datasource which has reliability risks because of the network.
-It is recommended to configure alerts thresholds and rules expressions with the understanding that network
-requests may fail;
+ It is recommended to configure alerts thresholds and rules expressions with the understanding that network
+ requests may fail;
* by default, rules execution is sequential within one group, but persistence of execution results to remote
-storage is asynchronous. Hence, user shouldn't rely on chaining of recording rules when result of previous
-recording rule is reused in the next one;
+ storage is asynchronous. Hence, user shouldn't rely on chaining of recording rules when result of previous
+ recording rule is reused in the next one;
## QuickStart
@@ -48,8 +49,8 @@ To start using `vmalert` you will need the following things:
* list of rules - PromQL/MetricsQL expressions to execute;
* datasource address - reachable MetricsQL endpoint to run queries against;
* notifier address [optional] - reachable [Alert Manager](https://github.com/prometheus/alertmanager) instance for processing,
-aggregating alerts, and sending notifications. Please note, notifier address also supports Consul and DNS Service Discovery via
-[config file](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/config.go).
+ aggregating alerts, and sending notifications. Please note, notifier address also supports Consul and DNS Service Discovery via
+ [config file](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/config.go).
* remote write address [optional] - [remote write](https://prometheus.io/docs/prometheus/latest/storage/#remote-storage-integrations)
compatible storage to persist rules and alerts state info;
* remote read address [optional] - MetricsQL compatible datasource to restore alerts state from.
@@ -146,12 +147,12 @@ expression and then act according to the Rule type.
There are two types of Rules:
* [alerting](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/) -
-Alerting rules allow defining alert conditions via `expr` field and to send notifications to
-[Alertmanager](https://github.com/prometheus/alertmanager) if execution result is not empty.
+ Alerting rules allow defining alert conditions via `expr` field and to send notifications to
+ [Alertmanager](https://github.com/prometheus/alertmanager) if execution result is not empty.
* [recording](https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) -
-Recording rules allow defining `expr` which result will be then backfilled to configured
-`-remoteWrite.url`. Recording rules are used to precompute frequently needed or computationally
-expensive expressions and save their result as a new set of time series.
+ Recording rules allow defining `expr` which result will be then backfilled to configured
+ `-remoteWrite.url`. Recording rules are used to precompute frequently needed or computationally
+ expensive expressions and save their result as a new set of time series.
`vmalert` forbids defining duplicates - rules with the same combination of name, expression, and labels
within one group.
@@ -184,10 +185,52 @@ annotations:
[ : ]
```
-It is allowed to use [Go templating](https://golang.org/pkg/text/template/) in annotations
-to format data, iterate over it or execute expressions.
+It is allowed to use [Go templating](https://golang.org/pkg/text/template/) in annotations to format data, iterate over it or execute expressions.
Additionally, `vmalert` provides some extra templating functions
-listed [here](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/template_func.go).
+listed [here](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/template_func.go) and [reusable templates](#reusable-templates).
+
+#### Reusable templates
+
+Like in Alertmanager you can define [reusable templates](https://prometheus.io/docs/prometheus/latest/configuration/template_examples/#defining-reusable-templates)
+to share same templates across annotations. Just define the templates in a file and
+set the path via `-rule.templates` flag.
+
+For example, the template can be defined as following:
+
+`/etc/vmalert/templates/global/common.tpl`
+
+```
+{{ define "grafana.filter" -}}
+ {{- $labels := .arg0 -}}
+ {{- range $name, $label := . -}}
+ {{- if (ne $name "arg0") -}}
+ {{- ( or (index $labels $label) "All" ) | printf "&var-%s=%s" $label -}}
+ {{- end -}}
+ {{- end -}}
+{{- end -}}
+```
+
+And used in annotations:
+
+`/etc/vmalert/rules/project/rule.yaml`
+
+```yaml
+groups:
+ - name: AlertGroupName
+ rules:
+ - alert: AlertName
+ expr: any_metric > 100
+ for: 30s
+ labels:
+ alertname: 'Any metric is too high'
+ severity: 'warning'
+ annotations:
+ dashboard: '{{ $externalURL }}/d/dashboard?orgId=1{{ template "grafana.filter" (args .CommonLabels "account_id" "any_label") }}'
+```
+
+The `-rule.templates` flag supports wildcards so multiple files with templates can be loaded.
+The content of `-rule.templates` can be also [hot reloaded](#hot-config-reload).
+
#### Recording rules
@@ -215,11 +258,11 @@ For recording rules to work `-remoteWrite.url` must be specified.
the process alerts state will be lost. To avoid this situation, `vmalert` should be configured via the following flags:
* `-remoteWrite.url` - URL to VictoriaMetrics (Single) or vminsert (Cluster). `vmalert` will persist alerts state
-into the configured address in the form of time series named `ALERTS` and `ALERTS_FOR_STATE` via remote-write protocol.
-These are regular time series and maybe queried from VM just as any other time series.
-The state is stored to the configured address on every rule evaluation.
+ into the configured address in the form of time series named `ALERTS` and `ALERTS_FOR_STATE` via remote-write protocol.
+ These are regular time series and maybe queried from VM just as any other time series.
+ The state is stored to the configured address on every rule evaluation.
* `-remoteRead.url` - URL to VictoriaMetrics (Single) or vmselect (Cluster). `vmalert` will try to restore alerts state
-from configured address by querying time series with name `ALERTS_FOR_STATE`.
+ from configured address by querying time series with name `ALERTS_FOR_STATE`.
Both flags are required for proper state restoration. Restore process may fail if time series are missing
in configured `-remoteRead.url`, weren't updated in the last `1h` (controlled by `-remoteRead.lookback`)
@@ -275,7 +318,7 @@ for different scenarios.
Please note, not all flags in examples are required:
* `-remoteWrite.url` and `-remoteRead.url` are optional and are needed only if
-you have recording rules or want to store [alerts state](#alerts-state-on-restarts) on `vmalert` restarts;
+ you have recording rules or want to store [alerts state](#alerts-state-on-restarts) on `vmalert` restarts;
* `-notifier.url` is optional and is needed only if you have alerting rules.
#### Single-node VictoriaMetrics
@@ -384,7 +427,7 @@ See also [downsampling docs](https://docs.victoriametrics.com/#downsampling).
* `http:///api/v1/rules` - list of all loaded groups and rules;
* `http:///api/v1/alerts` - list of all active alerts;
* `http:///api/v1///status"` - get alert status by ID.
-Used as alert source in AlertManager.
+ Used as alert source in AlertManager.
* `http:///metrics` - application metrics.
* `http:///-/reload` - hot configuration reload.
@@ -473,17 +516,17 @@ Execute the query against storage which was used for `-remoteWrite.url` during t
There are following non-required `replay` flags:
* `-replay.maxDatapointsPerQuery` - the max number of data points expected to receive in one request.
-In two words, it affects the max time range for every `/query_range` request. The higher the value,
-the fewer requests will be issued during `replay`.
+ In two words, it affects the max time range for every `/query_range` request. The higher the value,
+ the fewer requests will be issued during `replay`.
* `-replay.ruleRetryAttempts` - when datasource fails to respond vmalert will make this number of retries
-per rule before giving up.
+ per rule before giving up.
* `-replay.rulesDelay` - delay between sequential rules execution. Important in cases if there are chaining
-(rules which depend on each other) rules. It is expected, that remote storage will be able to persist
-previously accepted data during the delay, so data will be available for the subsequent queries.
-Keep it equal or bigger than `-remoteWrite.flushInterval`.
+ (rules which depend on each other) rules. It is expected, that remote storage will be able to persist
+ previously accepted data during the delay, so data will be available for the subsequent queries.
+ Keep it equal or bigger than `-remoteWrite.flushInterval`.
* `replay.disableProgressBar` - whether to disable progress bar which shows progress work.
-Progress bar may generate a lot of log records, which is not formatted as standard VictoriaMetrics logger.
-It could break logs parsing by external system and generate additional load on it.
+ Progress bar may generate a lot of log records, which is not formatted as standard VictoriaMetrics logger.
+ It could break logs parsing by external system and generate additional load on it.
See full description for these flags in `./vmalert --help`.
@@ -792,6 +835,11 @@ The shortlist of configuration flags is the following:
absolute path to all .yaml files in root.
Rule files may contain %{ENV_VAR} placeholders, which are substituted by the corresponding env vars.
Supports an array of values separated by comma or specified via multiple flags.
+ -rule.templates
+ Path or glob pattern to location with go template definitions for rules annotations templating. Flag can be specified multiple times.
+ Examples:
+ -rule.templates="/path/to/file". Path to a single file with go templates
+ -rule.templates="dir/*.tpl" -rule.templates="/*.tpl". Relative path to all .tpl files in "dir" folder, absolute path to all .tpl files in root.
-rule.configCheckInterval duration
Interval for checking for changes in '-rule' files. By default the checking is disabled. Send SIGHUP signal in order to force config check for changes. DEPRECATED - see '-configCheckInterval' instead
-rule.maxResolveDuration duration
@@ -822,7 +870,7 @@ The shortlist of configuration flags is the following:
* send SIGHUP signal to `vmalert` process;
* send GET request to `/-/reload` endpoint;
* configure `-configCheckInterval` flag for periodic reload
-on config change.
+ on config change.
### URL params
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index 23be8f5d97..e99366b3c7 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -15,6 +15,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
## tip
+* FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): support [reusable templates](https://prometheus.io/docs/prometheus/latest/configuration/template_examples/#defining-reusable-templates) for rules annotations. The path to the template files can be specified via `-rule.templates` flag. See more about this feature [here](https://docs.victoriametrics.com/vmalert.html#reusable-templates). Thanks to @AndrewChubatiuk for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2532).
* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
diff --git a/docs/vmalert.md b/docs/vmalert.md
index 244c7737a0..c2365a8f7a 100644
--- a/docs/vmalert.md
+++ b/docs/vmalert.md
@@ -17,9 +17,9 @@ implementation and aims to be compatible with its syntax.
* Integration with [VictoriaMetrics](https://github.com/VictoriaMetrics/VictoriaMetrics) TSDB;
* VictoriaMetrics [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html)
- support and expressions validation;
+ support and expressions validation;
* Prometheus [alerting rules definition format](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/#defining-alerting-rules)
- support;
+ support;
* Integration with [Alertmanager](https://github.com/prometheus/alertmanager) starting from [Alertmanager v0.16.0-aplha](https://github.com/prometheus/alertmanager/releases/tag/v0.16.0-alpha.0);
* Keeps the alerts [state on restarts](#alerts-state-on-restarts);
* Graphite datasource can be used for alerting and recording rules. See [these docs](#graphite);
@@ -30,11 +30,11 @@ implementation and aims to be compatible with its syntax.
## Limitations
* `vmalert` execute queries against remote datasource which has reliability risks because of the network.
-It is recommended to configure alerts thresholds and rules expressions with the understanding that network
-requests may fail;
+ It is recommended to configure alerts thresholds and rules expressions with the understanding that network
+ requests may fail;
* by default, rules execution is sequential within one group, but persistence of execution results to remote
-storage is asynchronous. Hence, user shouldn't rely on chaining of recording rules when result of previous
-recording rule is reused in the next one;
+ storage is asynchronous. Hence, user shouldn't rely on chaining of recording rules when result of previous
+ recording rule is reused in the next one;
## QuickStart
@@ -53,8 +53,8 @@ To start using `vmalert` you will need the following things:
* list of rules - PromQL/MetricsQL expressions to execute;
* datasource address - reachable MetricsQL endpoint to run queries against;
* notifier address [optional] - reachable [Alert Manager](https://github.com/prometheus/alertmanager) instance for processing,
-aggregating alerts, and sending notifications. Please note, notifier address also supports Consul and DNS Service Discovery via
-[config file](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/config.go).
+ aggregating alerts, and sending notifications. Please note, notifier address also supports Consul and DNS Service Discovery via
+ [config file](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app/vmalert/notifier/config.go).
* remote write address [optional] - [remote write](https://prometheus.io/docs/prometheus/latest/storage/#remote-storage-integrations)
compatible storage to persist rules and alerts state info;
* remote read address [optional] - MetricsQL compatible datasource to restore alerts state from.
@@ -151,12 +151,12 @@ expression and then act according to the Rule type.
There are two types of Rules:
* [alerting](https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/) -
-Alerting rules allow defining alert conditions via `expr` field and to send notifications to
-[Alertmanager](https://github.com/prometheus/alertmanager) if execution result is not empty.
+ Alerting rules allow defining alert conditions via `expr` field and to send notifications to
+ [Alertmanager](https://github.com/prometheus/alertmanager) if execution result is not empty.
* [recording](https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) -
-Recording rules allow defining `expr` which result will be then backfilled to configured
-`-remoteWrite.url`. Recording rules are used to precompute frequently needed or computationally
-expensive expressions and save their result as a new set of time series.
+ Recording rules allow defining `expr` which result will be then backfilled to configured
+ `-remoteWrite.url`. Recording rules are used to precompute frequently needed or computationally
+ expensive expressions and save their result as a new set of time series.
`vmalert` forbids defining duplicates - rules with the same combination of name, expression, and labels
within one group.
@@ -195,7 +195,11 @@ listed [here](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/app
#### Reusable templates
-Like in Alertmanager you can use reusable templates to share same templates across anotations. Path to files with templates is provided with `-rule.templates` cli argument. E.g:
+Like in Alertmanager you can define [reusable templates](https://prometheus.io/docs/prometheus/latest/configuration/template_examples/#defining-reusable-templates)
+to share same templates across annotations. Just define the templates in a file and
+set the path via `-rule.templates` flag.
+
+For example, the template can be defined as following:
`/etc/vmalert/templates/global/common.tpl`
@@ -210,6 +214,8 @@ Like in Alertmanager you can use reusable templates to share same templates acro
{{- end -}}
```
+And used in annotations:
+
`/etc/vmalert/rules/project/rule.yaml`
```yaml
@@ -226,16 +232,9 @@ groups:
dashboard: '{{ $externalURL }}/d/dashboard?orgId=1{{ template "grafana.filter" (args .CommonLabels "account_id" "any_label") }}'
```
-`vmalert` configuration flags:
+The `-rule.templates` flag supports wildcards so multiple files with templates can be loaded.
+The content of `-rule.templates` can be also [hot reloaded](#hot-config-reload).
-```
-./bin/vmalert -rule=/etc/vmalert/rules/**/*.yaml \ # Path to the fules with rules configuration
- -rule.templates=/etc/vmalert/templates/**/*.tpl \ # Path to the files with rule templates
- -datasource.url=http://victoriametrics:8428 \ # VM-single addr for executing rules expressions
- -remoteWrite.url=http://victoriametrics:8428 \ # VM-single addr to persist alerts state and recording rules results
- -remoteRead.url=http://victoriametrics:8428 \ # VM-single addr for restoring alerts state after restart
- -notifier.url=http://alertmanager:9093 # AlertManager addr to send alerts when they trigger
-```
#### Recording rules
@@ -263,11 +262,11 @@ For recording rules to work `-remoteWrite.url` must be specified.
the process alerts state will be lost. To avoid this situation, `vmalert` should be configured via the following flags:
* `-remoteWrite.url` - URL to VictoriaMetrics (Single) or vminsert (Cluster). `vmalert` will persist alerts state
-into the configured address in the form of time series named `ALERTS` and `ALERTS_FOR_STATE` via remote-write protocol.
-These are regular time series and maybe queried from VM just as any other time series.
-The state is stored to the configured address on every rule evaluation.
+ into the configured address in the form of time series named `ALERTS` and `ALERTS_FOR_STATE` via remote-write protocol.
+ These are regular time series and maybe queried from VM just as any other time series.
+ The state is stored to the configured address on every rule evaluation.
* `-remoteRead.url` - URL to VictoriaMetrics (Single) or vmselect (Cluster). `vmalert` will try to restore alerts state
-from configured address by querying time series with name `ALERTS_FOR_STATE`.
+ from configured address by querying time series with name `ALERTS_FOR_STATE`.
Both flags are required for proper state restoration. Restore process may fail if time series are missing
in configured `-remoteRead.url`, weren't updated in the last `1h` (controlled by `-remoteRead.lookback`)
@@ -323,7 +322,7 @@ for different scenarios.
Please note, not all flags in examples are required:
* `-remoteWrite.url` and `-remoteRead.url` are optional and are needed only if
-you have recording rules or want to store [alerts state](#alerts-state-on-restarts) on `vmalert` restarts;
+ you have recording rules or want to store [alerts state](#alerts-state-on-restarts) on `vmalert` restarts;
* `-notifier.url` is optional and is needed only if you have alerting rules.
#### Single-node VictoriaMetrics
@@ -432,7 +431,7 @@ See also [downsampling docs](https://docs.victoriametrics.com/#downsampling).
* `http:///api/v1/rules` - list of all loaded groups and rules;
* `http:///api/v1/alerts` - list of all active alerts;
* `http:///api/v1///status"` - get alert status by ID.
-Used as alert source in AlertManager.
+ Used as alert source in AlertManager.
* `http:///metrics` - application metrics.
* `http:///-/reload` - hot configuration reload.
@@ -521,17 +520,17 @@ Execute the query against storage which was used for `-remoteWrite.url` during t
There are following non-required `replay` flags:
* `-replay.maxDatapointsPerQuery` - the max number of data points expected to receive in one request.
-In two words, it affects the max time range for every `/query_range` request. The higher the value,
-the fewer requests will be issued during `replay`.
+ In two words, it affects the max time range for every `/query_range` request. The higher the value,
+ the fewer requests will be issued during `replay`.
* `-replay.ruleRetryAttempts` - when datasource fails to respond vmalert will make this number of retries
-per rule before giving up.
+ per rule before giving up.
* `-replay.rulesDelay` - delay between sequential rules execution. Important in cases if there are chaining
-(rules which depend on each other) rules. It is expected, that remote storage will be able to persist
-previously accepted data during the delay, so data will be available for the subsequent queries.
-Keep it equal or bigger than `-remoteWrite.flushInterval`.
+ (rules which depend on each other) rules. It is expected, that remote storage will be able to persist
+ previously accepted data during the delay, so data will be available for the subsequent queries.
+ Keep it equal or bigger than `-remoteWrite.flushInterval`.
* `replay.disableProgressBar` - whether to disable progress bar which shows progress work.
-Progress bar may generate a lot of log records, which is not formatted as standard VictoriaMetrics logger.
-It could break logs parsing by external system and generate additional load on it.
+ Progress bar may generate a lot of log records, which is not formatted as standard VictoriaMetrics logger.
+ It could break logs parsing by external system and generate additional load on it.
See full description for these flags in `./vmalert --help`.
@@ -875,7 +874,7 @@ The shortlist of configuration flags is the following:
* send SIGHUP signal to `vmalert` process;
* send GET request to `/-/reload` endpoint;
* configure `-configCheckInterval` flag for periodic reload
-on config change.
+ on config change.
### URL params
From 0d07166eed0b1af0c11cb6a34ce2d504e331aecf Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Sat, 14 May 2022 19:29:09 +0200
Subject: [PATCH 29/51] vmalert: fix readme formatting (#2587)
Signed-off-by: hagen1778
---
app/vmalert/README.md | 8 ++------
docs/vmalert.md | 8 ++------
2 files changed, 4 insertions(+), 12 deletions(-)
diff --git a/app/vmalert/README.md b/app/vmalert/README.md
index 2b12c8011f..e89fb259c0 100644
--- a/app/vmalert/README.md
+++ b/app/vmalert/README.md
@@ -195,9 +195,7 @@ Like in Alertmanager you can define [reusable templates](https://prometheus.io/d
to share same templates across annotations. Just define the templates in a file and
set the path via `-rule.templates` flag.
-For example, the template can be defined as following:
-
-`/etc/vmalert/templates/global/common.tpl`
+For example, template `grafana.filter` can be defined as following:
```
{{ define "grafana.filter" -}}
@@ -210,9 +208,7 @@ For example, the template can be defined as following:
{{- end -}}
```
-And used in annotations:
-
-`/etc/vmalert/rules/project/rule.yaml`
+And then used in annotations:
```yaml
groups:
diff --git a/docs/vmalert.md b/docs/vmalert.md
index c2365a8f7a..d7e4d53b01 100644
--- a/docs/vmalert.md
+++ b/docs/vmalert.md
@@ -199,9 +199,7 @@ Like in Alertmanager you can define [reusable templates](https://prometheus.io/d
to share same templates across annotations. Just define the templates in a file and
set the path via `-rule.templates` flag.
-For example, the template can be defined as following:
-
-`/etc/vmalert/templates/global/common.tpl`
+For example, template `grafana.filter` can be defined as following:
```
{{ define "grafana.filter" -}}
@@ -214,9 +212,7 @@ For example, the template can be defined as following:
{{- end -}}
```
-And used in annotations:
-
-`/etc/vmalert/rules/project/rule.yaml`
+And then used in annotations:
```yaml
groups:
From 8402231d402351155811b8e0de6b08bc56f04d70 Mon Sep 17 00:00:00 2001
From: Dima Lazerka
Date: Tue, 10 May 2022 11:15:40 +0200
Subject: [PATCH 30/51] Force up nth-check version
---
app/vmui/packages/vmui/package-lock.json | 669 ++++++++++++-----------
app/vmui/packages/vmui/package.json | 6 +-
2 files changed, 359 insertions(+), 316 deletions(-)
diff --git a/app/vmui/packages/vmui/package-lock.json b/app/vmui/packages/vmui/package-lock.json
index 16d7cf5a85..320d99a26a 100644
--- a/app/vmui/packages/vmui/package-lock.json
+++ b/app/vmui/packages/vmui/package-lock.json
@@ -2398,20 +2398,20 @@
"integrity": "sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA=="
},
"node_modules/@eslint/eslintrc": {
- "version": "1.2.2",
- "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.2.2.tgz",
- "integrity": "sha512-lTVWHs7O2hjBFZunXTZYnYqtB9GakA1lnxIf+gKq2nY5gxkkNi/lQvveW6t8gFdOHTg6nG50Xs95PrLqVpcaLg==",
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.2.3.tgz",
+ "integrity": "sha512-uGo44hIwoLGNyduRpjdEpovcbMdd+Nv7amtmJxnKmI8xj6yd5LncmSwDa5NgX/41lIFJtkjD6YdVfgEzPfJ5UA==",
"dev": true,
"peer": true,
"dependencies": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
- "espree": "^9.3.1",
+ "espree": "^9.3.2",
"globals": "^13.9.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
"js-yaml": "^4.1.0",
- "minimatch": "^3.0.4",
+ "minimatch": "^3.1.2",
"strip-json-comments": "^3.1.1"
},
"engines": {
@@ -2419,9 +2419,9 @@
}
},
"node_modules/@eslint/eslintrc/node_modules/globals": {
- "version": "13.13.0",
- "resolved": "https://registry.npmjs.org/globals/-/globals-13.13.0.tgz",
- "integrity": "sha512-EQ7Q18AJlPwp3vUDL4mKA0KXrXyNIQyWon6T6XQiBQF0XHvRsiCSrWmmeATpUzdJN2HhWZU6Pdl0a9zdep5p6A==",
+ "version": "13.14.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.14.0.tgz",
+ "integrity": "sha512-ERO68sOYwm5UuLvSJTY7w7NP2c8S4UcXs3X1GBX8cwOr+ShOcDBbCY5mH4zxz0jsYCdJ8ve8Mv9n2YGJMB1aeg==",
"dev": true,
"peer": true,
"dependencies": {
@@ -3284,33 +3284,33 @@
}
},
"node_modules/@jridgewell/resolve-uri": {
- "version": "3.0.6",
- "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.0.6.tgz",
- "integrity": "sha512-R7xHtBSNm+9SyvpJkdQl+qrM3Hm2fea3Ef197M3mUug+v+yR+Rhfbs7PBtcBUVnIWJ4JcAdjvij+c8hXS9p5aw==",
+ "version": "3.0.7",
+ "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.0.7.tgz",
+ "integrity": "sha512-8cXDaBBHOr2pQ7j77Y6Vp5VDT2sIqWyWQ56TjEq4ih/a4iST3dItRe8Q9fp0rrIl9DoKhWQtUQz/YpOxLkXbNA==",
"peer": true,
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/@jridgewell/set-array": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.0.tgz",
- "integrity": "sha512-SfJxIxNVYLTsKwzB3MoOQ1yxf4w/E6MdkvTgrgAt1bfxjSrLUoHMKrDOykwN14q65waezZIdqDneUIPh4/sKxg==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.1.tgz",
+ "integrity": "sha512-Ct5MqZkLGEXTVmQYbGtx9SVqD2fqwvdubdps5D3djjAkgkKwT918VNOz65pEHFaYTeWcukmJmH5SwsA9Tn2ObQ==",
"peer": true,
"engines": {
"node": ">=6.0.0"
}
},
"node_modules/@jridgewell/sourcemap-codec": {
- "version": "1.4.12",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.12.tgz",
- "integrity": "sha512-az/NhpIwP3K33ILr0T2bso+k2E/SLf8Yidd8mHl0n6sCQ4YdyC8qDhZA6kOPDNDBA56ZnIjngVl0U3jREA0BUA==",
+ "version": "1.4.13",
+ "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz",
+ "integrity": "sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w==",
"peer": true
},
"node_modules/@jridgewell/trace-mapping": {
- "version": "0.3.9",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz",
- "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==",
+ "version": "0.3.10",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.10.tgz",
+ "integrity": "sha512-Q0YbBd6OTsXm8Y21+YUSDXupHnodNC2M4O18jtd3iwJ3+vMZNdKGols0a9G6JOK0dcJ3IdUUHoh908ZI6qhk8Q==",
"peer": true,
"dependencies": {
"@jridgewell/resolve-uri": "^3.0.3",
@@ -3318,9 +3318,9 @@
}
},
"node_modules/@leichtgewicht/ip-codec": {
- "version": "2.0.3",
- "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.3.tgz",
- "integrity": "sha512-nkalE/f1RvRGChwBnEIoBfSEYOXnCRdleKuv6+lePbMDrMZXeDQnqak5XDOeBgrPPyPfAdcCu/B5z+v3VhplGg==",
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz",
+ "integrity": "sha512-Hcv+nVC0kZnQ3tD9GVu5xSMR4VVYOteQIr/hwFPVEvPdlXqgGEuRjiheChHgdM+JyqdgNcmzZOX/tnl0JOiI7A==",
"dev": true,
"peer": true
},
@@ -4680,9 +4680,9 @@
"peer": true
},
"node_modules/@types/react": {
- "version": "18.0.8",
- "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.8.tgz",
- "integrity": "sha512-+j2hk9BzCOrrOSJASi5XiOyBbERk9jG5O73Ya4M0env5Ixi6vUNli4qy994AINcEF+1IEHISYFfIT4zwr++LKw==",
+ "version": "18.0.9",
+ "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.9.tgz",
+ "integrity": "sha512-9bjbg1hJHUm4De19L1cHiW0Jvx3geel6Qczhjd0qY5VKVE2X5+x77YxAepuCwVh4vrgZJdgEJw48zrhRIeF4Nw==",
"dependencies": {
"@types/prop-types": "*",
"@types/scheduler": "*",
@@ -4840,14 +4840,14 @@
"peer": true
},
"node_modules/@typescript-eslint/eslint-plugin": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.22.0.tgz",
- "integrity": "sha512-YCiy5PUzpAeOPGQ7VSGDEY2NeYUV1B0swde2e0HzokRsHBYjSdF6DZ51OuRZxVPHx0032lXGLvOMls91D8FXlg==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.23.0.tgz",
+ "integrity": "sha512-hEcSmG4XodSLiAp1uxv/OQSGsDY6QN3TcRU32gANp+19wGE1QQZLRS8/GV58VRUoXhnkuJ3ZxNQ3T6Z6zM59DA==",
"dev": true,
"dependencies": {
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/type-utils": "5.22.0",
- "@typescript-eslint/utils": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/type-utils": "5.23.0",
+ "@typescript-eslint/utils": "5.23.0",
"debug": "^4.3.2",
"functional-red-black-tree": "^1.0.1",
"ignore": "^5.1.8",
@@ -4888,13 +4888,13 @@
}
},
"node_modules/@typescript-eslint/experimental-utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-5.22.0.tgz",
- "integrity": "sha512-rKxoCUtAHwEH6IcAoVpqipY6Th+YKW7WFspAKu0IFdbdKZpveFBeqxxE9Xn+GWikhq1o03V3VXbxIe+GdhggiQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-5.23.0.tgz",
+ "integrity": "sha512-I+3YGQztH1DM9kgWzjslpZzJCBMRz0KhYG2WP62IwpooeZ1L6Qt0mNK8zs+uP+R2HOsr+TeDW35Pitc3PfVv8Q==",
"dev": true,
"peer": true,
"dependencies": {
- "@typescript-eslint/utils": "5.22.0"
+ "@typescript-eslint/utils": "5.23.0"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -4908,14 +4908,14 @@
}
},
"node_modules/@typescript-eslint/parser": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.22.0.tgz",
- "integrity": "sha512-piwC4krUpRDqPaPbFaycN70KCP87+PC5WZmrWs+DlVOxxmF+zI6b6hETv7Quy4s9wbkV16ikMeZgXsvzwI3icQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.23.0.tgz",
+ "integrity": "sha512-V06cYUkqcGqpFjb8ttVgzNF53tgbB/KoQT/iB++DOIExKmzI9vBJKjZKt/6FuV9c+zrDsvJKbJ2DOCYwX91cbw==",
"dev": true,
"dependencies": {
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/typescript-estree": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/typescript-estree": "5.23.0",
"debug": "^4.3.2"
},
"engines": {
@@ -4935,13 +4935,13 @@
}
},
"node_modules/@typescript-eslint/scope-manager": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.22.0.tgz",
- "integrity": "sha512-yA9G5NJgV5esANJCO0oF15MkBO20mIskbZ8ijfmlKIvQKg0ynVKfHZ15/nhAJN5m8Jn3X5qkwriQCiUntC9AbA==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.23.0.tgz",
+ "integrity": "sha512-EhjaFELQHCRb5wTwlGsNMvzK9b8Oco4aYNleeDlNuL6qXWDF47ch4EhVNPh8Rdhf9tmqbN4sWDk/8g+Z/J8JVw==",
"dev": true,
"dependencies": {
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/visitor-keys": "5.22.0"
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/visitor-keys": "5.23.0"
},
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -4952,12 +4952,12 @@
}
},
"node_modules/@typescript-eslint/type-utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.22.0.tgz",
- "integrity": "sha512-iqfLZIsZhK2OEJ4cQ01xOq3NaCuG5FQRKyHicA3xhZxMgaxQazLUHbH/B2k9y5i7l3+o+B5ND9Mf1AWETeMISA==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.23.0.tgz",
+ "integrity": "sha512-iuI05JsJl/SUnOTXA9f4oI+/4qS/Zcgk+s2ir+lRmXI+80D8GaGwoUqs4p+X+4AxDolPpEpVUdlEH4ADxFy4gw==",
"dev": true,
"dependencies": {
- "@typescript-eslint/utils": "5.22.0",
+ "@typescript-eslint/utils": "5.23.0",
"debug": "^4.3.2",
"tsutils": "^3.21.0"
},
@@ -4978,9 +4978,9 @@
}
},
"node_modules/@typescript-eslint/types": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.22.0.tgz",
- "integrity": "sha512-T7owcXW4l0v7NTijmjGWwWf/1JqdlWiBzPqzAWhobxft0SiEvMJB56QXmeCQjrPuM8zEfGUKyPQr/L8+cFUBLw==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.23.0.tgz",
+ "integrity": "sha512-NfBsV/h4dir/8mJwdZz7JFibaKC3E/QdeMEDJhiAE3/eMkoniZ7MjbEMCGXw6MZnZDMN3G9S0mH/6WUIj91dmw==",
"dev": true,
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -4991,13 +4991,13 @@
}
},
"node_modules/@typescript-eslint/typescript-estree": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.22.0.tgz",
- "integrity": "sha512-EyBEQxvNjg80yinGE2xdhpDYm41so/1kOItl0qrjIiJ1kX/L/L8WWGmJg8ni6eG3DwqmOzDqOhe6763bF92nOw==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.23.0.tgz",
+ "integrity": "sha512-xE9e0lrHhI647SlGMl+m+3E3CKPF1wzvvOEWnuE3CCjjT7UiRnDGJxmAcVKJIlFgK6DY9RB98eLr1OPigPEOGg==",
"dev": true,
"dependencies": {
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/visitor-keys": "5.22.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/visitor-keys": "5.23.0",
"debug": "^4.3.2",
"globby": "^11.0.4",
"is-glob": "^4.0.3",
@@ -5033,15 +5033,15 @@
}
},
"node_modules/@typescript-eslint/utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.22.0.tgz",
- "integrity": "sha512-HodsGb037iobrWSUMS7QH6Hl1kppikjA1ELiJlNSTYf/UdMEwzgj0WIp+lBNb6WZ3zTwb0tEz51j0Wee3iJ3wQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.23.0.tgz",
+ "integrity": "sha512-dbgaKN21drqpkbbedGMNPCtRPZo1IOUr5EI9Jrrh99r5UW5Q0dz46RKXeSBoPV+56R6dFKpbrdhgUNSJsDDRZA==",
"dev": true,
"dependencies": {
"@types/json-schema": "^7.0.9",
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/typescript-estree": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/typescript-estree": "5.23.0",
"eslint-scope": "^5.1.1",
"eslint-utils": "^3.0.0"
},
@@ -5057,12 +5057,12 @@
}
},
"node_modules/@typescript-eslint/visitor-keys": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.22.0.tgz",
- "integrity": "sha512-DbgTqn2Dv5RFWluG88tn0pP6Ex0ROF+dpDO1TNNZdRtLjUr6bdznjA6f/qNqJLjd2PgguAES2Zgxh/JzwzETDg==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.23.0.tgz",
+ "integrity": "sha512-Vd4mFNchU62sJB8pX19ZSPog05B0Y0CE2UxAZPT5k4iqhRYjPnqyY3woMxCd0++t9OTqkgjST+1ydLBi7e2Fvg==",
"dev": true,
"dependencies": {
- "@typescript-eslint/types": "5.22.0",
+ "@typescript-eslint/types": "5.23.0",
"eslint-visitor-keys": "^3.0.0"
},
"engines": {
@@ -6379,9 +6379,9 @@
}
},
"node_modules/caniuse-lite": {
- "version": "1.0.30001336",
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001336.tgz",
- "integrity": "sha512-/YxSlBmL7iKXTbIJ48IQTnAOBk7XmWsxhBF1PZLOko5Dt9qc4Pl+84lfqG3Tc4EuavurRn1QLoVJGxY2iSycfw==",
+ "version": "1.0.30001339",
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001339.tgz",
+ "integrity": "sha512-Es8PiVqCe+uXdms0Gu5xP5PF2bxLR7OBp3wUzUnuO7OHzhOfCyg3hdiGWVPVxhiuniOzng+hTc1u3fEQ0TlkSQ==",
"funding": [
{
"type": "opencollective",
@@ -7415,9 +7415,9 @@
}
},
"node_modules/dayjs": {
- "version": "1.11.1",
- "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.1.tgz",
- "integrity": "sha512-ER7EjqVAMkRRsxNCC5YqJ9d9VQYuWdGt7aiH2qA5R5wt8ZmWaP2dLUSIK6y/kVzLMlmh1Tvu5xUf4M/wdGJ5KA=="
+ "version": "1.11.2",
+ "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.2.tgz",
+ "integrity": "sha512-F4LXf1OeU9hrSYRPTTj/6FbO4HTjPKXvEIC1P2kcnFurViINCVk3ZV0xAS3XVx9MkMsXbbqlK6hjseaYbgKEHw=="
},
"node_modules/debug": {
"version": "4.3.4",
@@ -7853,9 +7853,9 @@
}
},
"node_modules/electron-to-chromium": {
- "version": "1.4.134",
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.134.tgz",
- "integrity": "sha512-OdD7M2no4Mi8PopfvoOuNcwYDJ2mNFxaBfurA6okG3fLBaMcFah9S+si84FhX+FIWLKkdaiHfl4A+5ep/gOVrg==",
+ "version": "1.4.137",
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.137.tgz",
+ "integrity": "sha512-0Rcpald12O11BUogJagX3HsCN3FE83DSqWjgXoHo5a72KUKMSfI39XBgJpgNNxS9fuGzytaFjE06kZkiVFy2qA==",
"peer": true
},
"node_modules/emittery": {
@@ -7941,17 +7941,19 @@
}
},
"node_modules/es-abstract": {
- "version": "1.19.5",
- "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.19.5.tgz",
- "integrity": "sha512-Aa2G2+Rd3b6kxEUKTF4TaW67czBLyAv3z7VOhYRU50YBx+bbsYZ9xQP4lMNazePuFlybXI0V4MruPos7qUo5fA==",
+ "version": "1.20.0",
+ "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.20.0.tgz",
+ "integrity": "sha512-URbD8tgRthKD3YcC39vbvSDrX23upXnPcnGAjQfgxXF5ID75YcENawc9ZX/9iTP9ptUyfCLIxTTuMYoRfiOVKA==",
"dev": true,
"dependencies": {
"call-bind": "^1.0.2",
"es-to-primitive": "^1.2.1",
"function-bind": "^1.1.1",
+ "function.prototype.name": "^1.1.5",
"get-intrinsic": "^1.1.1",
"get-symbol-description": "^1.0.0",
"has": "^1.0.3",
+ "has-property-descriptors": "^1.0.0",
"has-symbols": "^1.0.3",
"internal-slot": "^1.0.3",
"is-callable": "^1.2.4",
@@ -7963,9 +7965,10 @@
"object-inspect": "^1.12.0",
"object-keys": "^1.1.1",
"object.assign": "^4.1.2",
- "string.prototype.trimend": "^1.0.4",
- "string.prototype.trimstart": "^1.0.4",
- "unbox-primitive": "^1.0.1"
+ "regexp.prototype.flags": "^1.4.1",
+ "string.prototype.trimend": "^1.0.5",
+ "string.prototype.trimstart": "^1.0.5",
+ "unbox-primitive": "^1.0.2"
},
"engines": {
"node": ">= 0.4"
@@ -8124,13 +8127,13 @@
}
},
"node_modules/eslint": {
- "version": "8.14.0",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.14.0.tgz",
- "integrity": "sha512-3/CE4aJX7LNEiE3i6FeodHmI/38GZtWCsAtsymScmzYapx8q1nVVb+eLcLSzATmCPXw5pT4TqVs1E0OmxAd9tw==",
+ "version": "8.15.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.15.0.tgz",
+ "integrity": "sha512-GG5USZ1jhCu8HJkzGgeK8/+RGnHaNYZGrGDzUtigK3BsGESW/rs2az23XqE0WVwDxy1VRvvjSSGu5nB0Bu+6SA==",
"dev": true,
"peer": true,
"dependencies": {
- "@eslint/eslintrc": "^1.2.2",
+ "@eslint/eslintrc": "^1.2.3",
"@humanwhocodes/config-array": "^0.9.2",
"ajv": "^6.10.0",
"chalk": "^4.0.0",
@@ -8141,7 +8144,7 @@
"eslint-scope": "^7.1.1",
"eslint-utils": "^3.0.0",
"eslint-visitor-keys": "^3.3.0",
- "espree": "^9.3.1",
+ "espree": "^9.3.2",
"esquery": "^1.4.0",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
@@ -8157,7 +8160,7 @@
"json-stable-stringify-without-jsonify": "^1.0.1",
"levn": "^0.4.1",
"lodash.merge": "^4.6.2",
- "minimatch": "^3.0.4",
+ "minimatch": "^3.1.2",
"natural-compare": "^1.4.0",
"optionator": "^0.9.1",
"regexpp": "^3.2.0",
@@ -8533,9 +8536,9 @@
}
},
"node_modules/eslint-plugin-testing-library": {
- "version": "5.3.1",
- "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-5.3.1.tgz",
- "integrity": "sha512-OfF4dlG/q6ck6DL3P8Z0FPdK0dU5K57gsBu7eUcaVbwYKaNzjgejnXiM9CCUevppORkvfek+9D3Uj/9ZZ8Vz8g==",
+ "version": "5.4.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-5.4.0.tgz",
+ "integrity": "sha512-XjxIf4g33KaZXxRNbR33+0WcRQ/zt8N0R58IY6/kkHnrY6zPsC1gs3u5cTZr5eUmCZN/sjoPak3uF5vHGKg2wg==",
"dev": true,
"peer": true,
"dependencies": {
@@ -8700,9 +8703,9 @@
}
},
"node_modules/eslint/node_modules/globals": {
- "version": "13.13.0",
- "resolved": "https://registry.npmjs.org/globals/-/globals-13.13.0.tgz",
- "integrity": "sha512-EQ7Q18AJlPwp3vUDL4mKA0KXrXyNIQyWon6T6XQiBQF0XHvRsiCSrWmmeATpUzdJN2HhWZU6Pdl0a9zdep5p6A==",
+ "version": "13.14.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.14.0.tgz",
+ "integrity": "sha512-ERO68sOYwm5UuLvSJTY7w7NP2c8S4UcXs3X1GBX8cwOr+ShOcDBbCY5mH4zxz0jsYCdJ8ve8Mv9n2YGJMB1aeg==",
"dev": true,
"peer": true,
"dependencies": {
@@ -8752,14 +8755,14 @@
}
},
"node_modules/espree": {
- "version": "9.3.1",
- "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.1.tgz",
- "integrity": "sha512-bvdyLmJMfwkV3NCRl5ZhJf22zBFo1y8bYh3VYb+bfzqNB4Je68P2sSuXyuFquzWLebHpNd2/d5uv7yoP9ISnGQ==",
+ "version": "9.3.2",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.2.tgz",
+ "integrity": "sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA==",
"dev": true,
"peer": true,
"dependencies": {
- "acorn": "^8.7.0",
- "acorn-jsx": "^5.3.1",
+ "acorn": "^8.7.1",
+ "acorn-jsx": "^5.3.2",
"eslint-visitor-keys": "^3.3.0"
},
"engines": {
@@ -9538,11 +9541,44 @@
"dev": true,
"peer": true
},
+ "node_modules/fsevents": {
+ "version": "2.3.2",
+ "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
+ "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
+ "dev": true,
+ "hasInstallScript": true,
+ "optional": true,
+ "os": [
+ "darwin"
+ ],
+ "peer": true,
+ "engines": {
+ "node": "^8.16.0 || ^10.6.0 || >=11.0.0"
+ }
+ },
"node_modules/function-bind": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
"integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A=="
},
+ "node_modules/function.prototype.name": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz",
+ "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==",
+ "dev": true,
+ "dependencies": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.19.0",
+ "functions-have-names": "^1.2.2"
+ },
+ "engines": {
+ "node": ">= 0.4"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/ljharb"
+ }
+ },
"node_modules/functional-red-black-tree": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz",
@@ -12503,17 +12539,17 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/@jest/console": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/console/-/console-28.0.2.tgz",
- "integrity": "sha512-tiRpnMeeyQuuzgL5UNSeiqMwF8UOWPbAE5rzcu/1zyq4oPG2Ox6xm4YCOruwbp10F8odWc+XwVxTyGzMSLMqxA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/console/-/console-28.1.0.tgz",
+ "integrity": "sha512-tscn3dlJFGay47kb4qVruQg/XWlmvU0xp3EJOjzzY+sBaI+YgwKcvAmTcyYU7xEiLLIY5HCdWRooAL8dqkFlDA==",
"dev": true,
"peer": true,
"dependencies": {
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"chalk": "^4.0.0",
- "jest-message-util": "^28.0.2",
- "jest-util": "^28.0.2",
+ "jest-message-util": "^28.1.0",
+ "jest-util": "^28.1.0",
"slash": "^3.0.0"
},
"engines": {
@@ -12531,14 +12567,14 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/@jest/test-result": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-28.0.2.tgz",
- "integrity": "sha512-4EUqgjq9VzyUiVTvZfI9IRJD6t3NYBNP4f+Eq8Zr93+hkJ0RrGU4OBTw8tfNzidKX+bmuYzn8FxqpxOPIGGCMA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-28.1.0.tgz",
+ "integrity": "sha512-sBBFIyoPzrZho3N+80P35A5oAkSKlGfsEFfXFWuPGBsW40UAjCkGakZhn4UQK4iQlW2vgCDMRDOob9FGKV8YoQ==",
"dev": true,
"peer": true,
"dependencies": {
- "@jest/console": "^28.0.2",
- "@jest/types": "^28.0.2",
+ "@jest/console": "^28.1.0",
+ "@jest/types": "^28.1.0",
"@types/istanbul-lib-coverage": "^2.0.0",
"collect-v8-coverage": "^1.0.0"
},
@@ -12547,9 +12583,9 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/@jest/types": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/types/-/types-28.0.2.tgz",
- "integrity": "sha512-hi3jUdm9iht7I2yrV5C4s3ucCJHUP8Eh3W6rQ1s4n/Qw9rQgsda4eqCt+r3BKRi7klVmZfQlMx1nGlzNMP2d8A==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/types/-/types-28.1.0.tgz",
+ "integrity": "sha512-xmEggMPr317MIOjjDoZ4ejCSr9Lpbt/u34+dvc99t7DS8YirW5rwZEhzKPC2BMUFkUhI48qs6qLUSGw5FuL0GA==",
"dev": true,
"peer": true,
"dependencies": {
@@ -12651,19 +12687,19 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/jest-message-util": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-28.0.2.tgz",
- "integrity": "sha512-knK7XyojvwYh1XiF2wmVdskgM/uN11KsjcEWWHfnMZNEdwXCrqB4sCBO94F4cfiAwCS8WFV6CDixDwPlMh/wdA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-28.1.0.tgz",
+ "integrity": "sha512-RpA8mpaJ/B2HphDMiDlrAZdDytkmwFqgjDZovM21F35lHGeUeCvYmm6W+sbQ0ydaLpg5bFAUuWG1cjqOl8vqrw==",
"dev": true,
"peer": true,
"dependencies": {
"@babel/code-frame": "^7.12.13",
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/stack-utils": "^2.0.0",
"chalk": "^4.0.0",
"graceful-fs": "^4.2.9",
"micromatch": "^4.0.4",
- "pretty-format": "^28.0.2",
+ "pretty-format": "^28.1.0",
"slash": "^3.0.0",
"stack-utils": "^2.0.3"
},
@@ -12692,13 +12728,13 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/jest-util": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-28.0.2.tgz",
- "integrity": "sha512-EVdpIRCC8lzqhp9A0u0aAKlsFIzufK6xKxNK7awsnebTdOP4hpyQW5o6Ox2qPl8gbeUKYF+POLyItaND53kpGA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-28.1.0.tgz",
+ "integrity": "sha512-qYdCKD77k4Hwkose2YBEqQk7PzUf/NSE+rutzceduFveQREeH6b+89Dc9+wjX9dAwHcgdx4yedGA3FQlU/qCTA==",
"dev": true,
"peer": true,
"dependencies": {
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"chalk": "^4.0.0",
"ci-info": "^3.2.0",
@@ -12710,19 +12746,19 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/jest-watcher": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-28.0.2.tgz",
- "integrity": "sha512-uIVJLpQ/5VTGQWBiBatHsi7jrCqHjHl0e0dFHMWzwuIfUbdW/muk0DtSr0fteY2T7QTFylv+7a5Rm8sBKrE12Q==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-28.1.0.tgz",
+ "integrity": "sha512-tNHMtfLE8Njcr2IRS+5rXYA4BhU90gAOwI9frTGOqd+jX0P/Au/JfRSNqsf5nUTcWdbVYuLxS1KjnzILSoR5hA==",
"dev": true,
"peer": true,
"dependencies": {
- "@jest/test-result": "^28.0.2",
- "@jest/types": "^28.0.2",
+ "@jest/test-result": "^28.1.0",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"ansi-escapes": "^4.2.1",
"chalk": "^4.0.0",
"emittery": "^0.10.2",
- "jest-util": "^28.0.2",
+ "jest-util": "^28.1.0",
"string-length": "^4.0.1"
},
"engines": {
@@ -12757,9 +12793,9 @@
}
},
"node_modules/jest-watch-typeahead/node_modules/pretty-format": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-28.0.2.tgz",
- "integrity": "sha512-UmGZ1IERwS3yY35LDMTaBUYI1w4udZDdJGGT/DqQeKG9ZLDn7/K2Jf/JtYSRiHCCKMHvUA+zsEGSmHdpaVp1yw==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-28.1.0.tgz",
+ "integrity": "sha512-79Z4wWOYCdvQkEoEuSlBhHJqWeZ8D8YRPiPctJFCtvuaClGpiwiQYSCUOE6IEKUbbFukKOTFIUAXE8N4EQTo1Q==",
"dev": true,
"peer": true,
"dependencies": {
@@ -13942,13 +13978,13 @@
}
},
"node_modules/object.hasown": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/object.hasown/-/object.hasown-1.1.0.tgz",
- "integrity": "sha512-MhjYRfj3GBlhSkDHo6QmvgjRLXQ2zndabdf3nX0yTyZK9rPfxb6uRpAac8HXNLy1GpqWtZ81Qh4v3uOls2sRAg==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object.hasown/-/object.hasown-1.1.1.tgz",
+ "integrity": "sha512-LYLe4tivNQzq4JdaWW6WO3HMZZJWzkkH8fnI6EebWl0VZth2wL2Lovm74ep2/gZzlaTdV62JZHEqHQ2yVn8Q/A==",
"dev": true,
"dependencies": {
- "define-properties": "^1.1.3",
- "es-abstract": "^1.19.1"
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.19.5"
},
"funding": {
"url": "https://github.com/sponsors/ljharb"
@@ -15488,9 +15524,9 @@
}
},
"node_modules/postcss-pseudo-class-any-link": {
- "version": "7.1.2",
- "resolved": "https://registry.npmjs.org/postcss-pseudo-class-any-link/-/postcss-pseudo-class-any-link-7.1.2.tgz",
- "integrity": "sha512-76XzEQv3g+Vgnz3tmqh3pqQyRojkcJ+pjaePsyhcyf164p9aZsu3t+NWxkZYbcHLK1ju5Qmalti2jPI5IWCe5w==",
+ "version": "7.1.3",
+ "resolved": "https://registry.npmjs.org/postcss-pseudo-class-any-link/-/postcss-pseudo-class-any-link-7.1.3.tgz",
+ "integrity": "sha512-I9Yp1VV2r8xFwg/JrnAlPCcKmutv6f6Ig6/CHFPqGJiDgYXM9C+0kgLfK4KOXbKNw+63QYl4agRUB0Wi9ftUIg==",
"dev": true,
"peer": true,
"dependencies": {
@@ -15681,9 +15717,9 @@
"peer": true
},
"node_modules/preact": {
- "version": "10.7.1",
- "resolved": "https://registry.npmjs.org/preact/-/preact-10.7.1.tgz",
- "integrity": "sha512-MufnRFz39aIhs9AMFisonjzTud1PK1bY+jcJLo6m2T9Uh8AqjD77w11eAAawmjUogoGOnipECq7e/1RClIKsxg==",
+ "version": "10.7.2",
+ "resolved": "https://registry.npmjs.org/preact/-/preact-10.7.2.tgz",
+ "integrity": "sha512-GLjn0I3r6ka+NvxJUppsVFqb4V0qDTEHT/QxHlidPuClGaxF/4AI2Qti4a0cv3XMh5n1+D3hLScW10LRIm5msQ==",
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/preact"
@@ -16703,9 +16739,9 @@
}
},
"node_modules/rollup": {
- "version": "2.72.0",
- "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.72.0.tgz",
- "integrity": "sha512-KqtR2YcO35/KKijg4nx4STO3569aqCUeGRkKWnJ6r+AvBBrVY9L4pmf4NHVrQr4mTOq6msbohflxr2kpihhaOA==",
+ "version": "2.72.1",
+ "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.72.1.tgz",
+ "integrity": "sha512-NTc5UGy/NWFGpSqF1lFY8z9Adri6uhyMLI6LvPAXdBKoPRFhIIiBUpt+Qg2awixqO3xvzSijjhnb4+QEZwJmxA==",
"dev": true,
"peer": true,
"bin": {
@@ -17772,16 +17808,6 @@
"js-yaml": "bin/js-yaml.js"
}
},
- "node_modules/svgo/node_modules/nth-check": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz",
- "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==",
- "dev": true,
- "peer": true,
- "dependencies": {
- "boolbase": "~1.0.0"
- }
- },
"node_modules/symbol-tree": {
"version": "3.2.4",
"resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.4.tgz",
@@ -21161,27 +21187,27 @@
"integrity": "sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA=="
},
"@eslint/eslintrc": {
- "version": "1.2.2",
- "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.2.2.tgz",
- "integrity": "sha512-lTVWHs7O2hjBFZunXTZYnYqtB9GakA1lnxIf+gKq2nY5gxkkNi/lQvveW6t8gFdOHTg6nG50Xs95PrLqVpcaLg==",
+ "version": "1.2.3",
+ "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-1.2.3.tgz",
+ "integrity": "sha512-uGo44hIwoLGNyduRpjdEpovcbMdd+Nv7amtmJxnKmI8xj6yd5LncmSwDa5NgX/41lIFJtkjD6YdVfgEzPfJ5UA==",
"dev": true,
"peer": true,
"requires": {
"ajv": "^6.12.4",
"debug": "^4.3.2",
- "espree": "^9.3.1",
+ "espree": "^9.3.2",
"globals": "^13.9.0",
"ignore": "^5.2.0",
"import-fresh": "^3.2.1",
"js-yaml": "^4.1.0",
- "minimatch": "^3.0.4",
+ "minimatch": "^3.1.2",
"strip-json-comments": "^3.1.1"
},
"dependencies": {
"globals": {
- "version": "13.13.0",
- "resolved": "https://registry.npmjs.org/globals/-/globals-13.13.0.tgz",
- "integrity": "sha512-EQ7Q18AJlPwp3vUDL4mKA0KXrXyNIQyWon6T6XQiBQF0XHvRsiCSrWmmeATpUzdJN2HhWZU6Pdl0a9zdep5p6A==",
+ "version": "13.14.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.14.0.tgz",
+ "integrity": "sha512-ERO68sOYwm5UuLvSJTY7w7NP2c8S4UcXs3X1GBX8cwOr+ShOcDBbCY5mH4zxz0jsYCdJ8ve8Mv9n2YGJMB1aeg==",
"dev": true,
"peer": true,
"requires": {
@@ -21846,27 +21872,27 @@
}
},
"@jridgewell/resolve-uri": {
- "version": "3.0.6",
- "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.0.6.tgz",
- "integrity": "sha512-R7xHtBSNm+9SyvpJkdQl+qrM3Hm2fea3Ef197M3mUug+v+yR+Rhfbs7PBtcBUVnIWJ4JcAdjvij+c8hXS9p5aw==",
+ "version": "3.0.7",
+ "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.0.7.tgz",
+ "integrity": "sha512-8cXDaBBHOr2pQ7j77Y6Vp5VDT2sIqWyWQ56TjEq4ih/a4iST3dItRe8Q9fp0rrIl9DoKhWQtUQz/YpOxLkXbNA==",
"peer": true
},
"@jridgewell/set-array": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.0.tgz",
- "integrity": "sha512-SfJxIxNVYLTsKwzB3MoOQ1yxf4w/E6MdkvTgrgAt1bfxjSrLUoHMKrDOykwN14q65waezZIdqDneUIPh4/sKxg==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.1.tgz",
+ "integrity": "sha512-Ct5MqZkLGEXTVmQYbGtx9SVqD2fqwvdubdps5D3djjAkgkKwT918VNOz65pEHFaYTeWcukmJmH5SwsA9Tn2ObQ==",
"peer": true
},
"@jridgewell/sourcemap-codec": {
- "version": "1.4.12",
- "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.12.tgz",
- "integrity": "sha512-az/NhpIwP3K33ILr0T2bso+k2E/SLf8Yidd8mHl0n6sCQ4YdyC8qDhZA6kOPDNDBA56ZnIjngVl0U3jREA0BUA==",
+ "version": "1.4.13",
+ "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.13.tgz",
+ "integrity": "sha512-GryiOJmNcWbovBxTfZSF71V/mXbgcV3MewDe3kIMCLyIh5e7SKAeUZs+rMnJ8jkMolZ/4/VsdBmMrw3l+VdZ3w==",
"peer": true
},
"@jridgewell/trace-mapping": {
- "version": "0.3.9",
- "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz",
- "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==",
+ "version": "0.3.10",
+ "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.10.tgz",
+ "integrity": "sha512-Q0YbBd6OTsXm8Y21+YUSDXupHnodNC2M4O18jtd3iwJ3+vMZNdKGols0a9G6JOK0dcJ3IdUUHoh908ZI6qhk8Q==",
"peer": true,
"requires": {
"@jridgewell/resolve-uri": "^3.0.3",
@@ -21874,9 +21900,9 @@
}
},
"@leichtgewicht/ip-codec": {
- "version": "2.0.3",
- "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.3.tgz",
- "integrity": "sha512-nkalE/f1RvRGChwBnEIoBfSEYOXnCRdleKuv6+lePbMDrMZXeDQnqak5XDOeBgrPPyPfAdcCu/B5z+v3VhplGg==",
+ "version": "2.0.4",
+ "resolved": "https://registry.npmjs.org/@leichtgewicht/ip-codec/-/ip-codec-2.0.4.tgz",
+ "integrity": "sha512-Hcv+nVC0kZnQ3tD9GVu5xSMR4VVYOteQIr/hwFPVEvPdlXqgGEuRjiheChHgdM+JyqdgNcmzZOX/tnl0JOiI7A==",
"dev": true,
"peer": true
},
@@ -22801,9 +22827,9 @@
"peer": true
},
"@types/react": {
- "version": "18.0.8",
- "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.8.tgz",
- "integrity": "sha512-+j2hk9BzCOrrOSJASi5XiOyBbERk9jG5O73Ya4M0env5Ixi6vUNli4qy994AINcEF+1IEHISYFfIT4zwr++LKw==",
+ "version": "18.0.9",
+ "resolved": "https://registry.npmjs.org/@types/react/-/react-18.0.9.tgz",
+ "integrity": "sha512-9bjbg1hJHUm4De19L1cHiW0Jvx3geel6Qczhjd0qY5VKVE2X5+x77YxAepuCwVh4vrgZJdgEJw48zrhRIeF4Nw==",
"requires": {
"@types/prop-types": "*",
"@types/scheduler": "*",
@@ -22961,14 +22987,14 @@
"peer": true
},
"@typescript-eslint/eslint-plugin": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.22.0.tgz",
- "integrity": "sha512-YCiy5PUzpAeOPGQ7VSGDEY2NeYUV1B0swde2e0HzokRsHBYjSdF6DZ51OuRZxVPHx0032lXGLvOMls91D8FXlg==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.23.0.tgz",
+ "integrity": "sha512-hEcSmG4XodSLiAp1uxv/OQSGsDY6QN3TcRU32gANp+19wGE1QQZLRS8/GV58VRUoXhnkuJ3ZxNQ3T6Z6zM59DA==",
"dev": true,
"requires": {
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/type-utils": "5.22.0",
- "@typescript-eslint/utils": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/type-utils": "5.23.0",
+ "@typescript-eslint/utils": "5.23.0",
"debug": "^4.3.2",
"functional-red-black-tree": "^1.0.1",
"ignore": "^5.1.8",
@@ -22989,62 +23015,62 @@
}
},
"@typescript-eslint/experimental-utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-5.22.0.tgz",
- "integrity": "sha512-rKxoCUtAHwEH6IcAoVpqipY6Th+YKW7WFspAKu0IFdbdKZpveFBeqxxE9Xn+GWikhq1o03V3VXbxIe+GdhggiQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-5.23.0.tgz",
+ "integrity": "sha512-I+3YGQztH1DM9kgWzjslpZzJCBMRz0KhYG2WP62IwpooeZ1L6Qt0mNK8zs+uP+R2HOsr+TeDW35Pitc3PfVv8Q==",
"dev": true,
"peer": true,
"requires": {
- "@typescript-eslint/utils": "5.22.0"
+ "@typescript-eslint/utils": "5.23.0"
}
},
"@typescript-eslint/parser": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.22.0.tgz",
- "integrity": "sha512-piwC4krUpRDqPaPbFaycN70KCP87+PC5WZmrWs+DlVOxxmF+zI6b6hETv7Quy4s9wbkV16ikMeZgXsvzwI3icQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.23.0.tgz",
+ "integrity": "sha512-V06cYUkqcGqpFjb8ttVgzNF53tgbB/KoQT/iB++DOIExKmzI9vBJKjZKt/6FuV9c+zrDsvJKbJ2DOCYwX91cbw==",
"dev": true,
"requires": {
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/typescript-estree": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/typescript-estree": "5.23.0",
"debug": "^4.3.2"
}
},
"@typescript-eslint/scope-manager": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.22.0.tgz",
- "integrity": "sha512-yA9G5NJgV5esANJCO0oF15MkBO20mIskbZ8ijfmlKIvQKg0ynVKfHZ15/nhAJN5m8Jn3X5qkwriQCiUntC9AbA==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.23.0.tgz",
+ "integrity": "sha512-EhjaFELQHCRb5wTwlGsNMvzK9b8Oco4aYNleeDlNuL6qXWDF47ch4EhVNPh8Rdhf9tmqbN4sWDk/8g+Z/J8JVw==",
"dev": true,
"requires": {
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/visitor-keys": "5.22.0"
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/visitor-keys": "5.23.0"
}
},
"@typescript-eslint/type-utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.22.0.tgz",
- "integrity": "sha512-iqfLZIsZhK2OEJ4cQ01xOq3NaCuG5FQRKyHicA3xhZxMgaxQazLUHbH/B2k9y5i7l3+o+B5ND9Mf1AWETeMISA==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.23.0.tgz",
+ "integrity": "sha512-iuI05JsJl/SUnOTXA9f4oI+/4qS/Zcgk+s2ir+lRmXI+80D8GaGwoUqs4p+X+4AxDolPpEpVUdlEH4ADxFy4gw==",
"dev": true,
"requires": {
- "@typescript-eslint/utils": "5.22.0",
+ "@typescript-eslint/utils": "5.23.0",
"debug": "^4.3.2",
"tsutils": "^3.21.0"
}
},
"@typescript-eslint/types": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.22.0.tgz",
- "integrity": "sha512-T7owcXW4l0v7NTijmjGWwWf/1JqdlWiBzPqzAWhobxft0SiEvMJB56QXmeCQjrPuM8zEfGUKyPQr/L8+cFUBLw==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.23.0.tgz",
+ "integrity": "sha512-NfBsV/h4dir/8mJwdZz7JFibaKC3E/QdeMEDJhiAE3/eMkoniZ7MjbEMCGXw6MZnZDMN3G9S0mH/6WUIj91dmw==",
"dev": true
},
"@typescript-eslint/typescript-estree": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.22.0.tgz",
- "integrity": "sha512-EyBEQxvNjg80yinGE2xdhpDYm41so/1kOItl0qrjIiJ1kX/L/L8WWGmJg8ni6eG3DwqmOzDqOhe6763bF92nOw==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.23.0.tgz",
+ "integrity": "sha512-xE9e0lrHhI647SlGMl+m+3E3CKPF1wzvvOEWnuE3CCjjT7UiRnDGJxmAcVKJIlFgK6DY9RB98eLr1OPigPEOGg==",
"dev": true,
"requires": {
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/visitor-keys": "5.22.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/visitor-keys": "5.23.0",
"debug": "^4.3.2",
"globby": "^11.0.4",
"is-glob": "^4.0.3",
@@ -23064,26 +23090,26 @@
}
},
"@typescript-eslint/utils": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.22.0.tgz",
- "integrity": "sha512-HodsGb037iobrWSUMS7QH6Hl1kppikjA1ELiJlNSTYf/UdMEwzgj0WIp+lBNb6WZ3zTwb0tEz51j0Wee3iJ3wQ==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.23.0.tgz",
+ "integrity": "sha512-dbgaKN21drqpkbbedGMNPCtRPZo1IOUr5EI9Jrrh99r5UW5Q0dz46RKXeSBoPV+56R6dFKpbrdhgUNSJsDDRZA==",
"dev": true,
"requires": {
"@types/json-schema": "^7.0.9",
- "@typescript-eslint/scope-manager": "5.22.0",
- "@typescript-eslint/types": "5.22.0",
- "@typescript-eslint/typescript-estree": "5.22.0",
+ "@typescript-eslint/scope-manager": "5.23.0",
+ "@typescript-eslint/types": "5.23.0",
+ "@typescript-eslint/typescript-estree": "5.23.0",
"eslint-scope": "^5.1.1",
"eslint-utils": "^3.0.0"
}
},
"@typescript-eslint/visitor-keys": {
- "version": "5.22.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.22.0.tgz",
- "integrity": "sha512-DbgTqn2Dv5RFWluG88tn0pP6Ex0ROF+dpDO1TNNZdRtLjUr6bdznjA6f/qNqJLjd2PgguAES2Zgxh/JzwzETDg==",
+ "version": "5.23.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.23.0.tgz",
+ "integrity": "sha512-Vd4mFNchU62sJB8pX19ZSPog05B0Y0CE2UxAZPT5k4iqhRYjPnqyY3woMxCd0++t9OTqkgjST+1ydLBi7e2Fvg==",
"dev": true,
"requires": {
- "@typescript-eslint/types": "5.22.0",
+ "@typescript-eslint/types": "5.23.0",
"eslint-visitor-keys": "^3.0.0"
}
},
@@ -24140,9 +24166,9 @@
}
},
"caniuse-lite": {
- "version": "1.0.30001336",
- "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001336.tgz",
- "integrity": "sha512-/YxSlBmL7iKXTbIJ48IQTnAOBk7XmWsxhBF1PZLOko5Dt9qc4Pl+84lfqG3Tc4EuavurRn1QLoVJGxY2iSycfw==",
+ "version": "1.0.30001339",
+ "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001339.tgz",
+ "integrity": "sha512-Es8PiVqCe+uXdms0Gu5xP5PF2bxLR7OBp3wUzUnuO7OHzhOfCyg3hdiGWVPVxhiuniOzng+hTc1u3fEQ0TlkSQ==",
"peer": true
},
"case-sensitive-paths-webpack-plugin": {
@@ -24923,9 +24949,9 @@
}
},
"dayjs": {
- "version": "1.11.1",
- "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.1.tgz",
- "integrity": "sha512-ER7EjqVAMkRRsxNCC5YqJ9d9VQYuWdGt7aiH2qA5R5wt8ZmWaP2dLUSIK6y/kVzLMlmh1Tvu5xUf4M/wdGJ5KA=="
+ "version": "1.11.2",
+ "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.2.tgz",
+ "integrity": "sha512-F4LXf1OeU9hrSYRPTTj/6FbO4HTjPKXvEIC1P2kcnFurViINCVk3ZV0xAS3XVx9MkMsXbbqlK6hjseaYbgKEHw=="
},
"debug": {
"version": "4.3.4",
@@ -25268,9 +25294,9 @@
}
},
"electron-to-chromium": {
- "version": "1.4.134",
- "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.134.tgz",
- "integrity": "sha512-OdD7M2no4Mi8PopfvoOuNcwYDJ2mNFxaBfurA6okG3fLBaMcFah9S+si84FhX+FIWLKkdaiHfl4A+5ep/gOVrg==",
+ "version": "1.4.137",
+ "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.137.tgz",
+ "integrity": "sha512-0Rcpald12O11BUogJagX3HsCN3FE83DSqWjgXoHo5a72KUKMSfI39XBgJpgNNxS9fuGzytaFjE06kZkiVFy2qA==",
"peer": true
},
"emittery": {
@@ -25338,17 +25364,19 @@
}
},
"es-abstract": {
- "version": "1.19.5",
- "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.19.5.tgz",
- "integrity": "sha512-Aa2G2+Rd3b6kxEUKTF4TaW67czBLyAv3z7VOhYRU50YBx+bbsYZ9xQP4lMNazePuFlybXI0V4MruPos7qUo5fA==",
+ "version": "1.20.0",
+ "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.20.0.tgz",
+ "integrity": "sha512-URbD8tgRthKD3YcC39vbvSDrX23upXnPcnGAjQfgxXF5ID75YcENawc9ZX/9iTP9ptUyfCLIxTTuMYoRfiOVKA==",
"dev": true,
"requires": {
"call-bind": "^1.0.2",
"es-to-primitive": "^1.2.1",
"function-bind": "^1.1.1",
+ "function.prototype.name": "^1.1.5",
"get-intrinsic": "^1.1.1",
"get-symbol-description": "^1.0.0",
"has": "^1.0.3",
+ "has-property-descriptors": "^1.0.0",
"has-symbols": "^1.0.3",
"internal-slot": "^1.0.3",
"is-callable": "^1.2.4",
@@ -25360,9 +25388,10 @@
"object-inspect": "^1.12.0",
"object-keys": "^1.1.1",
"object.assign": "^4.1.2",
- "string.prototype.trimend": "^1.0.4",
- "string.prototype.trimstart": "^1.0.4",
- "unbox-primitive": "^1.0.1"
+ "regexp.prototype.flags": "^1.4.1",
+ "string.prototype.trimend": "^1.0.5",
+ "string.prototype.trimstart": "^1.0.5",
+ "unbox-primitive": "^1.0.2"
}
},
"es-module-lexer": {
@@ -25478,13 +25507,13 @@
}
},
"eslint": {
- "version": "8.14.0",
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.14.0.tgz",
- "integrity": "sha512-3/CE4aJX7LNEiE3i6FeodHmI/38GZtWCsAtsymScmzYapx8q1nVVb+eLcLSzATmCPXw5pT4TqVs1E0OmxAd9tw==",
+ "version": "8.15.0",
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.15.0.tgz",
+ "integrity": "sha512-GG5USZ1jhCu8HJkzGgeK8/+RGnHaNYZGrGDzUtigK3BsGESW/rs2az23XqE0WVwDxy1VRvvjSSGu5nB0Bu+6SA==",
"dev": true,
"peer": true,
"requires": {
- "@eslint/eslintrc": "^1.2.2",
+ "@eslint/eslintrc": "^1.2.3",
"@humanwhocodes/config-array": "^0.9.2",
"ajv": "^6.10.0",
"chalk": "^4.0.0",
@@ -25495,7 +25524,7 @@
"eslint-scope": "^7.1.1",
"eslint-utils": "^3.0.0",
"eslint-visitor-keys": "^3.3.0",
- "espree": "^9.3.1",
+ "espree": "^9.3.2",
"esquery": "^1.4.0",
"esutils": "^2.0.2",
"fast-deep-equal": "^3.1.3",
@@ -25511,7 +25540,7 @@
"json-stable-stringify-without-jsonify": "^1.0.1",
"levn": "^0.4.1",
"lodash.merge": "^4.6.2",
- "minimatch": "^3.0.4",
+ "minimatch": "^3.1.2",
"natural-compare": "^1.4.0",
"optionator": "^0.9.1",
"regexpp": "^3.2.0",
@@ -25571,9 +25600,9 @@
}
},
"globals": {
- "version": "13.13.0",
- "resolved": "https://registry.npmjs.org/globals/-/globals-13.13.0.tgz",
- "integrity": "sha512-EQ7Q18AJlPwp3vUDL4mKA0KXrXyNIQyWon6T6XQiBQF0XHvRsiCSrWmmeATpUzdJN2HhWZU6Pdl0a9zdep5p6A==",
+ "version": "13.14.0",
+ "resolved": "https://registry.npmjs.org/globals/-/globals-13.14.0.tgz",
+ "integrity": "sha512-ERO68sOYwm5UuLvSJTY7w7NP2c8S4UcXs3X1GBX8cwOr+ShOcDBbCY5mH4zxz0jsYCdJ8ve8Mv9n2YGJMB1aeg==",
"dev": true,
"peer": true,
"requires": {
@@ -25888,9 +25917,9 @@
"requires": {}
},
"eslint-plugin-testing-library": {
- "version": "5.3.1",
- "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-5.3.1.tgz",
- "integrity": "sha512-OfF4dlG/q6ck6DL3P8Z0FPdK0dU5K57gsBu7eUcaVbwYKaNzjgejnXiM9CCUevppORkvfek+9D3Uj/9ZZ8Vz8g==",
+ "version": "5.4.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-testing-library/-/eslint-plugin-testing-library-5.4.0.tgz",
+ "integrity": "sha512-XjxIf4g33KaZXxRNbR33+0WcRQ/zt8N0R58IY6/kkHnrY6zPsC1gs3u5cTZr5eUmCZN/sjoPak3uF5vHGKg2wg==",
"dev": true,
"peer": true,
"requires": {
@@ -25953,14 +25982,14 @@
}
},
"espree": {
- "version": "9.3.1",
- "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.1.tgz",
- "integrity": "sha512-bvdyLmJMfwkV3NCRl5ZhJf22zBFo1y8bYh3VYb+bfzqNB4Je68P2sSuXyuFquzWLebHpNd2/d5uv7yoP9ISnGQ==",
+ "version": "9.3.2",
+ "resolved": "https://registry.npmjs.org/espree/-/espree-9.3.2.tgz",
+ "integrity": "sha512-D211tC7ZwouTIuY5x9XnS0E9sWNChB7IYKX/Xp5eQj3nFXhqmiUDB9q27y76oFl8jTg3pXcQx/bpxMfs3CIZbA==",
"dev": true,
"peer": true,
"requires": {
- "acorn": "^8.7.0",
- "acorn-jsx": "^5.3.1",
+ "acorn": "^8.7.1",
+ "acorn-jsx": "^5.3.2",
"eslint-visitor-keys": "^3.3.0"
}
},
@@ -26552,11 +26581,31 @@
"dev": true,
"peer": true
},
+ "fsevents": {
+ "version": "2.3.2",
+ "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz",
+ "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==",
+ "dev": true,
+ "optional": true,
+ "peer": true
+ },
"function-bind": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz",
"integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A=="
},
+ "function.prototype.name": {
+ "version": "1.1.5",
+ "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz",
+ "integrity": "sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==",
+ "dev": true,
+ "requires": {
+ "call-bind": "^1.0.2",
+ "define-properties": "^1.1.3",
+ "es-abstract": "^1.19.0",
+ "functions-have-names": "^1.2.2"
+ }
+ },
"functional-red-black-tree": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz",
@@ -28782,17 +28831,17 @@
},
"dependencies": {
"@jest/console": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/console/-/console-28.0.2.tgz",
- "integrity": "sha512-tiRpnMeeyQuuzgL5UNSeiqMwF8UOWPbAE5rzcu/1zyq4oPG2Ox6xm4YCOruwbp10F8odWc+XwVxTyGzMSLMqxA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/console/-/console-28.1.0.tgz",
+ "integrity": "sha512-tscn3dlJFGay47kb4qVruQg/XWlmvU0xp3EJOjzzY+sBaI+YgwKcvAmTcyYU7xEiLLIY5HCdWRooAL8dqkFlDA==",
"dev": true,
"peer": true,
"requires": {
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"chalk": "^4.0.0",
- "jest-message-util": "^28.0.2",
- "jest-util": "^28.0.2",
+ "jest-message-util": "^28.1.0",
+ "jest-util": "^28.1.0",
"slash": "^3.0.0"
},
"dependencies": {
@@ -28806,22 +28855,22 @@
}
},
"@jest/test-result": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-28.0.2.tgz",
- "integrity": "sha512-4EUqgjq9VzyUiVTvZfI9IRJD6t3NYBNP4f+Eq8Zr93+hkJ0RrGU4OBTw8tfNzidKX+bmuYzn8FxqpxOPIGGCMA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/test-result/-/test-result-28.1.0.tgz",
+ "integrity": "sha512-sBBFIyoPzrZho3N+80P35A5oAkSKlGfsEFfXFWuPGBsW40UAjCkGakZhn4UQK4iQlW2vgCDMRDOob9FGKV8YoQ==",
"dev": true,
"peer": true,
"requires": {
- "@jest/console": "^28.0.2",
- "@jest/types": "^28.0.2",
+ "@jest/console": "^28.1.0",
+ "@jest/types": "^28.1.0",
"@types/istanbul-lib-coverage": "^2.0.0",
"collect-v8-coverage": "^1.0.0"
}
},
"@jest/types": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/@jest/types/-/types-28.0.2.tgz",
- "integrity": "sha512-hi3jUdm9iht7I2yrV5C4s3ucCJHUP8Eh3W6rQ1s4n/Qw9rQgsda4eqCt+r3BKRi7klVmZfQlMx1nGlzNMP2d8A==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/@jest/types/-/types-28.1.0.tgz",
+ "integrity": "sha512-xmEggMPr317MIOjjDoZ4ejCSr9Lpbt/u34+dvc99t7DS8YirW5rwZEhzKPC2BMUFkUhI48qs6qLUSGw5FuL0GA==",
"dev": true,
"peer": true,
"requires": {
@@ -28896,19 +28945,19 @@
"peer": true
},
"jest-message-util": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-28.0.2.tgz",
- "integrity": "sha512-knK7XyojvwYh1XiF2wmVdskgM/uN11KsjcEWWHfnMZNEdwXCrqB4sCBO94F4cfiAwCS8WFV6CDixDwPlMh/wdA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-28.1.0.tgz",
+ "integrity": "sha512-RpA8mpaJ/B2HphDMiDlrAZdDytkmwFqgjDZovM21F35lHGeUeCvYmm6W+sbQ0ydaLpg5bFAUuWG1cjqOl8vqrw==",
"dev": true,
"peer": true,
"requires": {
"@babel/code-frame": "^7.12.13",
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/stack-utils": "^2.0.0",
"chalk": "^4.0.0",
"graceful-fs": "^4.2.9",
"micromatch": "^4.0.4",
- "pretty-format": "^28.0.2",
+ "pretty-format": "^28.1.0",
"slash": "^3.0.0",
"stack-utils": "^2.0.3"
},
@@ -28930,13 +28979,13 @@
"peer": true
},
"jest-util": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-28.0.2.tgz",
- "integrity": "sha512-EVdpIRCC8lzqhp9A0u0aAKlsFIzufK6xKxNK7awsnebTdOP4hpyQW5o6Ox2qPl8gbeUKYF+POLyItaND53kpGA==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-28.1.0.tgz",
+ "integrity": "sha512-qYdCKD77k4Hwkose2YBEqQk7PzUf/NSE+rutzceduFveQREeH6b+89Dc9+wjX9dAwHcgdx4yedGA3FQlU/qCTA==",
"dev": true,
"peer": true,
"requires": {
- "@jest/types": "^28.0.2",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"chalk": "^4.0.0",
"ci-info": "^3.2.0",
@@ -28945,19 +28994,19 @@
}
},
"jest-watcher": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-28.0.2.tgz",
- "integrity": "sha512-uIVJLpQ/5VTGQWBiBatHsi7jrCqHjHl0e0dFHMWzwuIfUbdW/muk0DtSr0fteY2T7QTFylv+7a5Rm8sBKrE12Q==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/jest-watcher/-/jest-watcher-28.1.0.tgz",
+ "integrity": "sha512-tNHMtfLE8Njcr2IRS+5rXYA4BhU90gAOwI9frTGOqd+jX0P/Au/JfRSNqsf5nUTcWdbVYuLxS1KjnzILSoR5hA==",
"dev": true,
"peer": true,
"requires": {
- "@jest/test-result": "^28.0.2",
- "@jest/types": "^28.0.2",
+ "@jest/test-result": "^28.1.0",
+ "@jest/types": "^28.1.0",
"@types/node": "*",
"ansi-escapes": "^4.2.1",
"chalk": "^4.0.0",
"emittery": "^0.10.2",
- "jest-util": "^28.0.2",
+ "jest-util": "^28.1.0",
"string-length": "^4.0.1"
},
"dependencies": {
@@ -28985,9 +29034,9 @@
}
},
"pretty-format": {
- "version": "28.0.2",
- "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-28.0.2.tgz",
- "integrity": "sha512-UmGZ1IERwS3yY35LDMTaBUYI1w4udZDdJGGT/DqQeKG9ZLDn7/K2Jf/JtYSRiHCCKMHvUA+zsEGSmHdpaVp1yw==",
+ "version": "28.1.0",
+ "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-28.1.0.tgz",
+ "integrity": "sha512-79Z4wWOYCdvQkEoEuSlBhHJqWeZ8D8YRPiPctJFCtvuaClGpiwiQYSCUOE6IEKUbbFukKOTFIUAXE8N4EQTo1Q==",
"dev": true,
"peer": true,
"requires": {
@@ -29895,13 +29944,13 @@
}
},
"object.hasown": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/object.hasown/-/object.hasown-1.1.0.tgz",
- "integrity": "sha512-MhjYRfj3GBlhSkDHo6QmvgjRLXQ2zndabdf3nX0yTyZK9rPfxb6uRpAac8HXNLy1GpqWtZ81Qh4v3uOls2sRAg==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/object.hasown/-/object.hasown-1.1.1.tgz",
+ "integrity": "sha512-LYLe4tivNQzq4JdaWW6WO3HMZZJWzkkH8fnI6EebWl0VZth2wL2Lovm74ep2/gZzlaTdV62JZHEqHQ2yVn8Q/A==",
"dev": true,
"requires": {
- "define-properties": "^1.1.3",
- "es-abstract": "^1.19.1"
+ "define-properties": "^1.1.4",
+ "es-abstract": "^1.19.5"
}
},
"object.values": {
@@ -30928,9 +30977,9 @@
}
},
"postcss-pseudo-class-any-link": {
- "version": "7.1.2",
- "resolved": "https://registry.npmjs.org/postcss-pseudo-class-any-link/-/postcss-pseudo-class-any-link-7.1.2.tgz",
- "integrity": "sha512-76XzEQv3g+Vgnz3tmqh3pqQyRojkcJ+pjaePsyhcyf164p9aZsu3t+NWxkZYbcHLK1ju5Qmalti2jPI5IWCe5w==",
+ "version": "7.1.3",
+ "resolved": "https://registry.npmjs.org/postcss-pseudo-class-any-link/-/postcss-pseudo-class-any-link-7.1.3.tgz",
+ "integrity": "sha512-I9Yp1VV2r8xFwg/JrnAlPCcKmutv6f6Ig6/CHFPqGJiDgYXM9C+0kgLfK4KOXbKNw+63QYl4agRUB0Wi9ftUIg==",
"dev": true,
"peer": true,
"requires": {
@@ -31066,9 +31115,9 @@
"peer": true
},
"preact": {
- "version": "10.7.1",
- "resolved": "https://registry.npmjs.org/preact/-/preact-10.7.1.tgz",
- "integrity": "sha512-MufnRFz39aIhs9AMFisonjzTud1PK1bY+jcJLo6m2T9Uh8AqjD77w11eAAawmjUogoGOnipECq7e/1RClIKsxg=="
+ "version": "10.7.2",
+ "resolved": "https://registry.npmjs.org/preact/-/preact-10.7.2.tgz",
+ "integrity": "sha512-GLjn0I3r6ka+NvxJUppsVFqb4V0qDTEHT/QxHlidPuClGaxF/4AI2Qti4a0cv3XMh5n1+D3hLScW10LRIm5msQ=="
},
"prelude-ls": {
"version": "1.2.1",
@@ -31846,9 +31895,9 @@
}
},
"rollup": {
- "version": "2.72.0",
- "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.72.0.tgz",
- "integrity": "sha512-KqtR2YcO35/KKijg4nx4STO3569aqCUeGRkKWnJ6r+AvBBrVY9L4pmf4NHVrQr4mTOq6msbohflxr2kpihhaOA==",
+ "version": "2.72.1",
+ "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.72.1.tgz",
+ "integrity": "sha512-NTc5UGy/NWFGpSqF1lFY8z9Adri6uhyMLI6LvPAXdBKoPRFhIIiBUpt+Qg2awixqO3xvzSijjhnb4+QEZwJmxA==",
"dev": true,
"peer": true,
"requires": {
@@ -32643,7 +32692,7 @@
"boolbase": "^1.0.0",
"css-what": "^3.2.1",
"domutils": "^1.7.0",
- "nth-check": "^1.0.2"
+ "nth-check": "^2.0.1"
}
},
"css-what": {
@@ -32694,16 +32743,6 @@
"argparse": "^1.0.7",
"esprima": "^4.0.0"
}
- },
- "nth-check": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz",
- "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==",
- "dev": true,
- "peer": true,
- "requires": {
- "boolbase": "~1.0.0"
- }
}
}
},
diff --git a/app/vmui/packages/vmui/package.json b/app/vmui/packages/vmui/package.json
index f34e6ac7d6..424d2505e4 100644
--- a/app/vmui/packages/vmui/package.json
+++ b/app/vmui/packages/vmui/package.json
@@ -37,7 +37,6 @@
"start": "react-app-rewired start",
"build": "GENERATE_SOURCEMAP=false react-app-rewired build",
"test": "react-app-rewired test",
- "eject": "react-scripts eject",
"lint": "eslint src --ext tsx,ts",
"lint:fix": "eslint src --ext tsx,ts --fix"
},
@@ -66,5 +65,10 @@
"customize-cra": "^1.0.0",
"eslint-plugin-react": "^7.29.4",
"react-app-rewired": "^2.2.1"
+ },
+ "overrides": {
+ "react-app-rewired": {
+ "nth-check": "^2.0.1"
+ }
}
}
From 284bda87462ce4fbd2bd702db885318fb9794755 Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Mon, 16 May 2022 09:27:19 +0200
Subject: [PATCH 31/51] docs: fix liquid syntax errors (#2592)
For liquid text processor double braces `{{` `}}`
are special chars for templating.
Since we use them in some of our docs with different purpose,
we must escape them to avoid syntax errors from liquid.
For escaping curly braces we use bult-in plugin which helps
to enclose sections of text via `{% raw %}` and `{% endraw %}`.
This approach prevents liquid syntax errors and makes render correct.
Signed-off-by: hagen1778
---
app/vmalert/README.md | 4 ++++
docs/PerTenantStatistic.md | 2 ++
docs/operator/quick-start.MD | 6 ++++++
docs/vmalert.md | 4 ++++
4 files changed, 16 insertions(+)
diff --git a/app/vmalert/README.md b/app/vmalert/README.md
index e89fb259c0..18fa20ae4f 100644
--- a/app/vmalert/README.md
+++ b/app/vmalert/README.md
@@ -197,6 +197,7 @@ set the path via `-rule.templates` flag.
For example, template `grafana.filter` can be defined as following:
+{% raw %}
```
{{ define "grafana.filter" -}}
{{- $labels := .arg0 -}}
@@ -207,9 +208,11 @@ For example, template `grafana.filter` can be defined as following:
{{- end -}}
{{- end -}}
```
+{% endraw %}
And then used in annotations:
+{% raw %}
```yaml
groups:
- name: AlertGroupName
@@ -223,6 +226,7 @@ groups:
annotations:
dashboard: '{{ $externalURL }}/d/dashboard?orgId=1{{ template "grafana.filter" (args .CommonLabels "account_id" "any_label") }}'
```
+{% endraw %}
The `-rule.templates` flag supports wildcards so multiple files with templates can be loaded.
The content of `-rule.templates` can be also [hot reloaded](#hot-config-reload).
diff --git a/docs/PerTenantStatistic.md b/docs/PerTenantStatistic.md
index 7768895bf6..e798a7e119 100644
--- a/docs/PerTenantStatistic.md
+++ b/docs/PerTenantStatistic.md
@@ -60,6 +60,7 @@ to prevent limits exhaustion.
Here is an alert example for high churn rate by the tenant:
+{% raw %}
```yaml
- alert: TooHighChurnRate
@@ -79,3 +80,4 @@ Here is an alert example for high churn rate by the tenant:
High Churn Rate is tightly connected with database performance and may
result in unexpected OOM's or slow queries."
```
+{% endraw %}
diff --git a/docs/operator/quick-start.MD b/docs/operator/quick-start.MD
index c05e5a73ed..ede19fdd0f 100644
--- a/docs/operator/quick-start.MD
+++ b/docs/operator/quick-start.MD
@@ -752,6 +752,7 @@ kubectl logs vmalert-example-vmalert-6f8748c6f9-hcfrr vmalert
Let's add simple rule for `VMAlert` itself, `delta(vmalert_config_last_reload_errors_total[5m]) > 1`
+{% raw %}
```yaml
cat << 'EOF' | kubectl apply -f -
apiVersion: operator.victoriametrics.com/v1beta1
@@ -775,6 +776,7 @@ spec:
description: 'error reloading vmalert config, reload count for 5 min {{ $value }}'
EOF
```
+{% endraw %}
Ensure, that new alert was started:
```bash
@@ -790,6 +792,7 @@ kubectl logs vmalert-example-vmalert-6f8748c6f9-hcfrr vmalert
Let's trigger it by adding some incorrect rule
+{% raw %}
```yaml
cat << 'EOF' | kubectl apply -f -
apiVersion: operator.victoriametrics.com/v1beta1
@@ -811,6 +814,7 @@ spec:
value: "{{ $badValue | bad function }}"
EOF
```
+{% endraw %}
`VMAlert` will report incorrect rule config and fire alert:
```bash
@@ -1129,6 +1133,7 @@ vmauth-config-example Opaque 1 2m32s
```
Generated configuration can be retrieved with command:
+{% raw %}
```text
kubectl get secrets/vmauth-config-example -o=go-template='{{index .data "config.yaml.gz"}}' | base64 -d | gunzip
@@ -1136,6 +1141,7 @@ users:
- url_prefix: http://localhost:8428
bearer_token: some-default-token
```
+{% endraw %}
Operator generates default config, if `VMUser`s for given `VMAuth` wasn't found.
diff --git a/docs/vmalert.md b/docs/vmalert.md
index d7e4d53b01..d398ef8308 100644
--- a/docs/vmalert.md
+++ b/docs/vmalert.md
@@ -201,6 +201,7 @@ set the path via `-rule.templates` flag.
For example, template `grafana.filter` can be defined as following:
+{% raw %}
```
{{ define "grafana.filter" -}}
{{- $labels := .arg0 -}}
@@ -211,9 +212,11 @@ For example, template `grafana.filter` can be defined as following:
{{- end -}}
{{- end -}}
```
+{% endraw %}
And then used in annotations:
+{% raw %}
```yaml
groups:
- name: AlertGroupName
@@ -227,6 +230,7 @@ groups:
annotations:
dashboard: '{{ $externalURL }}/d/dashboard?orgId=1{{ template "grafana.filter" (args .CommonLabels "account_id" "any_label") }}'
```
+{% endraw %}
The `-rule.templates` flag supports wildcards so multiple files with templates can be loaded.
The content of `-rule.templates` can be also [hot reloaded](#hot-config-reload).
From ff7447262185964746ca9e62f2126fdeed7f24bb Mon Sep 17 00:00:00 2001
From: Yury Molodov
Date: Mon, 16 May 2022 10:42:37 +0300
Subject: [PATCH 32/51] vmui: setup predefined dashboards without build (#2541)
vmui: support predefined dashboards in json format
See https://github.com/VictoriaMetrics/VictoriaMetrics/tree/master/app/vmselect/vmui/dashboards
---
app/vmselect/vmui/asset-manifest.json | 6 ++--
.../vmui}/dashboards/README.md | 5 ++++
app/vmselect/vmui/dashboards/index.js | 5 ++++
.../vmui}/dashboards/perJobUsage.json | 4 +--
app/vmselect/vmui/index.html | 2 +-
.../vmui/static/js/362.1f16598a.chunk.js | 1 -
app/vmselect/vmui/static/js/main.a54e3212.js | 2 ++
...CENSE.txt => main.a54e3212.js.LICENSE.txt} | 0
app/vmselect/vmui/static/js/main.f64c8675.js | 2 --
.../vmui/public/dashboards/README.md} | 5 ++++
.../packages/vmui/public/dashboards/index.js | 5 ++++
.../vmui/public/dashboards/perJobUsage.json | 29 +++++++++++++++++++
app/vmui/packages/vmui/public/index.html | 1 +
.../PredefinedPanels/DashboardsLayout.tsx | 2 +-
.../PredefinedPanels/getDashboardSettings.ts | 12 ++------
app/vmui/packages/vmui/src/types/index.ts | 6 ++++
16 files changed, 66 insertions(+), 21 deletions(-)
rename app/{vmui/packages/vmui/src => vmselect/vmui}/dashboards/README.md (93%)
create mode 100644 app/vmselect/vmui/dashboards/index.js
rename app/{vmui/packages/vmui/src => vmselect/vmui}/dashboards/perJobUsage.json (97%)
delete mode 100644 app/vmselect/vmui/static/js/362.1f16598a.chunk.js
create mode 100644 app/vmselect/vmui/static/js/main.a54e3212.js
rename app/vmselect/vmui/static/js/{main.f64c8675.js.LICENSE.txt => main.a54e3212.js.LICENSE.txt} (100%)
delete mode 100644 app/vmselect/vmui/static/js/main.f64c8675.js
rename app/{vmselect/vmui/static/media/README.40ebc3a1f4adae949154.md => vmui/packages/vmui/public/dashboards/README.md} (93%)
create mode 100644 app/vmui/packages/vmui/public/dashboards/index.js
create mode 100644 app/vmui/packages/vmui/public/dashboards/perJobUsage.json
diff --git a/app/vmselect/vmui/asset-manifest.json b/app/vmselect/vmui/asset-manifest.json
index 74e00af510..31172b57fc 100644
--- a/app/vmselect/vmui/asset-manifest.json
+++ b/app/vmselect/vmui/asset-manifest.json
@@ -1,14 +1,12 @@
{
"files": {
"main.css": "./static/css/main.d8362c27.css",
- "main.js": "./static/js/main.f64c8675.js",
- "static/js/362.1f16598a.chunk.js": "./static/js/362.1f16598a.chunk.js",
+ "main.js": "./static/js/main.a54e3212.js",
"static/js/27.939f971b.chunk.js": "./static/js/27.939f971b.chunk.js",
- "static/media/README.md": "./static/media/README.40ebc3a1f4adae949154.md",
"index.html": "./index.html"
},
"entrypoints": [
"static/css/main.d8362c27.css",
- "static/js/main.f64c8675.js"
+ "static/js/main.a54e3212.js"
]
}
\ No newline at end of file
diff --git a/app/vmui/packages/vmui/src/dashboards/README.md b/app/vmselect/vmui/dashboards/README.md
similarity index 93%
rename from app/vmui/packages/vmui/src/dashboards/README.md
rename to app/vmselect/vmui/dashboards/README.md
index 7fd86af708..655b7cc23c 100644
--- a/app/vmui/packages/vmui/src/dashboards/README.md
+++ b/app/vmselect/vmui/dashboards/README.md
@@ -1,3 +1,8 @@
+### Setup
+1. Create `.json` config file in a folder `dashboards`
+2. Import your config file into the `dashboards/index.js`
+3. Add imported variable into the array `window.__VMUI_PREDEFINED_DASHBOARDS__`
+
### Configuration options
diff --git a/app/vmselect/vmui/dashboards/index.js b/app/vmselect/vmui/dashboards/index.js
new file mode 100644
index 0000000000..403467fe3c
--- /dev/null
+++ b/app/vmselect/vmui/dashboards/index.js
@@ -0,0 +1,5 @@
+import perJob from "./perJobUsage.json" assert { type: "json" };
+
+window.__VMUI_PREDEFINED_DASHBOARDS__ = [
+ perJob
+];
diff --git a/app/vmui/packages/vmui/src/dashboards/perJobUsage.json b/app/vmselect/vmui/dashboards/perJobUsage.json
similarity index 97%
rename from app/vmui/packages/vmui/src/dashboards/perJobUsage.json
rename to app/vmselect/vmui/dashboards/perJobUsage.json
index abc6d186af..6d134a3bea 100644
--- a/app/vmui/packages/vmui/src/dashboards/perJobUsage.json
+++ b/app/vmselect/vmui/dashboards/perJobUsage.json
@@ -17,12 +17,12 @@
"title": "Per-job disk read",
"width": 6,
"expr": ["sum(rate(process_io_storage_read_bytes_total)) by (job)"]
- },{
+ },
+ {
"title": "Per-job disk write",
"width": 6,
"expr": ["sum(rate(process_io_storage_written_bytes_total)) by (job)"]
}
-
]
}
]
diff --git a/app/vmselect/vmui/index.html b/app/vmselect/vmui/index.html
index d8a2deeafd..3669e8671a 100644
--- a/app/vmselect/vmui/index.html
+++ b/app/vmselect/vmui/index.html
@@ -1 +1 @@
-VM UI
\ No newline at end of file
+VM UI
diff --git a/app/vmselect/vmui/static/js/362.1f16598a.chunk.js b/app/vmselect/vmui/static/js/362.1f16598a.chunk.js
deleted file mode 100644
index 4e97a606c8..0000000000
--- a/app/vmselect/vmui/static/js/362.1f16598a.chunk.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";(self.webpackChunkvmui=self.webpackChunkvmui||[]).push([[362],{8362:function(e,a,s){e.exports=s.p+"static/media/README.40ebc3a1f4adae949154.md"}}]);
\ No newline at end of file
diff --git a/app/vmselect/vmui/static/js/main.a54e3212.js b/app/vmselect/vmui/static/js/main.a54e3212.js
new file mode 100644
index 0000000000..02d3cb7d51
--- /dev/null
+++ b/app/vmselect/vmui/static/js/main.a54e3212.js
@@ -0,0 +1,2 @@
+/*! For license information please see main.a54e3212.js.LICENSE.txt */
+!function(){var e={5318:function(e){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},7757:function(e,t,n){e.exports=n(8937)},2575:function(e,t,n){"use strict";n.d(t,{Z:function(){return oe}});var r=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t0?c(x,--y):0,v--,10===b&&(v=1,m--),b}function k(){return b=y2||E(b)>3?"":" "}function R(e,t){for(;--t&&k()&&!(b<48||b>102||b>57&&b<65||b>70&&b<97););return _(e,C()+(t<6&&32==S()&&32==k()))}function F(e){for(;k();)switch(b){case e:return y;case 34:case 39:34!==e&&39!==e&&F(b);break;case 40:41===e&&F(e);break;case 92:k()}return y}function O(e,t){for(;k()&&e+b!==57&&(e+b!==84||47!==S()););return"/*"+_(t,y-1)+"*"+i(47===e?e:k())}function B(e){for(;!E(S());)k();return _(e,y)}var I="-ms-",L="-moz-",N="-webkit-",z="comm",j="rule",W="decl",$="@keyframes";function H(e,t){for(var n="",r=p(e),o=0;o6)switch(c(e,t+1)){case 109:if(45!==c(e,t+4))break;case 102:return l(e,/(.+:)(.+)-([^]+)/,"$1-webkit-$2-$3$1"+L+(108==c(e,t+3)?"$3":"$2-$3"))+e;case 115:return~s(e,"stretch")?V(l(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==c(e,t+1))break;case 6444:switch(c(e,f(e)-3-(~s(e,"!important")&&10))){case 107:return l(e,":",":"+N)+e;case 101:return l(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+N+(45===c(e,14)?"inline-":"")+"box$3$1"+N+"$2$3$1"+I+"$2box$3")+e}break;case 5936:switch(c(e,t+11)){case 114:return N+e+I+l(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return N+e+I+l(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return N+e+I+l(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return N+e+I+e+e}return e}function U(e){return M(q("",null,null,null,[""],e=A(e),0,[0],e))}function q(e,t,n,r,o,a,u,c,d){for(var p=0,m=0,v=u,g=0,y=0,b=0,x=1,Z=1,w=1,_=0,E="",A=o,M=a,F=r,I=E;Z;)switch(b=_,_=k()){case 40:if(108!=b&&58==I.charCodeAt(v-1)){-1!=s(I+=l(T(_),"&","&\f"),"&\f")&&(w=-1);break}case 34:case 39:case 91:I+=T(_);break;case 9:case 10:case 13:case 32:I+=P(b);break;case 92:I+=R(C()-1,7);continue;case 47:switch(S()){case 42:case 47:h(G(O(k(),C()),t,n),d);break;default:I+="/"}break;case 123*x:c[p++]=f(I)*w;case 125*x:case 59:case 0:switch(_){case 0:case 125:Z=0;case 59+m:y>0&&f(I)-v&&h(y>32?K(I+";",r,n,v-1):K(l(I," ","")+";",r,n,v-2),d);break;case 59:I+=";";default:if(h(F=X(I,t,n,p,m,o,c,E,A=[],M=[],v),a),123===_)if(0===m)q(I,t,F,F,A,a,v,c,M);else switch(g){case 100:case 109:case 115:q(e,F,F,r&&h(X(e,F,F,0,0,o,c,E,o,A=[],v),M),o,M,v,c,r?A:M);break;default:q(I,F,F,F,[""],M,0,c,M)}}p=m=y=0,x=w=1,E=I="",v=u;break;case 58:v=1+f(I),y=b;default:if(x<1)if(123==_)--x;else if(125==_&&0==x++&&125==D())continue;switch(I+=i(_),_*x){case 38:w=m>0?1:(I+="\f",-1);break;case 44:c[p++]=(f(I)-1)*w,w=1;break;case 64:45===S()&&(I+=T(k())),g=S(),m=v=f(E=I+=B(C())),_++;break;case 45:45===b&&2==f(I)&&(x=0)}}return a}function X(e,t,n,r,i,a,s,c,f,h,m){for(var v=i-1,g=0===i?a:[""],y=p(g),b=0,x=0,w=0;b0?g[D]+" "+k:l(k,/&\f/g,g[D])))&&(f[w++]=S);return Z(e,t,n,0===i?j:c,f,h,m)}function G(e,t,n){return Z(e,t,n,z,i(b),d(e,2,-2),0)}function K(e,t,n,r){return Z(e,t,n,W,d(e,0,r),d(e,r+1,-1),r)}var Q=function(e,t,n){for(var r=0,o=0;r=o,o=S(),38===r&&12===o&&(t[n]=1),!E(o);)k();return _(e,y)},J=function(e,t){return M(function(e,t){var n=-1,r=44;do{switch(E(r)){case 0:38===r&&12===S()&&(t[n]=1),e[n]+=Q(y-1,t,n);break;case 2:e[n]+=T(r);break;case 4:if(44===r){e[++n]=58===S()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=i(r)}}while(r=k());return e}(A(e),t))},ee=new WeakMap,te=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||ee.get(n))&&!r){ee.set(e,!0);for(var o=[],i=J(t,o),a=n.props,u=0,l=0;u-1&&!e.return)switch(e.type){case W:e.return=V(e.value,e.length);break;case $:return H([w(e,{value:l(e.value,"@","@"+N)})],r);case j:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=t.exec(e))?e[0]:e}(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return H([w(e,{props:[l(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return H([w(e,{props:[l(t,/:(plac\w+)/,":-webkit-input-$1")]}),w(e,{props:[l(t,/:(plac\w+)/,":-moz-$1")]}),w(e,{props:[l(t,/:(plac\w+)/,I+"input-$1")]})],r)}return""}))}}],oe=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var o=e.stylisPlugins||re;var i,a,u={},l=[];i=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)},o={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},i=n(3390),a=/[A-Z]|^ms/g,u=/_EMO_([^_]+?)_([^]*?)_EMO_/g,l=function(e){return 45===e.charCodeAt(1)},s=function(e){return null!=e&&"boolean"!==typeof e},c=(0,i.Z)((function(e){return l(e)?e:e.replace(a,"-$&").toLowerCase()})),d=function(e,t){switch(e){case"animation":case"animationName":if("string"===typeof t)return t.replace(u,(function(e,t,n){return p={name:t,styles:n,next:p},t}))}return 1===o[e]||l(e)||"number"!==typeof t||0===t?t:t+"px"};function f(e,t,n){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return p={name:n.name,styles:n.styles,next:p},n.name;if(void 0!==n.styles){var r=n.next;if(void 0!==r)for(;void 0!==r;)p={name:r.name,styles:r.styles,next:p},r=r.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o0&&void 0!==arguments[0]?arguments[0]:"light")?{main:v[200],light:v[50],dark:v[400]}:{main:v[700],light:v[400],dark:v[800]}}(n),C=e.secondary||function(){return"dark"===(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light")?{main:p[200],light:p[50],dark:p[400]}:{main:p[500],light:p[300],dark:p[700]}}(n),_=e.error||function(){return"dark"===(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light")?{main:h[500],light:h[300],dark:h[700]}:{main:h[700],light:h[400],dark:h[800]}}(n),E=e.info||function(){return"dark"===(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light")?{main:g[400],light:g[300],dark:g[700]}:{main:g[700],light:g[500],dark:g[900]}}(n),A=e.success||function(){return"dark"===(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light")?{main:y[400],light:y[300],dark:y[700]}:{main:y[800],light:y[500],dark:y[900]}}(n),M=e.warning||function(){return"dark"===(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"light")?{main:m[400],light:m[300],dark:m[700]}:{main:"#ed6c02",light:m[500],dark:m[900]}}(n);function T(e){return(0,c.mi)(e,Z.text.primary)>=u?Z.text.primary:x.text.primary}var P=function(e){var t=e.color,n=e.name,o=e.mainShade,i=void 0===o?500:o,a=e.lightShade,u=void 0===a?300:a,l=e.darkShade,c=void 0===l?700:l;if(!(t=(0,r.Z)({},t)).main&&t[i]&&(t.main=t[i]),!t.hasOwnProperty("main"))throw new Error((0,s.Z)(11,n?" (".concat(n,")"):"",i));if("string"!==typeof t.main)throw new Error((0,s.Z)(12,n?" (".concat(n,")"):"",JSON.stringify(t.main)));return w(t,"light",u,D),w(t,"dark",c,D),t.contrastText||(t.contrastText=T(t.main)),t},R={dark:Z,light:x};return(0,i.Z)((0,r.Z)({common:d,mode:n,primary:P({color:S,name:"primary"}),secondary:P({color:C,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:P({color:_,name:"error"}),warning:P({color:M,name:"warning"}),info:P({color:E,name:"info"}),success:P({color:A,name:"success"}),grey:f,contrastThreshold:u,getContrastText:T,augmentColor:P,tonalOffset:D},R[n]),k)}var k=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];var S={textTransform:"uppercase"},C='"Roboto", "Helvetica", "Arial", sans-serif';function _(e,t){var n="function"===typeof t?t(e):t,a=n.fontFamily,u=void 0===a?C:a,l=n.fontSize,s=void 0===l?14:l,c=n.fontWeightLight,d=void 0===c?300:c,f=n.fontWeightRegular,p=void 0===f?400:f,h=n.fontWeightMedium,m=void 0===h?500:h,v=n.fontWeightBold,g=void 0===v?700:v,y=n.htmlFontSize,b=void 0===y?16:y,x=n.allVariants,Z=n.pxToRem,w=(0,o.Z)(n,k);var D=s/14,_=Z||function(e){return"".concat(e/b*D,"rem")},E=function(e,t,n,o,i){return(0,r.Z)({fontFamily:u,fontWeight:e,fontSize:_(t),lineHeight:n},u===C?{letterSpacing:"".concat((a=o/t,Math.round(1e5*a)/1e5),"em")}:{},i,x);var a},A={h1:E(d,96,1.167,-1.5),h2:E(d,60,1.2,-.5),h3:E(p,48,1.167,0),h4:E(p,34,1.235,.25),h5:E(p,24,1.334,0),h6:E(m,20,1.6,.15),subtitle1:E(p,16,1.75,.15),subtitle2:E(m,14,1.57,.1),body1:E(p,16,1.5,.15),body2:E(p,14,1.43,.15),button:E(m,14,1.75,.4,S),caption:E(p,12,1.66,.4),overline:E(p,12,2.66,1,S)};return(0,i.Z)((0,r.Z)({htmlFontSize:b,pxToRem:_,fontFamily:u,fontSize:s,fontWeightLight:d,fontWeightRegular:p,fontWeightMedium:m,fontWeightBold:g},A),w,{clone:!1})}function E(){return["".concat(arguments.length<=0?void 0:arguments[0],"px ").concat(arguments.length<=1?void 0:arguments[1],"px ").concat(arguments.length<=2?void 0:arguments[2],"px ").concat(arguments.length<=3?void 0:arguments[3],"px rgba(0,0,0,").concat(.2,")"),"".concat(arguments.length<=4?void 0:arguments[4],"px ").concat(arguments.length<=5?void 0:arguments[5],"px ").concat(arguments.length<=6?void 0:arguments[6],"px ").concat(arguments.length<=7?void 0:arguments[7],"px rgba(0,0,0,").concat(.14,")"),"".concat(arguments.length<=8?void 0:arguments[8],"px ").concat(arguments.length<=9?void 0:arguments[9],"px ").concat(arguments.length<=10?void 0:arguments[10],"px ").concat(arguments.length<=11?void 0:arguments[11],"px rgba(0,0,0,").concat(.12,")")].join(",")}var A=["none",E(0,2,1,-1,0,1,1,0,0,1,3,0),E(0,3,1,-2,0,2,2,0,0,1,5,0),E(0,3,3,-2,0,3,4,0,0,1,8,0),E(0,2,4,-1,0,4,5,0,0,1,10,0),E(0,3,5,-1,0,5,8,0,0,1,14,0),E(0,3,5,-1,0,6,10,0,0,1,18,0),E(0,4,5,-2,0,7,10,1,0,2,16,1),E(0,5,5,-3,0,8,10,1,0,3,14,2),E(0,5,6,-3,0,9,12,1,0,3,16,2),E(0,6,6,-3,0,10,14,1,0,4,18,3),E(0,6,7,-4,0,11,15,1,0,4,20,3),E(0,7,8,-4,0,12,17,2,0,5,22,4),E(0,7,8,-4,0,13,19,2,0,5,24,4),E(0,7,9,-4,0,14,21,2,0,5,26,4),E(0,8,9,-5,0,15,22,2,0,6,28,5),E(0,8,10,-5,0,16,24,2,0,6,30,5),E(0,8,11,-5,0,17,26,2,0,6,32,5),E(0,9,11,-5,0,18,28,2,0,7,34,6),E(0,9,12,-6,0,19,29,2,0,7,36,6),E(0,10,13,-6,0,20,31,3,0,8,38,7),E(0,10,13,-6,0,21,33,3,0,8,40,7),E(0,10,14,-6,0,22,35,3,0,8,42,7),E(0,11,14,-7,0,23,36,3,0,9,44,8),E(0,11,15,-7,0,24,38,3,0,9,46,8)],M=n(5829),T={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},P=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function R(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.mixins,n=void 0===t?{}:t,u=e.palette,s=void 0===u?{}:u,c=e.transitions,d=void 0===c?{}:c,f=e.typography,p=void 0===f?{}:f,h=(0,o.Z)(e,P),m=D(s),v=(0,a.Z)(e),g=(0,i.Z)(v,{mixins:l(v.breakpoints,v.spacing,n),palette:m,shadows:A.slice(),typography:_(m,p),transitions:(0,M.ZP)(d),zIndex:(0,r.Z)({},T)});g=(0,i.Z)(g,h);for(var y=arguments.length,b=new Array(y>1?y-1:0),x=1;x0&&void 0!==arguments[0]?arguments[0]:["all"],o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=o.duration,u=void 0===a?n.standard:a,s=o.easing,c=void 0===s?t.easeInOut:s,d=o.delay,f=void 0===d?0:d;(0,r.Z)(o,i);return(Array.isArray(e)?e:[e]).map((function(e){return"".concat(e," ").concat("string"===typeof u?u:l(u)," ").concat(c," ").concat("string"===typeof f?f:l(f))})).join(",")}},e,{easing:t,duration:n})}},2248:function(e,t,n){"use strict";var r=(0,n(7458).Z)();t.Z=r},8564:function(e,t,n){"use strict";n.d(t,{ZP:function(){return _},FO:function(){return k},Dz:function(){return S}});var r=n(3433),o=n(9439),i=n(7462),a=n(3366),u=n(297),l=n(9456),s=n(114),c=["variant"];function d(e){return 0===e.length}function f(e){var t=e.variant,n=(0,a.Z)(e,c),r=t||"";return Object.keys(n).sort().forEach((function(t){r+="color"===t?d(r)?e[t]:(0,s.Z)(e[t]):"".concat(d(r)?t:(0,s.Z)(t)).concat((0,s.Z)(e[t].toString()))})),r}var p=n(3649),h=["name","slot","skipVariantsResolver","skipSx","overridesResolver"],m=["theme"],v=["theme"];function g(e){return 0===Object.keys(e).length}var y=function(e,t){return t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null},b=function(e,t){var n=[];t&&t.components&&t.components[e]&&t.components[e].variants&&(n=t.components[e].variants);var r={};return n.forEach((function(e){var t=f(e.props);r[t]=e.style})),r},x=function(e,t,n,r){var o,i,a=e.ownerState,u=void 0===a?{}:a,l=[],s=null==n||null==(o=n.components)||null==(i=o[r])?void 0:i.variants;return s&&s.forEach((function(n){var r=!0;Object.keys(n.props).forEach((function(t){u[t]!==n.props[t]&&e[t]!==n.props[t]&&(r=!1)})),r&&l.push(t[f(n.props)])})),l};function Z(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}var w=(0,l.Z)();var D=n(2248),k=function(e){return Z(e)&&"classes"!==e},S=Z,C=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.defaultTheme,n=void 0===t?w:t,l=e.rootShouldForwardProp,s=void 0===l?Z:l,c=e.slotShouldForwardProp,d=void 0===c?Z:c,f=e.styleFunctionSx,D=void 0===f?p.Z:f;return function(e){var t,l=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},c=l.name,f=l.slot,p=l.skipVariantsResolver,w=l.skipSx,k=l.overridesResolver,S=(0,a.Z)(l,h),C=void 0!==p?p:f&&"Root"!==f||!1,_=w||!1;var E=Z;"Root"===f?E=s:f&&(E=d);var A=(0,u.ZP)(e,(0,i.Z)({shouldForwardProp:E,label:t},S)),M=function(e){for(var t=arguments.length,u=new Array(t>1?t-1:0),l=1;l0){var p=new Array(f).fill("");(d=[].concat((0,r.Z)(e),(0,r.Z)(p))).raw=[].concat((0,r.Z)(e.raw),(0,r.Z)(p))}else"function"===typeof e&&e.__emotion_real!==e&&(d=function(t){var r=t.theme,o=(0,a.Z)(t,v);return e((0,i.Z)({theme:g(r)?n:r},o))});var h=A.apply(void 0,[d].concat((0,r.Z)(s)));return h};return A.withConfig&&(M.withConfig=A.withConfig),M}}({defaultTheme:D.Z,rootShouldForwardProp:k}),_=C},5469:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(4290),o=n(6728);var i=n(2248);function a(e){return function(e){var t=e.props,n=e.name,i=e.defaultTheme,a=(0,o.Z)(i);return(0,r.Z)({theme:a,name:n,props:t})}({props:e.props,name:e.name,defaultTheme:i.Z})}},1615:function(e,t,n){"use strict";var r=n(114);t.Z=r.Z},4750:function(e,t,n){"use strict";n.d(t,{Z:function(){return u}});var r=n(7462),o=n(4206),i=n(210),a=n(3138);function u(e,t){var n=function(n,o){return(0,a.tZ)(i.Z,(0,r.Z)({"data-testid":"".concat(t,"Icon"),ref:o},n,{children:e}))};return n.muiName=i.Z.muiName,o.memo(o.forwardRef(n))}},8706:function(e,t,n){"use strict";var r=n(4312);t.Z=r.Z},6415:function(e,t,n){"use strict";n.r(t),n.d(t,{capitalize:function(){return o.Z},createChainedFunction:function(){return i},createSvgIcon:function(){return a.Z},debounce:function(){return u.Z},deprecatedPropType:function(){return l},isMuiElement:function(){return s.Z},ownerDocument:function(){return c.Z},ownerWindow:function(){return d.Z},requirePropFactory:function(){return f},setRef:function(){return p},unstable_ClassNameGenerator:function(){return Z},unstable_useEnhancedEffect:function(){return h.Z},unstable_useId:function(){return m.Z},unsupportedProp:function(){return v},useControlled:function(){return g.Z},useEventCallback:function(){return y.Z},useForkRef:function(){return b.Z},useIsFocusVisible:function(){return x.Z}});var r=n(4496),o=n(1615),i=n(4246).Z,a=n(4750),u=n(8706);var l=function(e,t){return function(){return null}},s=n(7816),c=n(6106),d=n(3533);n(7462);var f=function(e,t){return function(){return null}},p=n(9265).Z,h=n(4993),m=n(7677);var v=function(e,t,n,r,o){return null},g=n(522),y=n(3236),b=n(6983),x=n(9127),Z={configure:function(e){console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join("\n")),r.Z.configure(e)}}},7816:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(4206);var o=function(e,t){return r.isValidElement(e)&&-1!==t.indexOf(e.type.muiName)}},6106:function(e,t,n){"use strict";var r=n(9081);t.Z=r.Z},3533:function(e,t,n){"use strict";var r=n(3282);t.Z=r.Z},522:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var r=n(9439),o=n(4206);var i=function(e){var t=e.controlled,n=e.default,i=(e.name,e.state,o.useRef(void 0!==t).current),a=o.useState(n),u=(0,r.Z)(a,2),l=u[0],s=u[1];return[i?t:l,o.useCallback((function(e){i||s(e)}),[])]}},4993:function(e,t,n){"use strict";var r=n(2678);t.Z=r.Z},3236:function(e,t,n){"use strict";var r=n(2780);t.Z=r.Z},6983:function(e,t,n){"use strict";var r=n(7472);t.Z=r.Z},7677:function(e,t,n){"use strict";var r=n(3362);t.Z=r.Z},9127:function(e,t,n){"use strict";n.d(t,{Z:function(){return f}});var r,o=n(4206),i=!0,a=!1,u={text:!0,search:!0,url:!0,tel:!0,email:!0,password:!0,number:!0,date:!0,month:!0,week:!0,time:!0,datetime:!0,"datetime-local":!0};function l(e){e.metaKey||e.altKey||e.ctrlKey||(i=!0)}function s(){i=!1}function c(){"hidden"===this.visibilityState&&a&&(i=!0)}function d(e){var t=e.target;try{return t.matches(":focus-visible")}catch(n){}return i||function(e){var t=e.type,n=e.tagName;return!("INPUT"!==n||!u[t]||e.readOnly)||"TEXTAREA"===n&&!e.readOnly||!!e.isContentEditable}(t)}var f=function(){var e=o.useCallback((function(e){var t;null!=e&&((t=e.ownerDocument).addEventListener("keydown",l,!0),t.addEventListener("mousedown",s,!0),t.addEventListener("pointerdown",s,!0),t.addEventListener("touchstart",s,!0),t.addEventListener("visibilitychange",c,!0))}),[]),t=o.useRef(!1);return{isFocusVisibleRef:t,onFocus:function(e){return!!d(e)&&(t.current=!0,!0)},onBlur:function(){return!!t.current&&(a=!0,window.clearTimeout(r),r=window.setTimeout((function(){a=!1}),100),t.current=!1,!0)},ref:e}}},5693:function(e,t,n){"use strict";var r=n(4206).createContext(null);t.Z=r},201:function(e,t,n){"use strict";n.d(t,{Z:function(){return i}});var r=n(4206),o=n(5693);function i(){return r.useContext(o.Z)}},297:function(e,t,n){"use strict";n.d(t,{ZP:function(){return x}});var r=n(4206),o=n(7462),i=n(3390),a=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,u=(0,i.Z)((function(e){return a.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})),l=n(6173),s=n(4911),c=n(4544),d=u,f=function(e){return"theme"!==e},p=function(e){return"string"===typeof e&&e.charCodeAt(0)>96?d:f},h=function(e,t,n){var r;if(t){var o=t.shouldForwardProp;r=e.__emotion_forwardProp&&o?function(t){return e.__emotion_forwardProp(t)&&o(t)}:o}return"function"!==typeof r&&n&&(r=e.__emotion_forwardProp),r},m=r.useInsertionEffect?r.useInsertionEffect:function(e){e()};var v=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;(0,s.hC)(t,n,r);m((function(){return(0,s.My)(t,n,r)}));return null},g=function e(t,n){var i,a,u=t.__emotion_real===t,d=u&&t.__emotion_base||t;void 0!==n&&(i=n.label,a=n.target);var f=h(t,n,u),m=f||p(d),g=!m("as");return function(){var y=arguments,b=u&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==i&&b.push("label:"+i+";"),null==y[0]||void 0===y[0].raw)b.push.apply(b,y);else{0,b.push(y[0][0]);for(var x=y.length,Z=1;Z0&&void 0!==arguments[0]?arguments[0]:{},n=null==t||null==(e=t.keys)?void 0:e.reduce((function(e,n){return e[t.up(n)]={},e}),{});return n||{}}function u(e,t){return e.reduce((function(e,t){var n=e[t];return(!n||0===Object.keys(n).length)&&delete e[t],e}),t)}function l(e){var t,n=e.values,r=e.breakpoints,o=e.base||function(e,t){if("object"!==typeof e)return{};var n={},r=Object.keys(t);return Array.isArray(e)?r.forEach((function(t,r){r1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return Math.min(Math.max(t,e),n)}function i(e){if(e.type)return e;if("#"===e.charAt(0))return i(function(e){e=e.slice(1);var t=new RegExp(".{1,".concat(e.length>=6?2:1,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map((function(e){return e+e}))),n?"rgb".concat(4===n.length?"a":"","(").concat(n.map((function(e,t){return t<3?parseInt(e,16):Math.round(parseInt(e,16)/255*1e3)/1e3})).join(", "),")"):""}(e));var t=e.indexOf("("),n=e.substring(0,t);if(-1===["rgb","rgba","hsl","hsla","color"].indexOf(n))throw new Error((0,r.Z)(9,e));var o,a=e.substring(t+1,e.length-1);if("color"===n){if(o=(a=a.split(" ")).shift(),4===a.length&&"/"===a[3].charAt(0)&&(a[3]=a[3].slice(1)),-1===["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(o))throw new Error((0,r.Z)(10,o))}else a=a.split(",");return{type:n,values:a=a.map((function(e){return parseFloat(e)})),colorSpace:o}}function a(e){var t=e.type,n=e.colorSpace,r=e.values;return-1!==t.indexOf("rgb")?r=r.map((function(e,t){return t<3?parseInt(e,10):e})):-1!==t.indexOf("hsl")&&(r[1]="".concat(r[1],"%"),r[2]="".concat(r[2],"%")),r=-1!==t.indexOf("color")?"".concat(n," ").concat(r.join(" ")):"".concat(r.join(", ")),"".concat(t,"(").concat(r,")")}function u(e){var t="hsl"===(e=i(e)).type?i(function(e){var t=(e=i(e)).values,n=t[0],r=t[1]/100,o=t[2]/100,u=r*Math.min(o,1-o),l=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:(e+n/30)%12;return o-u*Math.max(Math.min(t-3,9-t,1),-1)},s="rgb",c=[Math.round(255*l(0)),Math.round(255*l(8)),Math.round(255*l(4))];return"hsla"===e.type&&(s+="a",c.push(t[3])),a({type:s,values:c})}(e)).values:e.values;return t=t.map((function(t){return"color"!==e.type&&(t/=255),t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)})),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function l(e,t){var n=u(e),r=u(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function s(e,t){return e=i(e),t=o(t),"rgb"!==e.type&&"hsl"!==e.type||(e.type+="a"),"color"===e.type?e.values[3]="/".concat(t):e.values[3]=t,a(e)}function c(e,t){if(e=i(e),t=o(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb")||-1!==e.type.indexOf("color"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return a(e)}function d(e,t){if(e=i(e),t=o(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;else if(-1!==e.type.indexOf("color"))for(var r=0;r<3;r+=1)e.values[r]+=(1-e.values[r])*t;return a(e)}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return u(e)>.5?c(e,t):d(e,t)}},9456:function(e,t,n){"use strict";n.d(t,{Z:function(){return p}});var r=n(7462),o=n(3366),i=n(3019),a=n(4942),u=["values","unit","step"];function l(e){var t=e.values,n=void 0===t?{xs:0,sm:600,md:900,lg:1200,xl:1536}:t,i=e.unit,l=void 0===i?"px":i,s=e.step,c=void 0===s?5:s,d=(0,o.Z)(e,u),f=function(e){var t=Object.keys(e).map((function(t){return{key:t,val:e[t]}}))||[];return t.sort((function(e,t){return e.val-t.val})),t.reduce((function(e,t){return(0,r.Z)({},e,(0,a.Z)({},t.key,t.val))}),{})}(n),p=Object.keys(f);function h(e){var t="number"===typeof n[e]?n[e]:e;return"@media (min-width:".concat(t).concat(l,")")}function m(e){var t="number"===typeof n[e]?n[e]:e;return"@media (max-width:".concat(t-c/100).concat(l,")")}function v(e,t){var r=p.indexOf(t);return"@media (min-width:".concat("number"===typeof n[e]?n[e]:e).concat(l,") and ")+"(max-width:".concat((-1!==r&&"number"===typeof n[p[r]]?n[p[r]]:t)-c/100).concat(l,")")}return(0,r.Z)({keys:p,values:f,up:h,down:m,between:v,only:function(e){return p.indexOf(e)+10&&void 0!==arguments[0]?arguments[0]:8;if(e.mui)return e;var t=(0,c.hB)({spacing:e}),n=function(){for(var e=arguments.length,n=new Array(e),r=0;r0&&void 0!==arguments[0]?arguments[0]:{},t=e.breakpoints,n=void 0===t?{}:t,a=e.palette,u=void 0===a?{}:a,c=e.spacing,p=e.shape,h=void 0===p?{}:p,m=(0,o.Z)(e,f),v=l(n),g=d(c),y=(0,i.Z)({breakpoints:v,direction:"ltr",components:{},palette:(0,r.Z)({mode:"light"},u),spacing:g,shape:(0,r.Z)({},s,h)},m),b=arguments.length,x=new Array(b>1?b-1:0),Z=1;Z2){if(!s[e])return[e];e=s[e]}var t=e.split(""),n=(0,r.Z)(t,2),o=n[0],i=n[1],a=u[o],c=l[i]||"";return Array.isArray(c)?c.map((function(e){return a+e})):[a+c]})),d=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],f=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"],p=[].concat(d,f);function h(e,t,n,r){var o,a=null!=(o=(0,i.D)(e,t))?o:n;return"number"===typeof a?function(e){return"string"===typeof e?e:a*e}:Array.isArray(a)?function(e){return"string"===typeof e?e:a[e]}:"function"===typeof a?a:function(){}}function m(e){return h(e,"spacing",8)}function v(e,t){if("string"===typeof t||null==t)return t;var n=e(Math.abs(t));return t>=0?n:"number"===typeof n?-n:"-".concat(n)}function g(e,t,n,r){if(-1===t.indexOf(n))return null;var i=function(e,t){return function(n){return e.reduce((function(e,r){return e[r]=v(t,n),e}),{})}}(c(n),r),a=e[n];return(0,o.k9)(e,a,i)}function y(e,t){var n=m(e.theme);return Object.keys(e).map((function(r){return g(e,t,r,n)})).reduce(a.Z,{})}function b(e){return y(e,d)}function x(e){return y(e,f)}function Z(e){return y(e,p)}b.propTypes={},b.filterProps=d,x.propTypes={},x.filterProps=f,Z.propTypes={},Z.filterProps=p;var w=Z},6428:function(e,t,n){"use strict";n.d(t,{D:function(){return a}});var r=n(4942),o=n(114),i=n(4929);function a(e,t){if(!t||"string"!==typeof t)return null;if(e&&e.vars){var n="vars.".concat(t).split(".").reduce((function(e,t){return e&&e[t]?e[t]:null}),e);if(null!=n)return n}return t.split(".").reduce((function(e,t){return e&&null!=e[t]?e[t]:null}),e)}function u(e,t,n){var r,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n;return r="function"===typeof e?e(n):Array.isArray(e)?e[n]||o:a(e,n)||o,t&&(r=t(r)),r}t.Z=function(e){var t=e.prop,n=e.cssProperty,l=void 0===n?e.prop:n,s=e.themeKey,c=e.transform,d=function(e){if(null==e[t])return null;var n=e[t],d=a(e.theme,s)||{};return(0,i.k9)(e,n,(function(e){var n=u(d,c,e);return e===n&&"string"===typeof e&&(n=u(d,c,"".concat(t).concat("default"===e?"":(0,o.Z)(e)),e)),!1===l?n:(0,r.Z)({},l,n)}))};return d.propTypes={},d.filterProps=[t],d}},3649:function(e,t,n){"use strict";var r=n(4942),o=n(7330),i=n(9716),a=n(4929);function u(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:i.G$,t=Object.keys(e).reduce((function(t,n){return e[n].filterProps.forEach((function(r){t[r]=e[n]})),t}),{});function n(e,n,o){var i,a=(i={},(0,r.Z)(i,e,n),(0,r.Z)(i,"theme",o),i),u=t[e];return u?u(a):(0,r.Z)({},e,n)}function s(e){var i=e||{},c=i.sx,d=i.theme,f=void 0===d?{}:d;if(!c)return null;function p(e){var i=e;if("function"===typeof e)i=e(f);else if("object"!==typeof e)return e;if(!i)return null;var c=(0,a.W8)(f.breakpoints),d=Object.keys(c),p=c;return Object.keys(i).forEach((function(e){var c=l(i[e],f);if(null!==c&&void 0!==c)if("object"===typeof c)if(t[e])p=(0,o.Z)(p,n(e,c,f));else{var d=(0,a.k9)({theme:f},c,(function(t){return(0,r.Z)({},e,t)}));u(d,c)?p[e]=s({sx:c,theme:f}):p=(0,o.Z)(p,d)}else p=(0,o.Z)(p,n(e,c,f))})),(0,a.L7)(d,p)}return Array.isArray(c)?c.map(p):p(c)}return s}();s.filterProps=["sx"],t.Z=s},6728:function(e,t,n){"use strict";var r=n(9456),o=n(4976),i=(0,r.Z)();t.Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:i;return(0,o.Z)(e)}},4290:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(9023);function o(e){var t=e.theme,n=e.name,o=e.props;return t&&t.components&&t.components[n]&&t.components[n].defaultProps?(0,r.Z)(t.components[n].defaultProps,o):o}},4976:function(e,t,n){"use strict";var r=n(201);function o(e){return 0===Object.keys(e).length}t.Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=(0,r.Z)();return!t||o(t)?e:t}},114:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(7219);function o(e){if("string"!==typeof e)throw new Error((0,r.Z)(7));return e.charAt(0).toUpperCase()+e.slice(1)}},4246:function(e,t,n){"use strict";function r(){for(var e=arguments.length,t=new Array(e),n=0;n1&&void 0!==arguments[1]?arguments[1]:166;function r(){for(var r=this,o=arguments.length,i=new Array(o),a=0;a2&&void 0!==arguments[2]?arguments[2]:{clone:!0},a=n.clone?(0,r.Z)({},e):e;return o(e)&&o(t)&&Object.keys(t).forEach((function(r){"__proto__"!==r&&(o(t[r])&&r in e&&o(e[r])?a[r]=i(e[r],t[r],n):a[r]=t[r])})),a}},7219:function(e,t,n){"use strict";function r(e){for(var t="https://mui.com/production-error/?code="+e,n=1;n-1?o(n):n}},9962:function(e,t,n){"use strict";var r=n(1199),o=n(8476),i=o("%Function.prototype.apply%"),a=o("%Function.prototype.call%"),u=o("%Reflect.apply%",!0)||r.call(a,i),l=o("%Object.getOwnPropertyDescriptor%",!0),s=o("%Object.defineProperty%",!0),c=o("%Math.max%");if(s)try{s({},"a",{value:1})}catch(f){s=null}e.exports=function(e){var t=u(r,a,arguments);if(l&&s){var n=l(t,"length");n.configurable&&s(t,"length",{value:1+c(0,e.length-(arguments.length-1))})}return t};var d=function(){return u(r,i,arguments)};s?s(e.exports,"apply",{value:d}):e.exports.apply=d},3061:function(e,t,n){"use strict";function r(e){var t,n,o="";if("string"===typeof e||"number"===typeof e)o+=e;else if("object"===typeof e)if(Array.isArray(e))for(t=0;t=t?e:""+Array(t+1-r.length).join(n)+e},y={s:g,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),r=Math.floor(n/60),o=n%60;return(t<=0?"+":"-")+g(r,2,"0")+":"+g(o,2,"0")},m:function e(t,n){if(t.date()1)return e(a[0])}else{var u=t.name;x[u]=t,o=u}return!r&&o&&(b=o),o||!r&&b},D=function(e,t){if(Z(e))return e.clone();var n="object"==typeof t?t:{};return n.date=e,n.args=arguments,new S(n)},k=y;k.l=w,k.i=Z,k.w=function(e,t){return D(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var S=function(){function v(e){this.$L=w(e.locale,null,!0),this.parse(e)}var g=v.prototype;return g.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(null===t)return new Date(NaN);if(k.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var r=t.match(h);if(r){var o=r[2]-1||0,i=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],o,r[3]||1,r[4]||0,r[5]||0,r[6]||0,i)):new Date(r[1],o,r[3]||1,r[4]||0,r[5]||0,r[6]||0,i)}}return new Date(t)}(e),this.$x=e.x||{},this.init()},g.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},g.$utils=function(){return k},g.isValid=function(){return!(this.$d.toString()===p)},g.isSame=function(e,t){var n=D(e);return this.startOf(t)<=n&&n<=this.endOf(t)},g.isAfter=function(e,t){return D(e)68?1900:2e3)},u=function(e){return function(t){this[e]=+t}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e)return 0;if("Z"===e)return 0;var t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return 0===n?0:"+"===t[0]?-n:n}(e)}],s=function(e){var t=i[e];return t&&(t.indexOf?t:t.s.concat(t.f))},c=function(e,t){var n,r=i.meridiem;if(r){for(var o=1;o<=24;o+=1)if(e.indexOf(r(o,0,t))>-1){n=o>12;break}}else n=e===(t?"pm":"PM");return n},d={A:[o,function(e){this.afternoon=c(e,!1)}],a:[o,function(e){this.afternoon=c(e,!0)}],S:[/\d/,function(e){this.milliseconds=100*+e}],SS:[n,function(e){this.milliseconds=10*+e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[r,u("seconds")],ss:[r,u("seconds")],m:[r,u("minutes")],mm:[r,u("minutes")],H:[r,u("hours")],h:[r,u("hours")],HH:[r,u("hours")],hh:[r,u("hours")],D:[r,u("day")],DD:[n,u("day")],Do:[o,function(e){var t=i.ordinal,n=e.match(/\d+/);if(this.day=n[0],t)for(var r=1;r<=31;r+=1)t(r).replace(/\[|\]/g,"")===e&&(this.day=r)}],M:[r,u("month")],MM:[n,u("month")],MMM:[o,function(e){var t=s("months"),n=(s("monthsShort")||t.map((function(e){return e.slice(0,3)}))).indexOf(e)+1;if(n<1)throw new Error;this.month=n%12||n}],MMMM:[o,function(e){var t=s("months").indexOf(e)+1;if(t<1)throw new Error;this.month=t%12||t}],Y:[/[+-]?\d+/,u("year")],YY:[n,function(e){this.year=a(e)}],YYYY:[/\d{4}/,u("year")],Z:l,ZZ:l};function f(n){var r,o;r=n,o=i&&i.formats;for(var a=(n=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(t,n,r){var i=r&&r.toUpperCase();return n||o[r]||e[r]||o[i].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(e,t,n){return t||n.slice(1)}))}))).match(t),u=a.length,l=0;l-1)return new Date(("X"===t?1e3:1)*e);var r=f(t)(e),o=r.year,i=r.month,a=r.day,u=r.hours,l=r.minutes,s=r.seconds,c=r.milliseconds,d=r.zone,p=new Date,h=a||(o||i?1:p.getDate()),m=o||p.getFullYear(),v=0;o&&!i||(v=i>0?i-1:p.getMonth());var g=u||0,y=l||0,b=s||0,x=c||0;return d?new Date(Date.UTC(m,v,h,g,y,b,x+60*d.offset*1e3)):n?new Date(Date.UTC(m,v,h,g,y,b,x)):new Date(m,v,h,g,y,b,x)}catch(e){return new Date("")}}(t,u,r),this.init(),d&&!0!==d&&(this.$L=this.locale(d).$L),c&&t!=this.format(u)&&(this.$d=new Date("")),i={}}else if(u instanceof Array)for(var p=u.length,h=1;h<=p;h+=1){a[1]=u[h-1];var m=n.apply(this,a);if(m.isValid()){this.$d=m.$d,this.$L=m.$L,this.init();break}h===p&&(this.$d=new Date(""))}else o.call(this,e)}}}()},6446:function(e){e.exports=function(){"use strict";var e,t,n=1e3,r=6e4,o=36e5,i=864e5,a=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,u=31536e6,l=2592e6,s=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,c={years:u,months:l,days:i,hours:o,minutes:r,seconds:n,milliseconds:1,weeks:6048e5},d=function(e){return e instanceof y},f=function(e,t,n){return new y(e,n,t.$l)},p=function(e){return t.p(e)+"s"},h=function(e){return e<0},m=function(e){return h(e)?Math.ceil(e):Math.floor(e)},v=function(e){return Math.abs(e)},g=function(e,t){return e?h(e)?{negative:!0,format:""+v(e)+t}:{negative:!1,format:""+e+t}:{negative:!1,format:""}},y=function(){function h(e,t,n){var r=this;if(this.$d={},this.$l=n,void 0===e&&(this.$ms=0,this.parseFromMilliseconds()),t)return f(e*c[p(t)],this);if("number"==typeof e)return this.$ms=e,this.parseFromMilliseconds(),this;if("object"==typeof e)return Object.keys(e).forEach((function(t){r.$d[p(t)]=e[t]})),this.calMilliseconds(),this;if("string"==typeof e){var o=e.match(s);if(o){var i=o.slice(2).map((function(e){return null!=e?Number(e):0}));return this.$d.years=i[0],this.$d.months=i[1],this.$d.weeks=i[2],this.$d.days=i[3],this.$d.hours=i[4],this.$d.minutes=i[5],this.$d.seconds=i[6],this.calMilliseconds(),this}}return this}var v=h.prototype;return v.calMilliseconds=function(){var e=this;this.$ms=Object.keys(this.$d).reduce((function(t,n){return t+(e.$d[n]||0)*c[n]}),0)},v.parseFromMilliseconds=function(){var e=this.$ms;this.$d.years=m(e/u),e%=u,this.$d.months=m(e/l),e%=l,this.$d.days=m(e/i),e%=i,this.$d.hours=m(e/o),e%=o,this.$d.minutes=m(e/r),e%=r,this.$d.seconds=m(e/n),e%=n,this.$d.milliseconds=e},v.toISOString=function(){var e=g(this.$d.years,"Y"),t=g(this.$d.months,"M"),n=+this.$d.days||0;this.$d.weeks&&(n+=7*this.$d.weeks);var r=g(n,"D"),o=g(this.$d.hours,"H"),i=g(this.$d.minutes,"M"),a=this.$d.seconds||0;this.$d.milliseconds&&(a+=this.$d.milliseconds/1e3);var u=g(a,"S"),l=e.negative||t.negative||r.negative||o.negative||i.negative||u.negative,s=o.format||i.format||u.format?"T":"",c=(l?"-":"")+"P"+e.format+t.format+r.format+s+o.format+i.format+u.format;return"P"===c||"-P"===c?"P0D":c},v.toJSON=function(){return this.toISOString()},v.format=function(e){var n=e||"YYYY-MM-DDTHH:mm:ss",r={Y:this.$d.years,YY:t.s(this.$d.years,2,"0"),YYYY:t.s(this.$d.years,4,"0"),M:this.$d.months,MM:t.s(this.$d.months,2,"0"),D:this.$d.days,DD:t.s(this.$d.days,2,"0"),H:this.$d.hours,HH:t.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:t.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:t.s(this.$d.seconds,2,"0"),SSS:t.s(this.$d.milliseconds,3,"0")};return n.replace(a,(function(e,t){return t||String(r[e])}))},v.as=function(e){return this.$ms/c[p(e)]},v.get=function(e){var t=this.$ms,n=p(e);return"milliseconds"===n?t%=1e3:t="weeks"===n?m(t/c[n]):this.$d[n],0===t?0:t},v.add=function(e,t,n){var r;return r=t?e*c[p(t)]:d(e)?e.$ms:f(e,this).$ms,f(this.$ms+r*(n?-1:1),this)},v.subtract=function(e,t){return this.add(e,t,!0)},v.locale=function(e){var t=this.clone();return t.$l=e,t},v.clone=function(){return f(this.$ms,this)},v.humanize=function(t){return e().add(this.$ms,"ms").locale(this.$l).fromNow(!t)},v.milliseconds=function(){return this.get("milliseconds")},v.asMilliseconds=function(){return this.as("milliseconds")},v.seconds=function(){return this.get("seconds")},v.asSeconds=function(){return this.as("seconds")},v.minutes=function(){return this.get("minutes")},v.asMinutes=function(){return this.as("minutes")},v.hours=function(){return this.get("hours")},v.asHours=function(){return this.as("hours")},v.days=function(){return this.get("days")},v.asDays=function(){return this.as("days")},v.weeks=function(){return this.get("weeks")},v.asWeeks=function(){return this.as("weeks")},v.months=function(){return this.get("months")},v.asMonths=function(){return this.as("months")},v.years=function(){return this.get("years")},v.asYears=function(){return this.as("years")},h}();return function(n,r,o){e=o,t=o().$utils(),o.duration=function(e,t){var n=o.locale();return f(e,{$l:n},t)},o.isDuration=d;var i=r.prototype.add,a=r.prototype.subtract;r.prototype.add=function(e,t){return d(e)&&(e=e.asMilliseconds()),i.bind(this)(e,t)},r.prototype.subtract=function(e,t){return d(e)&&(e=e.asMilliseconds()),a.bind(this)(e,t)}}}()},8743:function(e){e.exports=function(){"use strict";return function(e,t,n){t.prototype.isBetween=function(e,t,r,o){var i=n(e),a=n(t),u="("===(o=o||"()")[0],l=")"===o[1];return(u?this.isAfter(i,r):!this.isBefore(i,r))&&(l?this.isBefore(a,r):!this.isAfter(a,r))||(u?this.isBefore(i,r):!this.isAfter(i,r))&&(l?this.isAfter(a,r):!this.isBefore(a,r))}}}()},3825:function(e){e.exports=function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(t,n,r){var o=n.prototype,i=o.format;r.en.formats=e,o.format=function(t){void 0===t&&(t="YYYY-MM-DDTHH:mm:ssZ");var n=this.$locale().formats,r=function(t,n){return t.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(t,r,o){var i=o&&o.toUpperCase();return r||n[o]||e[o]||n[i].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(e,t,n){return t||n.slice(1)}))}))}(t,void 0===n?{}:n);return i.call(this,r)}}}()},1635:function(e){e.exports=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,n=/([+-]|\d\d)/g;return function(r,o,i){var a=o.prototype;i.utc=function(e){return new o({date:e,utc:!0,args:arguments})},a.utc=function(t){var n=i(this.toDate(),{locale:this.$L,utc:!0});return t?n.add(this.utcOffset(),e):n},a.local=function(){return i(this.toDate(),{locale:this.$L,utc:!1})};var u=a.parse;a.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),u.call(this,e)};var l=a.init;a.init=function(){if(this.$u){var e=this.$d;this.$y=e.getUTCFullYear(),this.$M=e.getUTCMonth(),this.$D=e.getUTCDate(),this.$W=e.getUTCDay(),this.$H=e.getUTCHours(),this.$m=e.getUTCMinutes(),this.$s=e.getUTCSeconds(),this.$ms=e.getUTCMilliseconds()}else l.call(this)};var s=a.utcOffset;a.utcOffset=function(r,o){var i=this.$utils().u;if(i(r))return this.$u?0:i(this.$offset)?s.call(this):this.$offset;if("string"==typeof r&&(r=function(e){void 0===e&&(e="");var r=e.match(t);if(!r)return null;var o=(""+r[0]).match(n)||["-",0,0],i=o[0],a=60*+o[1]+ +o[2];return 0===a?0:"+"===i?a:-a}(r),null===r))return this;var a=Math.abs(r)<=16?60*r:r,u=this;if(o)return u.$offset=a,u.$u=0===r,u;if(0!==r){var l=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(u=this.local().add(a+l,e)).$offset=a,u.$x.$localOffset=l}else u=this.utc();return u};var c=a.format;a.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return c.call(this,t)},a.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||(new Date).getTimezoneOffset());return this.$d.valueOf()-6e4*e},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var d=a.toDate;a.toDate=function(e){return"s"===e&&this.$offset?i(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var f=a.diff;a.diff=function(e,t,n){if(e&&this.$u===e.$u)return f.call(this,e,t,n);var r=this.local(),o=i(e).local();return f.call(r,o,t,n)}}}()},2781:function(e){"use strict";var t="Function.prototype.bind called on incompatible ",n=Array.prototype.slice,r=Object.prototype.toString,o="[object Function]";e.exports=function(e){var i=this;if("function"!==typeof i||r.call(i)!==o)throw new TypeError(t+i);for(var a,u=n.call(arguments,1),l=function(){if(this instanceof a){var t=i.apply(this,u.concat(n.call(arguments)));return Object(t)===t?t:this}return i.apply(e,u.concat(n.call(arguments)))},s=Math.max(0,i.length-u.length),c=[],d=0;d1&&"boolean"!==typeof t)throw new a('"allowMissing" argument must be a boolean');var n=C(e),r=n.length>0?n[0]:"",i=_("%"+r+"%",t),u=i.name,s=i.value,c=!1,d=i.alias;d&&(r=d[0],Z(n,x([0,1],d)));for(var f=1,p=!0;f=n.length){var y=l(s,h);s=(p=!!y)&&"get"in y&&!("originalValue"in y.get)?y.get:s[h]}else p=b(s,h),s=s[h];p&&!c&&(m[u]=s)}}return s}},5520:function(e,t,n){"use strict";var r="undefined"!==typeof Symbol&&Symbol,o=n(541);e.exports=function(){return"function"===typeof r&&("function"===typeof Symbol&&("symbol"===typeof r("foo")&&("symbol"===typeof Symbol("bar")&&o())))}},541:function(e){"use strict";e.exports=function(){if("function"!==typeof Symbol||"function"!==typeof Object.getOwnPropertySymbols)return!1;if("symbol"===typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),n=Object(t);if("string"===typeof t)return!1;if("[object Symbol]"!==Object.prototype.toString.call(t))return!1;if("[object Symbol]"!==Object.prototype.toString.call(n))return!1;for(t in e[t]=42,e)return!1;if("function"===typeof Object.keys&&0!==Object.keys(e).length)return!1;if("function"===typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var r=Object.getOwnPropertySymbols(e);if(1!==r.length||r[0]!==t)return!1;if(!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"===typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(42!==o.value||!0!==o.enumerable)return!1}return!0}},7838:function(e,t,n){"use strict";var r=n(1199);e.exports=r.call(Function.call,Object.prototype.hasOwnProperty)},7861:function(e,t,n){"use strict";var r=n(2535),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},u={};function l(e){return r.isMemo(e)?a:u[e.$$typeof]||o}u[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},u[r.Memo]=a;var s=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!==typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=c(n);d&&(a=a.concat(d(n)));for(var u=l(t),m=l(n),v=0;v=t||n<0||d&&e-s>=i}function Z(){var e=h();if(x(e))return w(e);u=setTimeout(Z,function(e){var n=t-(e-l);return d?p(n,i-(e-s)):n}(e))}function w(e){return u=void 0,g&&r?y(e):(r=o=void 0,a)}function D(){var e=h(),n=x(e);if(r=arguments,o=this,l=e,n){if(void 0===u)return b(l);if(d)return u=setTimeout(Z,t),y(l)}return void 0===u&&(u=setTimeout(Z,t)),a}return t=v(t)||0,m(n)&&(c=!!n.leading,i=(d="maxWait"in n)?f(v(n.maxWait)||0,t):i,g="trailing"in n?!!n.trailing:g),D.cancel=function(){void 0!==u&&clearTimeout(u),s=0,r=l=o=u=void 0},D.flush=function(){return void 0===u?a:w(h())},D}},4007:function(e,t,n){var r="__lodash_hash_undefined__",o="[object Function]",i="[object GeneratorFunction]",a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,u=/^\w*$/,l=/^\./,s=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,c=/\\(\\)?/g,d=/^\[object .+?Constructor\]$/,f="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,p="object"==typeof self&&self&&self.Object===Object&&self,h=f||p||Function("return this")();var m=Array.prototype,v=Function.prototype,g=Object.prototype,y=h["__core-js_shared__"],b=function(){var e=/[^.]+$/.exec(y&&y.keys&&y.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),x=v.toString,Z=g.hasOwnProperty,w=g.toString,D=RegExp("^"+x.call(Z).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),k=h.Symbol,S=m.splice,C=I(h,"Map"),_=I(Object,"create"),E=k?k.prototype:void 0,A=E?E.toString:void 0;function M(e){var t=-1,n=e?e.length:0;for(this.clear();++t-1},T.prototype.set=function(e,t){var n=this.__data__,r=R(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},P.prototype.clear=function(){this.__data__={hash:new M,map:new(C||T),string:new M}},P.prototype.delete=function(e){return B(this,e).delete(e)},P.prototype.get=function(e){return B(this,e).get(e)},P.prototype.has=function(e){return B(this,e).has(e)},P.prototype.set=function(e,t){return B(this,e).set(e,t),this};var L=z((function(e){var t;e=null==(t=e)?"":function(e){if("string"==typeof e)return e;if($(e))return A?A.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(t);var n=[];return l.test(e)&&n.push(""),e.replace(s,(function(e,t,r,o){n.push(r?o.replace(c,"$1"):t||e)})),n}));function N(e){if("string"==typeof e||$(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function z(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function n(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a),a};return n.cache=new(z.Cache||P),n}z.Cache=P;var j=Array.isArray;function W(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function $(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==w.call(e)}e.exports=function(e,t,n){var r=null==e?void 0:F(e,t);return void 0===r?n:r}},2061:function(e,t,n){var r="Expected a function",o=/^\s+|\s+$/g,i=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,u=/^0o[0-7]+$/i,l=parseInt,s="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g,c="object"==typeof self&&self&&self.Object===Object&&self,d=s||c||Function("return this")(),f=Object.prototype.toString,p=Math.max,h=Math.min,m=function(){return d.Date.now()};function v(e,t,n){var o,i,a,u,l,s,c=0,d=!1,f=!1,v=!0;if("function"!=typeof e)throw new TypeError(r);function b(t){var n=o,r=i;return o=i=void 0,c=t,u=e.apply(r,n)}function x(e){return c=e,l=setTimeout(w,t),d?b(e):u}function Z(e){var n=e-s;return void 0===s||n>=t||n<0||f&&e-c>=a}function w(){var e=m();if(Z(e))return D(e);l=setTimeout(w,function(e){var n=t-(e-s);return f?h(n,a-(e-c)):n}(e))}function D(e){return l=void 0,v&&o?b(e):(o=i=void 0,u)}function k(){var e=m(),n=Z(e);if(o=arguments,i=this,s=e,n){if(void 0===l)return x(s);if(f)return l=setTimeout(w,t),b(s)}return void 0===l&&(l=setTimeout(w,t)),u}return t=y(t)||0,g(n)&&(d=!!n.leading,a=(f="maxWait"in n)?p(y(n.maxWait)||0,t):a,v="trailing"in n?!!n.trailing:v),k.cancel=function(){void 0!==l&&clearTimeout(l),c=0,o=s=i=l=void 0},k.flush=function(){return void 0===l?u:D(m())},k}function g(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function y(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==f.call(e)}(e))return NaN;if(g(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=g(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var n=a.test(e);return n||u.test(e)?l(e.slice(2),n?2:8):i.test(e)?NaN:+e}e.exports=function(e,t,n){var o=!0,i=!0;if("function"!=typeof e)throw new TypeError(r);return g(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),v(e,t,{leading:o,maxWait:t,trailing:i})}},3154:function(e,t,n){var r="function"===typeof Map&&Map.prototype,o=Object.getOwnPropertyDescriptor&&r?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,i=r&&o&&"function"===typeof o.get?o.get:null,a=r&&Map.prototype.forEach,u="function"===typeof Set&&Set.prototype,l=Object.getOwnPropertyDescriptor&&u?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,s=u&&l&&"function"===typeof l.get?l.get:null,c=u&&Set.prototype.forEach,d="function"===typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,f="function"===typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,p="function"===typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,h=Boolean.prototype.valueOf,m=Object.prototype.toString,v=Function.prototype.toString,g=String.prototype.match,y=String.prototype.slice,b=String.prototype.replace,x=String.prototype.toUpperCase,Z=String.prototype.toLowerCase,w=RegExp.prototype.test,D=Array.prototype.concat,k=Array.prototype.join,S=Array.prototype.slice,C=Math.floor,_="function"===typeof BigInt?BigInt.prototype.valueOf:null,E=Object.getOwnPropertySymbols,A="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?Symbol.prototype.toString:null,M="function"===typeof Symbol&&"object"===typeof Symbol.iterator,T="function"===typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===M||"symbol")?Symbol.toStringTag:null,P=Object.prototype.propertyIsEnumerable,R=("function"===typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(e){return e.__proto__}:null);function F(e,t){if(e===1/0||e===-1/0||e!==e||e&&e>-1e3&&e<1e3||w.call(/e/,t))return t;var n=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"===typeof e){var r=e<0?-C(-e):C(e);if(r!==e){var o=String(r),i=y.call(t,o.length+1);return b.call(o,n,"$&_")+"."+b.call(b.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return b.call(t,n,"$&_")}var O=n(4654).custom,B=O&&z(O)?O:null;function I(e,t,n){var r="double"===(n.quoteStyle||t)?'"':"'";return r+e+r}function L(e){return b.call(String(e),/"/g,""")}function N(e){return"[object Array]"===$(e)&&(!T||!("object"===typeof e&&T in e))}function z(e){if(M)return e&&"object"===typeof e&&e instanceof Symbol;if("symbol"===typeof e)return!0;if(!e||"object"!==typeof e||!A)return!1;try{return A.call(e),!0}catch(t){}return!1}e.exports=function e(t,n,r,o){var u=n||{};if(W(u,"quoteStyle")&&"single"!==u.quoteStyle&&"double"!==u.quoteStyle)throw new TypeError('option "quoteStyle" must be "single" or "double"');if(W(u,"maxStringLength")&&("number"===typeof u.maxStringLength?u.maxStringLength<0&&u.maxStringLength!==1/0:null!==u.maxStringLength))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var l=!W(u,"customInspect")||u.customInspect;if("boolean"!==typeof l&&"symbol"!==l)throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(W(u,"indent")&&null!==u.indent&&"\t"!==u.indent&&!(parseInt(u.indent,10)===u.indent&&u.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(W(u,"numericSeparator")&&"boolean"!==typeof u.numericSeparator)throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var m=u.numericSeparator;if("undefined"===typeof t)return"undefined";if(null===t)return"null";if("boolean"===typeof t)return t?"true":"false";if("string"===typeof t)return Y(t,u);if("number"===typeof t){if(0===t)return 1/0/t>0?"0":"-0";var x=String(t);return m?F(t,x):x}if("bigint"===typeof t){var w=String(t)+"n";return m?F(t,w):w}var C="undefined"===typeof u.depth?5:u.depth;if("undefined"===typeof r&&(r=0),r>=C&&C>0&&"object"===typeof t)return N(t)?"[Array]":"[Object]";var E=function(e,t){var n;if("\t"===e.indent)n="\t";else{if(!("number"===typeof e.indent&&e.indent>0))return null;n=k.call(Array(e.indent+1)," ")}return{base:n,prev:k.call(Array(t+1),n)}}(u,r);if("undefined"===typeof o)o=[];else if(H(o,t)>=0)return"[Circular]";function O(t,n,i){if(n&&(o=S.call(o)).push(n),i){var a={depth:u.depth};return W(u,"quoteStyle")&&(a.quoteStyle=u.quoteStyle),e(t,a,r+1,o)}return e(t,u,r+1,o)}if("function"===typeof t){var j=function(e){if(e.name)return e.name;var t=g.call(v.call(e),/^function\s*([\w$]+)/);if(t)return t[1];return null}(t),V=K(t,O);return"[Function"+(j?": "+j:" (anonymous)")+"]"+(V.length>0?" { "+k.call(V,", ")+" }":"")}if(z(t)){var Q=M?b.call(String(t),/^(Symbol\(.*\))_[^)]*$/,"$1"):A.call(t);return"object"!==typeof t||M?Q:U(Q)}if(function(e){if(!e||"object"!==typeof e)return!1;if("undefined"!==typeof HTMLElement&&e instanceof HTMLElement)return!0;return"string"===typeof e.nodeName&&"function"===typeof e.getAttribute}(t)){for(var J="<"+Z.call(String(t.nodeName)),ee=t.attributes||[],te=0;te",t.childNodes&&t.childNodes.length&&(J+="..."),J+=""+Z.call(String(t.nodeName))+">"}if(N(t)){if(0===t.length)return"[]";var ne=K(t,O);return E&&!function(e){for(var t=0;t=0)return!1;return!0}(ne)?"["+G(ne,E)+"]":"[ "+k.call(ne,", ")+" ]"}if(function(e){return"[object Error]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t)){var re=K(t,O);return"cause"in t&&!P.call(t,"cause")?"{ ["+String(t)+"] "+k.call(D.call("[cause]: "+O(t.cause),re),", ")+" }":0===re.length?"["+String(t)+"]":"{ ["+String(t)+"] "+k.call(re,", ")+" }"}if("object"===typeof t&&l){if(B&&"function"===typeof t[B])return t[B]();if("symbol"!==l&&"function"===typeof t.inspect)return t.inspect()}if(function(e){if(!i||!e||"object"!==typeof e)return!1;try{i.call(e);try{s.call(e)}catch(J){return!0}return e instanceof Map}catch(t){}return!1}(t)){var oe=[];return a.call(t,(function(e,n){oe.push(O(n,t,!0)+" => "+O(e,t))})),X("Map",i.call(t),oe,E)}if(function(e){if(!s||!e||"object"!==typeof e)return!1;try{s.call(e);try{i.call(e)}catch(t){return!0}return e instanceof Set}catch(n){}return!1}(t)){var ie=[];return c.call(t,(function(e){ie.push(O(e,t))})),X("Set",s.call(t),ie,E)}if(function(e){if(!d||!e||"object"!==typeof e)return!1;try{d.call(e,d);try{f.call(e,f)}catch(J){return!0}return e instanceof WeakMap}catch(t){}return!1}(t))return q("WeakMap");if(function(e){if(!f||!e||"object"!==typeof e)return!1;try{f.call(e,f);try{d.call(e,d)}catch(J){return!0}return e instanceof WeakSet}catch(t){}return!1}(t))return q("WeakSet");if(function(e){if(!p||!e||"object"!==typeof e)return!1;try{return p.call(e),!0}catch(t){}return!1}(t))return q("WeakRef");if(function(e){return"[object Number]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t))return U(O(Number(t)));if(function(e){if(!e||"object"!==typeof e||!_)return!1;try{return _.call(e),!0}catch(t){}return!1}(t))return U(O(_.call(t)));if(function(e){return"[object Boolean]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t))return U(h.call(t));if(function(e){return"[object String]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t))return U(O(String(t)));if(!function(e){return"[object Date]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t)&&!function(e){return"[object RegExp]"===$(e)&&(!T||!("object"===typeof e&&T in e))}(t)){var ae=K(t,O),ue=R?R(t)===Object.prototype:t instanceof Object||t.constructor===Object,le=t instanceof Object?"":"null prototype",se=!ue&&T&&Object(t)===t&&T in t?y.call($(t),8,-1):le?"Object":"",ce=(ue||"function"!==typeof t.constructor?"":t.constructor.name?t.constructor.name+" ":"")+(se||le?"["+k.call(D.call([],se||[],le||[]),": ")+"] ":"");return 0===ae.length?ce+"{}":E?ce+"{"+G(ae,E)+"}":ce+"{ "+k.call(ae,", ")+" }"}return String(t)};var j=Object.prototype.hasOwnProperty||function(e){return e in this};function W(e,t){return j.call(e,t)}function $(e){return m.call(e)}function H(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;nt.maxStringLength){var n=e.length-t.maxStringLength,r="... "+n+" more character"+(n>1?"s":"");return Y(y.call(e,0,t.maxStringLength),t)+r}return I(b.call(b.call(e,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,V),"single",t)}function V(e){var t=e.charCodeAt(0),n={8:"b",9:"t",10:"n",12:"f",13:"r"}[t];return n?"\\"+n:"\\x"+(t<16?"0":"")+x.call(t.toString(16))}function U(e){return"Object("+e+")"}function q(e){return e+" { ? }"}function X(e,t,n,r){return e+" ("+t+") {"+(r?G(n,r):k.call(n,", "))+"}"}function G(e,t){if(0===e.length)return"";var n="\n"+t.prev+t.base;return n+k.call(e,","+n)+"\n"+t.prev}function K(e,t){var n=N(e),r=[];if(n){r.length=e.length;for(var o=0;o=n.__.length&&n.__.push({}),n.__[e]}function m(e){return u=1,v(T,e)}function v(e,t,n){var i=h(r++,2);return i.t=e,i.__c||(i.__=[n?n(t):T(void 0,t),function(e){var t=i.t(i.__[0],e);i.__[0]!==t&&(i.__=[t,i.__[1]],i.__c.setState({}))}],i.__c=o),i.__}function g(e,t){var n=h(r++,3);!a.YM.__s&&M(n.__H,t)&&(n.__=e,n.__H=t,o.__H.__h.push(n))}function y(e,t){var n=h(r++,4);!a.YM.__s&&M(n.__H,t)&&(n.__=e,n.__H=t,o.__h.push(n))}function b(e){return u=5,Z((function(){return{current:e}}),[])}function x(e,t,n){u=6,y((function(){return"function"==typeof e?(e(t()),function(){return e(null)}):e?(e.current=t(),function(){return e.current=null}):void 0}),null==n?n:n.concat(e))}function Z(e,t){var n=h(r++,7);return M(n.__H,t)&&(n.__=e(),n.__H=t,n.__h=e),n.__}function w(e,t){return u=8,Z((function(){return e}),t)}function D(e){var t=o.context[e.__c],n=h(r++,9);return n.c=e,t?(null==n.__&&(n.__=!0,t.sub(o)),t.props.value):e.__}function k(e,t){a.YM.useDebugValue&&a.YM.useDebugValue(t?t(e):e)}function S(e){var t=h(r++,10),n=m();return t.__=e,o.componentDidCatch||(o.componentDidCatch=function(e){t.__&&t.__(e),n[1](e)}),[n[0],function(){n[1](void 0)}]}function C(){for(var e;e=l.shift();)if(e.__P)try{e.__H.__h.forEach(E),e.__H.__h.forEach(A),e.__H.__h=[]}catch(o){e.__H.__h=[],a.YM.__e(o,e.__v)}}a.YM.__b=function(e){o=null,s&&s(e)},a.YM.__r=function(e){c&&c(e),r=0;var t=(o=e.__c).__H;t&&(t.__h.forEach(E),t.__h.forEach(A),t.__h=[])},a.YM.diffed=function(e){d&&d(e);var t=e.__c;t&&t.__H&&t.__H.__h.length&&(1!==l.push(t)&&i===a.YM.requestAnimationFrame||((i=a.YM.requestAnimationFrame)||function(e){var t,n=function(){clearTimeout(r),_&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);_&&(t=requestAnimationFrame(n))})(C)),o=null},a.YM.__c=function(e,t){t.some((function(e){try{e.__h.forEach(E),e.__h=e.__h.filter((function(e){return!e.__||A(e)}))}catch(i){t.some((function(e){e.__h&&(e.__h=[])})),t=[],a.YM.__e(i,e.__v)}})),f&&f(e,t)},a.YM.unmount=function(e){p&&p(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach((function(e){try{E(e)}catch(e){t=e}})),t&&a.YM.__e(t,n.__v))};var _="function"==typeof requestAnimationFrame;function E(e){var t=o,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),o=t}function A(e){var t=o;e.__c=e.__(),o=t}function M(e,t){return!e||e.length!==t.length||t.some((function(t,n){return t!==e[n]}))}function T(e,t){return"function"==typeof t?t(e):t}function P(e,t){for(var n in t)e[n]=t[n];return e}function R(e,t){for(var n in e)if("__source"!==n&&!(n in t))return!0;for(var r in t)if("__source"!==r&&e[r]!==t[r])return!0;return!1}function F(e){this.props=e}function O(e,t){function n(e){var n=this.props.ref,r=n==e.ref;return!r&&n&&(n.call?n(null):n.current=null),t?!t(this.props,e)||!r:R(this.props,e)}function r(t){return this.shouldComponentUpdate=n,(0,a.az)(e,t)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(F.prototype=new a.wA).isPureReactComponent=!0,F.prototype.shouldComponentUpdate=function(e,t){return R(this.props,e)||R(this.state,t)};var B=a.YM.__b;a.YM.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),B&&B(e)};var I="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function L(e){function t(t){var n=P({},t);return delete n.ref,e(n,t.ref||null)}return t.$$typeof=I,t.render=t,t.prototype.isReactComponent=t.__f=!0,t.displayName="ForwardRef("+(e.displayName||e.name)+")",t}var N=function(e,t){return null==e?null:(0,a.bR)((0,a.bR)(e).map(t))},z={map:N,forEach:N,count:function(e){return e?(0,a.bR)(e).length:0},only:function(e){var t=(0,a.bR)(e);if(1!==t.length)throw"Children.only";return t[0]},toArray:a.bR},j=a.YM.__e;a.YM.__e=function(e,t,n,r){if(e.then)for(var o,i=t;i=i.__;)if((o=i.__c)&&o.__c)return null==t.__e&&(t.__e=n.__e,t.__k=n.__k),o.__c(e,t);j(e,t,n,r)};var W=a.YM.unmount;function $(){this.__u=0,this.t=null,this.__b=null}function H(e){var t=e.__.__c;return t&&t.__e&&t.__e(e)}function Y(e){var t,n,r;function o(o){if(t||(t=e()).then((function(e){n=e.default||e}),(function(e){r=e})),r)throw r;if(!n)throw t;return(0,a.az)(n,o)}return o.displayName="Lazy",o.__f=!0,o}function V(){this.u=null,this.o=null}a.YM.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&!0===e.__h&&(e.type=null),W&&W(e)},($.prototype=new a.wA).__c=function(e,t){var n=t.__c,r=this;null==r.t&&(r.t=[]),r.t.push(n);var o=H(r.__v),i=!1,a=function(){i||(i=!0,n.__R=null,o?o(u):u())};n.__R=a;var u=function(){if(!--r.__u){if(r.state.__e){var e=r.state.__e;r.__v.__k[0]=function e(t,n,r){return t&&(t.__v=null,t.__k=t.__k&&t.__k.map((function(t){return e(t,n,r)})),t.__c&&t.__c.__P===n&&(t.__e&&r.insertBefore(t.__e,t.__d),t.__c.__e=!0,t.__c.__P=r)),t}(e,e.__c.__P,e.__c.__O)}var t;for(r.setState({__e:r.__b=null});t=r.t.pop();)t.forceUpdate()}},l=!0===t.__h;r.__u++||l||r.setState({__e:r.__b=r.__v.__k[0]}),e.then(a,a)},$.prototype.componentWillUnmount=function(){this.t=[]},$.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=function e(t,n,r){return t&&(t.__c&&t.__c.__H&&(t.__c.__H.__.forEach((function(e){"function"==typeof e.__c&&e.__c()})),t.__c.__H=null),null!=(t=P({},t)).__c&&(t.__c.__P===r&&(t.__c.__P=n),t.__c=null),t.__k=t.__k&&t.__k.map((function(t){return e(t,n,r)}))),t}(this.__b,n,r.__O=r.__P)}this.__b=null}var o=t.__e&&(0,a.az)(a.HY,null,e.fallback);return o&&(o.__h=null),[(0,a.az)(a.HY,null,t.__e?null:e.children),o]};var U=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&("t"!==e.props.revealOrder[0]||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]>>1,1),t.i.removeChild(e)}}),(0,a.sY)((0,a.az)(q,{context:t.context},e.__v),t.l)):t.l&&t.componentWillUnmount()}function G(e,t){return(0,a.az)(X,{__v:e,i:t})}(V.prototype=new a.wA).__e=function(e){var t=this,n=H(t.__v),r=t.o.get(e);return r[0]++,function(o){var i=function(){t.props.revealOrder?(r.push(o),U(t,e,r)):o()};n?n(i):i()}},V.prototype.render=function(e){this.u=null,this.o=new Map;var t=(0,a.bR)(e.children);e.revealOrder&&"b"===e.revealOrder[0]&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},V.prototype.componentDidUpdate=V.prototype.componentDidMount=function(){var e=this;this.o.forEach((function(t,n){U(e,n,t)}))};var K="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,Q=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|marker(?!H|W|U)|overline|paint|stop|strikethrough|stroke|text(?!L)|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,J="undefined"!=typeof document,ee=function(e){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/i:/fil|che|ra/i).test(e)};function te(e,t,n){return null==t.__k&&(t.textContent=""),(0,a.sY)(e,t),"function"==typeof n&&n(),e?e.__c:null}function ne(e,t,n){return(0,a.ZB)(e,t),"function"==typeof n&&n(),e?e.__c:null}a.wA.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach((function(e){Object.defineProperty(a.wA.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})}));var re=a.YM.event;function oe(){}function ie(){return this.cancelBubble}function ae(){return this.defaultPrevented}a.YM.event=function(e){return re&&(e=re(e)),e.persist=oe,e.isPropagationStopped=ie,e.isDefaultPrevented=ae,e.nativeEvent=e};var ue,le={configurable:!0,get:function(){return this.class}},se=a.YM.vnode;a.YM.vnode=function(e){var t=e.type,n=e.props,r=n;if("string"==typeof t){var o=-1===t.indexOf("-");for(var i in r={},n){var u=n[i];J&&"children"===i&&"noscript"===t||"value"===i&&"defaultValue"in n&&null==u||("defaultValue"===i&&"value"in n&&null==n.value?i="value":"download"===i&&!0===u?u="":/ondoubleclick/i.test(i)?i="ondblclick":/^onchange(textarea|input)/i.test(i+t)&&!ee(n.type)?i="oninput":/^onfocus$/i.test(i)?i="onfocusin":/^onblur$/i.test(i)?i="onfocusout":/^on(Ani|Tra|Tou|BeforeInp|Compo)/.test(i)?i=i.toLowerCase():o&&Q.test(i)?i=i.replace(/[A-Z0-9]/,"-$&").toLowerCase():null===u&&(u=void 0),r[i]=u)}"select"==t&&r.multiple&&Array.isArray(r.value)&&(r.value=(0,a.bR)(n.children).forEach((function(e){e.props.selected=-1!=r.value.indexOf(e.props.value)}))),"select"==t&&null!=r.defaultValue&&(r.value=(0,a.bR)(n.children).forEach((function(e){e.props.selected=r.multiple?-1!=r.defaultValue.indexOf(e.props.value):r.defaultValue==e.props.value}))),e.props=r,n.class!=n.className&&(le.enumerable="className"in n,null!=n.className&&(r.class=n.className),Object.defineProperty(r,"className",le))}e.$$typeof=K,se&&se(e)};var ce=a.YM.__r;a.YM.__r=function(e){ce&&ce(e),ue=e.__c};var de={ReactCurrentDispatcher:{current:{readContext:function(e){return ue.__n[e.__c].props.value}}}},fe="17.0.2";function pe(e){return a.az.bind(null,e)}function he(e){return!!e&&e.$$typeof===K}function me(e){return he(e)?a.Tm.apply(null,arguments):e}function ve(e){return!!e.__k&&((0,a.sY)(null,e),!0)}function ge(e){return e&&(e.base||1===e.nodeType&&e)||null}var ye=function(e,t){return e(t)},be=function(e,t){return e(t)},xe=a.HY,Ze={useState:m,useReducer:v,useEffect:g,useLayoutEffect:y,useRef:b,useImperativeHandle:x,useMemo:Z,useCallback:w,useContext:D,useDebugValue:k,version:"17.0.2",Children:z,render:te,hydrate:ne,unmountComponentAtNode:ve,createPortal:G,createElement:a.az,createContext:a.kr,createFactory:pe,cloneElement:me,createRef:a.Vf,Fragment:a.HY,isValidElement:he,findDOMNode:ge,Component:a.wA,PureComponent:F,memo:O,forwardRef:L,flushSync:be,unstable_batchedUpdates:ye,StrictMode:a.HY,Suspense:$,SuspenseList:V,lazy:Y,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:de}},7742:function(e,t,n){n(4206),e.exports=n(7226)},3856:function(e,t,n){"use strict";n.d(t,{HY:function(){return y},Tm:function(){return z},Vf:function(){return g},YM:function(){return o},ZB:function(){return N},az:function(){return m},bR:function(){return C},kr:function(){return j},sY:function(){return L},wA:function(){return b}});var r,o,i,a,u,l,s,c={},d=[],f=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i;function p(e,t){for(var n in t)e[n]=t[n];return e}function h(e){var t=e.parentNode;t&&t.removeChild(e)}function m(e,t,n){var o,i,a,u={};for(a in t)"key"==a?o=t[a]:"ref"==a?i=t[a]:u[a]=t[a];if(arguments.length>2&&(u.children=arguments.length>3?r.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(a in e.defaultProps)void 0===u[a]&&(u[a]=e.defaultProps[a]);return v(e,u,o,i,null)}function v(e,t,n,r,a){var u={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==a?++i:a};return null==a&&null!=o.vnode&&o.vnode(u),u}function g(){return{current:null}}function y(e){return e.children}function b(e,t){this.props=e,this.context=t}function x(e,t){if(null==t)return e.__?x(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t0?v(m.type,m.props,m.key,null,m.__v):m)){if(m.__=n,m.__b=n.__b+1,null===(h=w[f])||h&&m.key==h.key&&m.type===h.type)w[f]=void 0;else for(p=0;p2&&(u.children=arguments.length>3?r.call(arguments,2):n),v(e.type,u,o||e.key,i||e.ref,null)}function j(e,t){var n={__c:t="__cC"+s++,__:e,Consumer:function(e,t){return e.children(t)},Provider:function(e){var n,r;return this.getChildContext||(n=[],(r={})[t]=this,this.getChildContext=function(){return r},this.shouldComponentUpdate=function(e){this.props.value!==e.value&&n.some(w)},this.sub=function(e){n.push(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n.splice(n.indexOf(e),1),t&&t.call(e)}}),e.children}};return n.Provider.__=n.Consumer.contextType=n}r=d.slice,o={__e:function(e,t,n,r){for(var o,i,a;t=t.__;)if((o=t.__c)&&!o.__)try{if((i=o.constructor)&&null!=i.getDerivedStateFromError&&(o.setState(i.getDerivedStateFromError(e)),a=o.__d),null!=o.componentDidCatch&&(o.componentDidCatch(e,r||{}),a=o.__d),a)return o.__E=o}catch(t){e=t}throw e}},i=0,b.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=p({},this.state),"function"==typeof e&&(e=e(p({},n),this.props)),e&&p(n,e),null!=e&&this.__v&&(t&&this.__h.push(t),w(this))},b.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),w(this))},b.prototype.render=y,a=[],u="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,D.__r=0,s=0},7226:function(e,t,n){"use strict";n.r(t),n.d(t,{Fragment:function(){return r.HY},jsx:function(){return i},jsxDEV:function(){return i},jsxs:function(){return i}});var r=n(3856),o=0;function i(e,t,n,i,a){var u,l,s={};for(l in t)"ref"==l?u=t[l]:s[l]=t[l];var c={type:e,props:s,key:n,ref:u,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:--o,__source:a,__self:i};if("function"==typeof e&&(u=e.defaultProps))for(l in u)void 0===s[l]&&(s[l]=u[l]);return r.YM.vnode&&r.YM.vnode(c),c}},1729:function(e,t,n){"use strict";var r=n(9165);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},5192:function(e,t,n){e.exports=n(1729)()},9165:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},5609:function(e){"use strict";var t=String.prototype.replace,n=/%20/g,r="RFC1738",o="RFC3986";e.exports={default:o,formatters:{RFC1738:function(e){return t.call(e,n,"+")},RFC3986:function(e){return String(e)}},RFC1738:r,RFC3986:o}},4776:function(e,t,n){"use strict";var r=n(2816),o=n(7668),i=n(5609);e.exports={formats:i,parse:o,stringify:r}},7668:function(e,t,n){"use strict";var r=n(9837),o=Object.prototype.hasOwnProperty,i=Array.isArray,a={allowDots:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:r.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},u=function(e){return e.replace(/(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},l=function(e,t){return e&&"string"===typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},s=function(e,t,n,r){if(e){var i=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,a=/(\[[^[\]]*])/g,u=n.depth>0&&/(\[[^[\]]*])/.exec(i),s=u?i.slice(0,u.index):i,c=[];if(s){if(!n.plainObjects&&o.call(Object.prototype,s)&&!n.allowPrototypes)return;c.push(s)}for(var d=0;n.depth>0&&null!==(u=a.exec(i))&&d=0;--i){var a,u=e[i];if("[]"===u&&n.parseArrays)a=[].concat(o);else{a=n.plainObjects?Object.create(null):{};var s="["===u.charAt(0)&&"]"===u.charAt(u.length-1)?u.slice(1,-1):u,c=parseInt(s,10);n.parseArrays||""!==s?!isNaN(c)&&u!==s&&String(c)===s&&c>=0&&n.parseArrays&&c<=n.arrayLimit?(a=[])[c]=o:"__proto__"!==s&&(a[s]=o):a={0:o}}o=a}return o}(c,t,n,r)}};e.exports=function(e,t){var n=function(e){if(!e)return a;if(null!==e.decoder&&void 0!==e.decoder&&"function"!==typeof e.decoder)throw new TypeError("Decoder has to be a function.");if("undefined"!==typeof e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t="undefined"===typeof e.charset?a.charset:e.charset;return{allowDots:"undefined"===typeof e.allowDots?a.allowDots:!!e.allowDots,allowPrototypes:"boolean"===typeof e.allowPrototypes?e.allowPrototypes:a.allowPrototypes,allowSparse:"boolean"===typeof e.allowSparse?e.allowSparse:a.allowSparse,arrayLimit:"number"===typeof e.arrayLimit?e.arrayLimit:a.arrayLimit,charset:t,charsetSentinel:"boolean"===typeof e.charsetSentinel?e.charsetSentinel:a.charsetSentinel,comma:"boolean"===typeof e.comma?e.comma:a.comma,decoder:"function"===typeof e.decoder?e.decoder:a.decoder,delimiter:"string"===typeof e.delimiter||r.isRegExp(e.delimiter)?e.delimiter:a.delimiter,depth:"number"===typeof e.depth||!1===e.depth?+e.depth:a.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"===typeof e.interpretNumericEntities?e.interpretNumericEntities:a.interpretNumericEntities,parameterLimit:"number"===typeof e.parameterLimit?e.parameterLimit:a.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"===typeof e.plainObjects?e.plainObjects:a.plainObjects,strictNullHandling:"boolean"===typeof e.strictNullHandling?e.strictNullHandling:a.strictNullHandling}}(t);if(""===e||null===e||"undefined"===typeof e)return n.plainObjects?Object.create(null):{};for(var c="string"===typeof e?function(e,t){var n,s={},c=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,d=t.parameterLimit===1/0?void 0:t.parameterLimit,f=c.split(t.delimiter,d),p=-1,h=t.charset;if(t.charsetSentinel)for(n=0;n-1&&(v=i(v)?[v]:v),o.call(s,m)?s[m]=r.combine(s[m],v):s[m]=v}return s}(e,n):e,d=n.plainObjects?Object.create(null):{},f=Object.keys(c),p=0;p0?k.join(",")||null:void 0}];else if(l(f))R=f;else{var O=Object.keys(k);R=p?O.sort(p):O}for(var B=0;B0?x+b:""}},9837:function(e,t,n){"use strict";var r=n(5609),o=Object.prototype.hasOwnProperty,i=Array.isArray,a=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),u=function(e,t){for(var n=t&&t.plainObjects?Object.create(null):{},r=0;r1;){var t=e.pop(),n=t.obj[t.prop];if(i(n)){for(var r=[],o=0;o=48&&c<=57||c>=65&&c<=90||c>=97&&c<=122||i===r.RFC1738&&(40===c||41===c)?l+=u.charAt(s):c<128?l+=a[c]:c<2048?l+=a[192|c>>6]+a[128|63&c]:c<55296||c>=57344?l+=a[224|c>>12]+a[128|c>>6&63]+a[128|63&c]:(s+=1,c=65536+((1023&c)<<10|1023&u.charCodeAt(s)),l+=a[240|c>>18]+a[128|c>>12&63]+a[128|c>>6&63]+a[128|63&c])}return l},isBuffer:function(e){return!(!e||"object"!==typeof e)&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(i(e)){for(var n=[],r=0;r=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=r.call(a,"catchLoc"),s=r.call(a,"finallyLoc");if(l&&s){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),_(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;_(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:A(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),m}},e}(e.exports);try{regeneratorRuntime=t}catch(n){"object"===typeof globalThis?globalThis.regeneratorRuntime=t:Function("r","regeneratorRuntime = r")(t)}},3170:function(e,t,n){"use strict";var r=n(8476),o=n(4680),i=n(3154),a=r("%TypeError%"),u=r("%WeakMap%",!0),l=r("%Map%",!0),s=o("WeakMap.prototype.get",!0),c=o("WeakMap.prototype.set",!0),d=o("WeakMap.prototype.has",!0),f=o("Map.prototype.get",!0),p=o("Map.prototype.set",!0),h=o("Map.prototype.has",!0),m=function(e,t){for(var n,r=e;null!==(n=r.next);r=n)if(n.key===t)return r.next=n.next,n.next=e.next,e.next=n,n};e.exports=function(){var e,t,n,r={assert:function(e){if(!r.has(e))throw new a("Side channel does not contain "+i(e))},get:function(r){if(u&&r&&("object"===typeof r||"function"===typeof r)){if(e)return s(e,r)}else if(l){if(t)return f(t,r)}else if(n)return function(e,t){var n=m(e,t);return n&&n.value}(n,r)},has:function(r){if(u&&r&&("object"===typeof r||"function"===typeof r)){if(e)return d(e,r)}else if(l){if(t)return h(t,r)}else if(n)return function(e,t){return!!m(e,t)}(n,r);return!1},set:function(r,o){u&&r&&("object"===typeof r||"function"===typeof r)?(e||(e=new u),c(e,r,o)):l?(t||(t=new l),p(t,r,o)):(n||(n={key:{},next:null}),function(e,t,n){var r=m(e,t);r?r.value=n:e.next={key:t,next:e.next,value:n}}(n,r,o))}};return r}},4654:function(){},907:function(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||(o[n]=e[n]);return o}n.d(t,{Z:function(){return r}})},9439:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(3878);var o=n(181),i=n(5267);function a(e,t){return(0,r.Z)(e)||function(e,t){var n=null==e?null:"undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i=[],a=!0,u=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(l){u=!0,o=l}finally{try{a||null==n.return||n.return()}finally{if(u)throw o}}return i}}(e,t)||(0,o.Z)(e,t)||(0,i.Z)()}},3433:function(e,t,n){"use strict";n.d(t,{Z:function(){return a}});var r=n(907);var o=n(9199),i=n(181);function a(e){return function(e){if(Array.isArray(e))return(0,r.Z)(e)}(e)||(0,o.Z)(e)||(0,i.Z)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},181:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(907);function o(e,t){if(e){if("string"===typeof e)return(0,r.Z)(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?(0,r.Z)(e,t):void 0}}},3138:function(e,t,n){"use strict";n.d(t,{BX:function(){return r.jsxs},HY:function(){return r.Fragment},tZ:function(){return r.jsx}});n(4206);var r=n(7226)}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r].call(i.exports,i,i.exports,n),i.exports}n.m=e,n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.f={},n.e=function(e){return Promise.all(Object.keys(n.f).reduce((function(t,r){return n.f[r](e,t),t}),[]))},n.u=function(e){return"static/js/"+e+".939f971b.chunk.js"},n.miniCssF=function(e){},n.g=function(){if("object"===typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"===typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){var e={},t="vmui:";n.l=function(r,o,i,a){if(e[r])e[r].push(o);else{var u,l;if(void 0!==i)for(var s=document.getElementsByTagName("script"),c=0;c=0&&(t.hash=e.substr(n),e=e.substr(0,n));var r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}var h=(0,t.createContext)(null);var m=(0,t.createContext)(null);var v=(0,t.createContext)({outlet:null,matches:[]});function g(e,t){if(!e)throw new Error(t)}function y(e,t,n){void 0===n&&(n="/");var r=C(("string"===typeof t?p(t):t).pathname||"/",n);if(null==r)return null;var o=b(e);!function(e){e.sort((function(e,t){return e.score!==t.score?t.score-e.score:function(e,t){var n=e.length===t.length&&e.slice(0,-1).every((function(e,n){return e===t[n]}));return n?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((function(e){return e.childrenIndex})),t.routesMeta.map((function(e){return e.childrenIndex})))}))}(o);for(var i=null,a=0;null==i&&a0&&(!0===e.index&&g(!1),b(e.children,t,u,a)),(null!=e.path||e.index)&&t.push({path:a,score:w(a,e.index),routesMeta:u})})),t}var x=/^:\w+$/,Z=function(e){return"*"===e};function w(e,t){var n=e.split("/"),r=n.length;return n.some(Z)&&(r+=-2),t&&(r+=2),n.filter((function(e){return!Z(e)})).reduce((function(e,t){return e+(x.test(t)?3:""===t?1:10)}),r)}function D(e,t){for(var n=e.routesMeta,r={},o="/",i=[],a=0;a=0?t[a]:"/"}var l=function(e,t){void 0===t&&(t="/");var n="string"===typeof e?p(e):e,r=n.pathname,o=n.search,i=void 0===o?"":o,a=n.hash,u=void 0===a?"":a,l=r?r.startsWith("/")?r:function(e,t){var n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((function(e){".."===e?n.length>1&&n.pop():"."!==e&&n.push(e)})),n.length>1?n.join("/"):"/"}(r,t):t;return{pathname:l,search:A(i),hash:M(u)}}(o,r);return i&&"/"!==i&&i.endsWith("/")&&!l.pathname.endsWith("/")&&(l.pathname+="/"),l}function C(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;var n=e.charAt(t.length);return n&&"/"!==n?null:e.slice(t.length)||"/"}var _=function(e){return e.join("/").replace(/\/\/+/g,"/")},E=function(e){return e.replace(/\/+$/,"").replace(/^\/*/,"/")},A=function(e){return e&&"?"!==e?e.startsWith("?")?e:"?"+e:""},M=function(e){return e&&"#"!==e?e.startsWith("#")?e:"#"+e:""};function T(e){P()||g(!1);var n=(0,t.useContext)(h),r=n.basename,o=n.navigator,i=B(e),a=i.hash,u=i.pathname,l=i.search,s=u;if("/"!==r){var c=function(e){return""===e||""===e.pathname?"/":"string"===typeof e?p(e).pathname:e.pathname}(e),d=null!=c&&c.endsWith("/");s="/"===u?r+(d?"/":""):_([r,u])}return o.createHref({pathname:s,search:l,hash:a})}function P(){return null!=(0,t.useContext)(m)}function R(){return P()||g(!1),(0,t.useContext)(m).location}function F(){P()||g(!1);var e=(0,t.useContext)(h),n=e.basename,r=e.navigator,o=(0,t.useContext)(v).matches,i=R().pathname,a=JSON.stringify(o.map((function(e){return e.pathnameBase}))),u=(0,t.useRef)(!1);(0,t.useEffect)((function(){u.current=!0}));var l=(0,t.useCallback)((function(e,t){if(void 0===t&&(t={}),u.current)if("number"!==typeof e){var o=S(e,JSON.parse(a),i);"/"!==n&&(o.pathname=_([n,o.pathname])),(t.replace?r.replace:r.push)(o,t.state)}else r.go(e)}),[n,r,a,i]);return l}var O=(0,t.createContext)(null);function B(e){var n=(0,t.useContext)(v).matches,r=R().pathname,o=JSON.stringify(n.map((function(e){return e.pathnameBase})));return(0,t.useMemo)((function(){return S(e,JSON.parse(o),r)}),[e,o,r])}function I(e,n){return void 0===n&&(n=[]),null==e?null:e.reduceRight((function(r,o,i){return(0,t.createElement)(v.Provider,{children:void 0!==o.route.element?o.route.element:r,value:{outlet:r,matches:n.concat(e.slice(0,i+1))}})}),null)}function L(e){return function(e){var n=(0,t.useContext)(v).outlet;return n?(0,t.createElement)(O.Provider,{value:e},n):n}(e.context)}function N(e){g(!1)}function z(n){var r=n.basename,o=void 0===r?"/":r,i=n.children,a=void 0===i?null:i,u=n.location,l=n.navigationType,s=void 0===l?e.Pop:l,c=n.navigator,d=n.static,f=void 0!==d&&d;P()&&g(!1);var v=E(o),y=(0,t.useMemo)((function(){return{basename:v,navigator:c,static:f}}),[v,c,f]);"string"===typeof u&&(u=p(u));var b=u,x=b.pathname,Z=void 0===x?"/":x,w=b.search,D=void 0===w?"":w,k=b.hash,S=void 0===k?"":k,_=b.state,A=void 0===_?null:_,M=b.key,T=void 0===M?"default":M,R=(0,t.useMemo)((function(){var e=C(Z,v);return null==e?null:{pathname:e,search:D,hash:S,state:A,key:T}}),[v,Z,D,S,A,T]);return null==R?null:(0,t.createElement)(h.Provider,{value:y},(0,t.createElement)(m.Provider,{children:a,value:{location:R,navigationType:s}}))}function j(e){var n=e.children,r=e.location;return function(e,n){P()||g(!1);var r,o=(0,t.useContext)(v).matches,i=o[o.length-1],a=i?i.params:{},u=(i&&i.pathname,i?i.pathnameBase:"/"),l=(i&&i.route,R());if(n){var s,c="string"===typeof n?p(n):n;"/"===u||(null==(s=c.pathname)?void 0:s.startsWith(u))||g(!1),r=c}else r=l;var d=r.pathname||"/",f=y(e,{pathname:"/"===u?d:d.slice(u.length)||"/"});return I(f&&f.map((function(e){return Object.assign({},e,{params:Object.assign({},a,e.params),pathname:_([u,e.pathname]),pathnameBase:"/"===e.pathnameBase?u:_([u,e.pathnameBase])})})),o)}(W(n),r)}function W(e){var n=[];return t.Children.forEach(e,(function(e){if((0,t.isValidElement)(e))if(e.type!==t.Fragment){e.type!==N&&g(!1);var r={caseSensitive:e.props.caseSensitive,element:e.props.element,index:e.props.index,path:e.props.path};e.props.children&&(r.children=W(e.props.children)),n.push(r)}else n.push.apply(n,W(e.props.children))})),n}function $(){return $=Object.assign||function(e){for(var t=1;t=0||(o[n]=e[n]);return o}var Y=["onClick","reloadDocument","replace","state","target","to"];function V(e){var n=e.basename,o=e.children,i=e.window,a=(0,t.useRef)();null==a.current&&(a.current=l({window:i}));var u=a.current,s=(0,t.useState)({action:u.action,location:u.location}),c=(0,r.Z)(s,2),d=c[0],f=c[1];return(0,t.useLayoutEffect)((function(){return u.listen(f)}),[u]),(0,t.createElement)(z,{basename:n,children:o,location:d.location,navigationType:d.action,navigator:u})}var U=(0,t.forwardRef)((function(e,n){var r=e.onClick,o=e.reloadDocument,i=e.replace,a=void 0!==i&&i,u=e.state,l=e.target,s=e.to,c=H(e,Y),d=T(s),p=function(e,n){var r=void 0===n?{}:n,o=r.target,i=r.replace,a=r.state,u=F(),l=R(),s=B(e);return(0,t.useCallback)((function(t){if(0===t.button&&(!o||"_self"===o)&&!function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(t)){t.preventDefault();var n=!!i||f(l)===f(s);u(e,{replace:n,state:a})}}),[l,u,s,i,a,o,e])}(s,{replace:a,state:u,target:l});return(0,t.createElement)("a",$({},c,{href:d,onClick:function(e){r&&r(e),e.defaultPrevented||o||p(e)},ref:n,target:l}))}));var q=n(4942),X=n(3366),G=n(3061),K=n(317),Q=n(7551),J=n(8564),ee=n(5469),te=n(1615),ne=n(2131),re=n(655);function oe(e){return(0,ne.Z)("MuiPaper",e)}(0,re.Z)("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);var ie=n(3138),ae=["className","component","elevation","square","variant"],ue=function(e){return((e<1?5.11916*Math.pow(e,2):4.5*Math.log(e+1)+2)/100).toFixed(2)},le=(0,J.ZP)("div",{name:"MuiPaper",slot:"Root",overridesResolver:function(e,t){var n=e.ownerState;return[t.root,t[n.variant],!n.square&&t.rounded,"elevation"===n.variant&&t["elevation".concat(n.elevation)]]}})((function(e){var t=e.theme,n=e.ownerState;return(0,o.Z)({backgroundColor:t.palette.background.paper,color:t.palette.text.primary,transition:t.transitions.create("box-shadow")},!n.square&&{borderRadius:t.shape.borderRadius},"outlined"===n.variant&&{border:"1px solid ".concat(t.palette.divider)},"elevation"===n.variant&&(0,o.Z)({boxShadow:t.shadows[n.elevation]},"dark"===t.palette.mode&&{backgroundImage:"linear-gradient(".concat((0,Q.Fq)("#fff",ue(n.elevation)),", ").concat((0,Q.Fq)("#fff",ue(n.elevation)),")")}))})),se=t.forwardRef((function(e,t){var n=(0,ee.Z)({props:e,name:"MuiPaper"}),r=n.className,i=n.component,a=void 0===i?"div":i,u=n.elevation,l=void 0===u?1:u,s=n.square,c=void 0!==s&&s,d=n.variant,f=void 0===d?"elevation":d,p=(0,X.Z)(n,ae),h=(0,o.Z)({},n,{component:a,elevation:l,square:c,variant:f}),m=function(e){var t=e.square,n=e.elevation,r=e.variant,o=e.classes,i={root:["root",r,!t&&"rounded","elevation"===r&&"elevation".concat(n)]};return(0,K.Z)(i,oe,o)}(h);return(0,ie.tZ)(le,(0,o.Z)({as:a,ownerState:h,className:(0,G.Z)(m.root,r),ref:t},p))})),ce=se;function de(e){return(0,ne.Z)("MuiAlert",e)}var fe=(0,re.Z)("MuiAlert",["root","action","icon","message","filled","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]),pe=n(6983),he=n(3236),me=n(9127),ve=n(3433);function ge(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function ye(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function be(e,t){return be=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},be(e,t)}function xe(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,be(e,t)}var Ze=t.default.createContext(null);function we(e,n){var r=Object.create(null);return e&&t.Children.map(e,(function(e){return e})).forEach((function(e){r[e.key]=function(e){return n&&(0,t.isValidElement)(e)?n(e):e}(e)})),r}function De(e,t,n){return null!=n[t]?n[t]:e.props[t]}function ke(e,n,r){var o=we(e.children),i=function(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,o=Object.create(null),i=[];for(var a in e)a in t?i.length&&(o[a]=i,i=[]):i.push(a);var u={};for(var l in t){if(o[l])for(r=0;r0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=t.pulsate,o=void 0!==r&&r,i=t.center,a=void 0===i?u||t.pulsate:i,l=t.fakeElement,s=void 0!==l&&l;if("mousedown"===e.type&&y.current)y.current=!1;else{"touchstart"===e.type&&(y.current=!0);var c,d,f,p=s?null:Z.current,h=p?p.getBoundingClientRect():{width:0,height:0,left:0,top:0};if(a||0===e.clientX&&0===e.clientY||!e.clientX&&!e.touches)c=Math.round(h.width/2),d=Math.round(h.height/2);else{var m=e.touches?e.touches[0]:e,v=m.clientX,g=m.clientY;c=Math.round(v-h.left),d=Math.round(g-h.top)}if(a)(f=Math.sqrt((2*Math.pow(h.width,2)+Math.pow(h.height,2))/3))%2===0&&(f+=1);else{var D=2*Math.max(Math.abs((p?p.clientWidth:0)-c),c)+2,k=2*Math.max(Math.abs((p?p.clientHeight:0)-d),d)+2;f=Math.sqrt(Math.pow(D,2)+Math.pow(k,2))}e.touches?null===x.current&&(x.current=function(){w({pulsate:o,rippleX:c,rippleY:d,rippleSize:f,cb:n})},b.current=setTimeout((function(){x.current&&(x.current(),x.current=null)}),80)):w({pulsate:o,rippleX:c,rippleY:d,rippleSize:f,cb:n})}}),[u,w]),k=t.useCallback((function(){D({},{pulsate:!0})}),[D]),S=t.useCallback((function(e,t){if(clearTimeout(b.current),"touchend"===e.type&&x.current)return x.current(),x.current=null,void(b.current=setTimeout((function(){S(e,t)})));x.current=null,m((function(e){return e.length>0?e.slice(1):e})),g.current=t}),[]);return t.useImperativeHandle(n,(function(){return{pulsate:k,start:D,stop:S}}),[k,D,S]),(0,ie.tZ)(Ge,(0,o.Z)({className:(0,G.Z)(s.root,Ye.root,c),ref:Z},d,{children:(0,ie.tZ)(_e,{component:null,exit:!0,children:h})}))})),Je=Qe;function et(e){return(0,ne.Z)("MuiButtonBase",e)}var tt,nt=(0,re.Z)("MuiButtonBase",["root","disabled","focusVisible"]),rt=["action","centerRipple","children","className","component","disabled","disableRipple","disableTouchRipple","focusRipple","focusVisibleClassName","LinkComponent","onBlur","onClick","onContextMenu","onDragLeave","onFocus","onFocusVisible","onKeyDown","onKeyUp","onMouseDown","onMouseLeave","onMouseUp","onTouchEnd","onTouchMove","onTouchStart","tabIndex","TouchRippleProps","touchRippleRef","type"],ot=(0,J.ZP)("button",{name:"MuiButtonBase",slot:"Root",overridesResolver:function(e,t){return t.root}})((tt={display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"}},(0,q.Z)(tt,"&.".concat(nt.disabled),{pointerEvents:"none",cursor:"default"}),(0,q.Z)(tt,"@media print",{colorAdjust:"exact"}),tt)),it=t.forwardRef((function(e,n){var i=(0,ee.Z)({props:e,name:"MuiButtonBase"}),a=i.action,u=i.centerRipple,l=void 0!==u&&u,s=i.children,c=i.className,d=i.component,f=void 0===d?"button":d,p=i.disabled,h=void 0!==p&&p,m=i.disableRipple,v=void 0!==m&&m,g=i.disableTouchRipple,y=void 0!==g&&g,b=i.focusRipple,x=void 0!==b&&b,Z=i.LinkComponent,w=void 0===Z?"a":Z,D=i.onBlur,k=i.onClick,S=i.onContextMenu,C=i.onDragLeave,_=i.onFocus,E=i.onFocusVisible,A=i.onKeyDown,M=i.onKeyUp,T=i.onMouseDown,P=i.onMouseLeave,R=i.onMouseUp,F=i.onTouchEnd,O=i.onTouchMove,B=i.onTouchStart,I=i.tabIndex,L=void 0===I?0:I,N=i.TouchRippleProps,z=i.touchRippleRef,j=i.type,W=(0,X.Z)(i,rt),$=t.useRef(null),H=t.useRef(null),Y=(0,pe.Z)(H,z),V=(0,me.Z)(),U=V.isFocusVisibleRef,q=V.onFocus,Q=V.onBlur,J=V.ref,te=t.useState(!1),ne=(0,r.Z)(te,2),re=ne[0],oe=ne[1];h&&re&&oe(!1),t.useImperativeHandle(a,(function(){return{focusVisible:function(){oe(!0),$.current.focus()}}}),[]);var ae=t.useState(!1),ue=(0,r.Z)(ae,2),le=ue[0],se=ue[1];t.useEffect((function(){se(!0)}),[]);var ce=le&&!v&&!h;function de(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:y;return(0,he.Z)((function(r){return t&&t(r),!n&&H.current&&H.current[e](r),!0}))}t.useEffect((function(){re&&x&&!v&&le&&H.current.pulsate()}),[v,x,re,le]);var fe=de("start",T),ve=de("stop",S),ge=de("stop",C),ye=de("stop",R),be=de("stop",(function(e){re&&e.preventDefault(),P&&P(e)})),xe=de("start",B),Ze=de("stop",F),we=de("stop",O),De=de("stop",(function(e){Q(e),!1===U.current&&oe(!1),D&&D(e)}),!1),ke=(0,he.Z)((function(e){$.current||($.current=e.currentTarget),q(e),!0===U.current&&(oe(!0),E&&E(e)),_&&_(e)})),Se=function(){var e=$.current;return f&&"button"!==f&&!("A"===e.tagName&&e.href)},Ce=t.useRef(!1),_e=(0,he.Z)((function(e){x&&!Ce.current&&re&&H.current&&" "===e.key&&(Ce.current=!0,H.current.stop(e,(function(){H.current.start(e)}))),e.target===e.currentTarget&&Se()&&" "===e.key&&e.preventDefault(),A&&A(e),e.target===e.currentTarget&&Se()&&"Enter"===e.key&&!h&&(e.preventDefault(),k&&k(e))})),Ee=(0,he.Z)((function(e){x&&" "===e.key&&H.current&&re&&!e.defaultPrevented&&(Ce.current=!1,H.current.stop(e,(function(){H.current.pulsate(e)}))),M&&M(e),k&&e.target===e.currentTarget&&Se()&&" "===e.key&&!e.defaultPrevented&&k(e)})),Ae=f;"button"===Ae&&(W.href||W.to)&&(Ae=w);var Me={};"button"===Ae?(Me.type=void 0===j?"button":j,Me.disabled=h):(W.href||W.to||(Me.role="button"),h&&(Me["aria-disabled"]=h));var Te=(0,pe.Z)(J,$),Pe=(0,pe.Z)(n,Te);var Re=(0,o.Z)({},i,{centerRipple:l,component:f,disabled:h,disableRipple:v,disableTouchRipple:y,focusRipple:x,tabIndex:L,focusVisible:re}),Fe=function(e){var t=e.disabled,n=e.focusVisible,r=e.focusVisibleClassName,o=e.classes,i={root:["root",t&&"disabled",n&&"focusVisible"]},a=(0,K.Z)(i,et,o);return n&&r&&(a.root+=" ".concat(r)),a}(Re);return(0,ie.BX)(ot,(0,o.Z)({as:Ae,className:(0,G.Z)(Fe.root,c),ownerState:Re,onBlur:De,onClick:k,onContextMenu:ve,onFocus:ke,onKeyDown:_e,onKeyUp:Ee,onMouseDown:fe,onMouseLeave:be,onMouseUp:ye,onDragLeave:ge,onTouchEnd:Ze,onTouchMove:we,onTouchStart:xe,ref:Pe,tabIndex:h?-1:L,type:j},Me,W,{children:[s,ce?(0,ie.tZ)(Je,(0,o.Z)({ref:Y,center:l},N)):null]}))})),at=it;function ut(e){return(0,ne.Z)("MuiIconButton",e)}var lt,st=(0,re.Z)("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge"]),ct=["edge","children","className","color","disabled","disableFocusRipple","size"],dt=(0,J.ZP)(at,{name:"MuiIconButton",slot:"Root",overridesResolver:function(e,t){var n=e.ownerState;return[t.root,"default"!==n.color&&t["color".concat((0,te.Z)(n.color))],n.edge&&t["edge".concat((0,te.Z)(n.edge))],t["size".concat((0,te.Z)(n.size))]]}})((function(e){var t=e.theme,n=e.ownerState;return(0,o.Z)({textAlign:"center",flex:"0 0 auto",fontSize:t.typography.pxToRem(24),padding:8,borderRadius:"50%",overflow:"visible",color:t.palette.action.active,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shortest})},!n.disableRipple&&{"&:hover":{backgroundColor:(0,Q.Fq)(t.palette.action.active,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}},"start"===n.edge&&{marginLeft:"small"===n.size?-3:-12},"end"===n.edge&&{marginRight:"small"===n.size?-3:-12})}),(function(e){var t=e.theme,n=e.ownerState;return(0,o.Z)({},"inherit"===n.color&&{color:"inherit"},"inherit"!==n.color&&"default"!==n.color&&(0,o.Z)({color:t.palette[n.color].main},!n.disableRipple&&{"&:hover":{backgroundColor:(0,Q.Fq)(t.palette[n.color].main,t.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}}}),"small"===n.size&&{padding:5,fontSize:t.typography.pxToRem(18)},"large"===n.size&&{padding:12,fontSize:t.typography.pxToRem(28)},(0,q.Z)({},"&.".concat(st.disabled),{backgroundColor:"transparent",color:t.palette.action.disabled}))})),ft=t.forwardRef((function(e,t){var n=(0,ee.Z)({props:e,name:"MuiIconButton"}),r=n.edge,i=void 0!==r&&r,a=n.children,u=n.className,l=n.color,s=void 0===l?"default":l,c=n.disabled,d=void 0!==c&&c,f=n.disableFocusRipple,p=void 0!==f&&f,h=n.size,m=void 0===h?"medium":h,v=(0,X.Z)(n,ct),g=(0,o.Z)({},n,{edge:i,color:s,disabled:d,disableFocusRipple:p,size:m}),y=function(e){var t=e.classes,n=e.disabled,r=e.color,o=e.edge,i=e.size,a={root:["root",n&&"disabled","default"!==r&&"color".concat((0,te.Z)(r)),o&&"edge".concat((0,te.Z)(o)),"size".concat((0,te.Z)(i))]};return(0,K.Z)(a,ut,t)}(g);return(0,ie.tZ)(dt,(0,o.Z)({className:(0,G.Z)(y.root,u),centerRipple:!0,focusRipple:!p,disabled:d,ref:t,ownerState:g},v,{children:a}))})),pt=ft,ht=n(4750),mt=(0,ht.Z)((0,ie.tZ)("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),vt=(0,ht.Z)((0,ie.tZ)("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),gt=(0,ht.Z)((0,ie.tZ)("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),yt=(0,ht.Z)((0,ie.tZ)("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined"),bt=(0,ht.Z)((0,ie.tZ)("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),xt=["action","children","className","closeText","color","icon","iconMapping","onClose","role","severity","variant"],Zt=(0,J.ZP)(ce,{name:"MuiAlert",slot:"Root",overridesResolver:function(e,t){var n=e.ownerState;return[t.root,t[n.variant],t["".concat(n.variant).concat((0,te.Z)(n.color||n.severity))]]}})((function(e){var t=e.theme,n=e.ownerState,r="light"===t.palette.mode?Q._j:Q.$n,i="light"===t.palette.mode?Q.$n:Q._j,a=n.color||n.severity;return(0,o.Z)({},t.typography.body2,{backgroundColor:"transparent",display:"flex",padding:"6px 16px"},a&&"standard"===n.variant&&(0,q.Z)({color:r(t.palette[a].light,.6),backgroundColor:i(t.palette[a].light,.9)},"& .".concat(fe.icon),{color:"dark"===t.palette.mode?t.palette[a].main:t.palette[a].light}),a&&"outlined"===n.variant&&(0,q.Z)({color:r(t.palette[a].light,.6),border:"1px solid ".concat(t.palette[a].light)},"& .".concat(fe.icon),{color:"dark"===t.palette.mode?t.palette[a].main:t.palette[a].light}),a&&"filled"===n.variant&&{color:"#fff",fontWeight:t.typography.fontWeightMedium,backgroundColor:"dark"===t.palette.mode?t.palette[a].dark:t.palette[a].main})})),wt=(0,J.ZP)("div",{name:"MuiAlert",slot:"Icon",overridesResolver:function(e,t){return t.icon}})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),Dt=(0,J.ZP)("div",{name:"MuiAlert",slot:"Message",overridesResolver:function(e,t){return t.message}})({padding:"8px 0"}),kt=(0,J.ZP)("div",{name:"MuiAlert",slot:"Action",overridesResolver:function(e,t){return t.action}})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),St={success:(0,ie.tZ)(mt,{fontSize:"inherit"}),warning:(0,ie.tZ)(vt,{fontSize:"inherit"}),error:(0,ie.tZ)(gt,{fontSize:"inherit"}),info:(0,ie.tZ)(yt,{fontSize:"inherit"})},Ct=t.forwardRef((function(e,t){var n=(0,ee.Z)({props:e,name:"MuiAlert"}),r=n.action,i=n.children,a=n.className,u=n.closeText,l=void 0===u?"Close":u,s=n.color,c=n.icon,d=n.iconMapping,f=void 0===d?St:d,p=n.onClose,h=n.role,m=void 0===h?"alert":h,v=n.severity,g=void 0===v?"success":v,y=n.variant,b=void 0===y?"standard":y,x=(0,X.Z)(n,xt),Z=(0,o.Z)({},n,{color:s,severity:g,variant:b}),w=function(e){var t=e.variant,n=e.color,r=e.severity,o=e.classes,i={root:["root","".concat(t).concat((0,te.Z)(n||r)),"".concat(t)],icon:["icon"],message:["message"],action:["action"]};return(0,K.Z)(i,de,o)}(Z);return(0,ie.BX)(Zt,(0,o.Z)({role:m,elevation:0,ownerState:Z,className:(0,G.Z)(w.root,a),ref:t},x,{children:[!1!==c?(0,ie.tZ)(wt,{ownerState:Z,className:w.icon,children:c||f[g]||St[g]}):null,(0,ie.tZ)(Dt,{ownerState:Z,className:w.message,children:i}),null!=r?(0,ie.tZ)(kt,{className:w.action,children:r}):null,null==r&&p?(0,ie.tZ)(kt,{ownerState:Z,className:w.action,children:(0,ie.tZ)(pt,{size:"small","aria-label":l,title:l,color:"inherit",onClick:p,children:lt||(lt=(0,ie.tZ)(bt,{fontSize:"small"}))})}):null]}))})),_t=Ct,Et=n(7472),At=n(2780),Mt=n(9081);function Tt(e){return e.substring(2).toLowerCase()}var Pt=function(e){var n=e.children,r=e.disableReactTree,o=void 0!==r&&r,i=e.mouseEvent,a=void 0===i?"onClick":i,u=e.onClickAway,l=e.touchEvent,s=void 0===l?"onTouchEnd":l,c=t.useRef(!1),d=t.useRef(null),f=t.useRef(!1),p=t.useRef(!1);t.useEffect((function(){return setTimeout((function(){f.current=!0}),0),function(){f.current=!1}}),[]);var h=(0,Et.Z)(n.ref,d),m=(0,At.Z)((function(e){var t=p.current;p.current=!1;var n=(0,Mt.Z)(d.current);!f.current||!d.current||"clientX"in e&&function(e,t){return t.documentElement.clientWidth-1:!n.documentElement.contains(e.target)||d.current.contains(e.target))||!o&&t||u(e))})),v=function(e){return function(t){p.current=!0;var r=n.props[e];r&&r(t)}},g={ref:h};return!1!==s&&(g[s]=v(s)),t.useEffect((function(){if(!1!==s){var e=Tt(s),t=(0,Mt.Z)(d.current),n=function(){c.current=!0};return t.addEventListener(e,m),t.addEventListener("touchmove",n),function(){t.removeEventListener(e,m),t.removeEventListener("touchmove",n)}}}),[m,s]),!1!==a&&(g[a]=v(a)),t.useEffect((function(){if(!1!==a){var e=Tt(a),t=(0,Mt.Z)(d.current);return t.addEventListener(e,m),function(){t.removeEventListener(e,m)}}}),[m,a]),(0,ie.tZ)(t.Fragment,{children:t.cloneElement(n,g)})},Rt=n(6728),Ft=n(2248);function Ot(){return(0,Rt.Z)(Ft.Z)}var Bt=!1,It="unmounted",Lt="exited",Nt="entering",zt="entered",jt="exiting",Wt=function(e){function n(t,n){var r;r=e.call(this,t,n)||this;var o,i=n&&!n.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(o=Lt,r.appearStatus=Nt):o=zt:o=t.unmountOnExit||t.mountOnEnter?It:Lt,r.state={status:o},r.nextCallback=null,r}xe(n,e),n.getDerivedStateFromProps=function(e,t){return e.in&&t.status===It?{status:Lt}:null};var r=n.prototype;return r.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},r.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==Nt&&n!==zt&&(t=Nt):n!==Nt&&n!==zt||(t=jt)}this.updateStatus(!1,t)},r.componentWillUnmount=function(){this.cancelNextCallback()},r.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!==typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},r.updateStatus=function(e,t){void 0===e&&(e=!1),null!==t?(this.cancelNextCallback(),t===Nt?this.performEnter(e):this.performExit()):this.props.unmountOnExit&&this.state.status===Lt&&this.setState({status:It})},r.performEnter=function(e){var n=this,r=this.props.enter,o=this.context?this.context.isMounting:e,i=this.props.nodeRef?[o]:[t.default.findDOMNode(this),o],a=i[0],u=i[1],l=this.getTimeouts(),s=o?l.appear:l.enter;!e&&!r||Bt?this.safeSetState({status:zt},(function(){n.props.onEntered(a)})):(this.props.onEnter(a,u),this.safeSetState({status:Nt},(function(){n.props.onEntering(a,u),n.onTransitionEnd(s,(function(){n.safeSetState({status:zt},(function(){n.props.onEntered(a,u)}))}))})))},r.performExit=function(){var e=this,n=this.props.exit,r=this.getTimeouts(),o=this.props.nodeRef?void 0:t.default.findDOMNode(this);n&&!Bt?(this.props.onExit(o),this.safeSetState({status:jt},(function(){e.props.onExiting(o),e.onTransitionEnd(r.exit,(function(){e.safeSetState({status:Lt},(function(){e.props.onExited(o)}))}))}))):this.safeSetState({status:Lt},(function(){e.props.onExited(o)}))},r.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},r.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},r.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},r.onTransitionEnd=function(e,n){this.setNextCallback(n);var r=this.props.nodeRef?this.props.nodeRef.current:t.default.findDOMNode(this),o=null==e&&!this.props.addEndListener;if(r&&!o){if(this.props.addEndListener){var i=this.props.nodeRef?[this.nextCallback]:[r,this.nextCallback],a=i[0],u=i[1];this.props.addEndListener(a,u)}null!=e&&setTimeout(this.nextCallback,e)}else setTimeout(this.nextCallback,0)},r.render=function(){var e=this.state.status;if(e===It)return null;var n=this.props,r=n.children,o=(n.in,n.mountOnEnter,n.unmountOnExit,n.appear,n.enter,n.exit,n.timeout,n.addEndListener,n.onEnter,n.onEntering,n.onEntered,n.onExit,n.onExiting,n.onExited,n.nodeRef,(0,X.Z)(n,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return t.default.createElement(Ze.Provider,{value:null},"function"===typeof r?r(e,o):t.default.cloneElement(t.default.Children.only(r),o))},n}(t.default.Component);function $t(){}Wt.contextType=Ze,Wt.propTypes={},Wt.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:$t,onEntering:$t,onEntered:$t,onExit:$t,onExiting:$t,onExited:$t},Wt.UNMOUNTED=It,Wt.EXITED=Lt,Wt.ENTERING=Nt,Wt.ENTERED=zt,Wt.EXITING=jt;var Ht=Wt,Yt=function(e){return e.scrollTop};function Vt(e,t){var n,r,o=e.timeout,i=e.easing,a=e.style,u=void 0===a?{}:a;return{duration:null!=(n=u.transitionDuration)?n:"number"===typeof o?o:o[t.mode]||0,easing:null!=(r=u.transitionTimingFunction)?r:"object"===typeof i?i[t.mode]:i,delay:u.transitionDelay}}var Ut=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function qt(e){return"scale(".concat(e,", ").concat(Math.pow(e,2),")")}var Xt={entering:{opacity:1,transform:qt(1)},entered:{opacity:1,transform:"none"}},Gt="undefined"!==typeof navigator&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)[4-9]/i.test(navigator.userAgent),Kt=t.forwardRef((function(e,n){var r=e.addEndListener,i=e.appear,a=void 0===i||i,u=e.children,l=e.easing,s=e.in,c=e.onEnter,d=e.onEntered,f=e.onEntering,p=e.onExit,h=e.onExited,m=e.onExiting,v=e.style,g=e.timeout,y=void 0===g?"auto":g,b=e.TransitionComponent,x=void 0===b?Ht:b,Z=(0,X.Z)(e,Ut),w=t.useRef(),D=t.useRef(),k=Ot(),S=t.useRef(null),C=(0,pe.Z)(u.ref,n),_=(0,pe.Z)(S,C),E=function(e){return function(t){if(e){var n=S.current;void 0===t?e(n):e(n,t)}}},A=E(f),M=E((function(e,t){Yt(e);var n,r=Vt({style:v,timeout:y,easing:l},{mode:"enter"}),o=r.duration,i=r.delay,a=r.easing;"auto"===y?(n=k.transitions.getAutoHeightDuration(e.clientHeight),D.current=n):n=o,e.style.transition=[k.transitions.create("opacity",{duration:n,delay:i}),k.transitions.create("transform",{duration:Gt?n:.666*n,delay:i,easing:a})].join(","),c&&c(e,t)})),T=E(d),P=E(m),R=E((function(e){var t,n=Vt({style:v,timeout:y,easing:l},{mode:"exit"}),r=n.duration,o=n.delay,i=n.easing;"auto"===y?(t=k.transitions.getAutoHeightDuration(e.clientHeight),D.current=t):t=r,e.style.transition=[k.transitions.create("opacity",{duration:t,delay:o}),k.transitions.create("transform",{duration:Gt?t:.666*t,delay:Gt?o:o||.333*t,easing:i})].join(","),e.style.opacity=0,e.style.transform=qt(.75),p&&p(e)})),F=E(h);return t.useEffect((function(){return function(){clearTimeout(w.current)}}),[]),(0,ie.tZ)(x,(0,o.Z)({appear:a,in:s,nodeRef:S,onEnter:M,onEntered:T,onEntering:A,onExit:R,onExited:F,onExiting:P,addEndListener:function(e){"auto"===y&&(w.current=setTimeout(e,D.current||0)),r&&r(S.current,e)},timeout:"auto"===y?null:y},Z,{children:function(e,n){return t.cloneElement(u,(0,o.Z)({style:(0,o.Z)({opacity:0,transform:qt(.75),visibility:"exited"!==e||s?void 0:"hidden"},Xt[e],v,u.props.style),ref:_},n))}}))}));Kt.muiSupportAuto=!0;var Qt=Kt;function Jt(e){return(0,ne.Z)("MuiSnackbarContent",e)}(0,re.Z)("MuiSnackbarContent",["root","message","action"]);var en=["action","className","message","role"],tn=(0,J.ZP)(ce,{name:"MuiSnackbarContent",slot:"Root",overridesResolver:function(e,t){return t.root}})((function(e){var t=e.theme,n="light"===t.palette.mode?.8:.98,r=(0,Q._4)(t.palette.background.default,n);return(0,o.Z)({},t.typography.body2,(0,q.Z)({color:t.palette.getContrastText(r),backgroundColor:r,display:"flex",alignItems:"center",flexWrap:"wrap",padding:"6px 16px",borderRadius:t.shape.borderRadius,flexGrow:1},t.breakpoints.up("sm"),{flexGrow:"initial",minWidth:288}))})),nn=(0,J.ZP)("div",{name:"MuiSnackbarContent",slot:"Message",overridesResolver:function(e,t){return t.message}})({padding:"8px 0"}),rn=(0,J.ZP)("div",{name:"MuiSnackbarContent",slot:"Action",overridesResolver:function(e,t){return t.action}})({display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:16,marginRight:-8}),on=t.forwardRef((function(e,t){var n=(0,ee.Z)({props:e,name:"MuiSnackbarContent"}),r=n.action,i=n.className,a=n.message,u=n.role,l=void 0===u?"alert":u,s=(0,X.Z)(n,en),c=n,d=function(e){var t=e.classes;return(0,K.Z)({root:["root"],action:["action"],message:["message"]},Jt,t)}(c);return(0,ie.BX)(tn,(0,o.Z)({role:l,square:!0,elevation:6,className:(0,G.Z)(d.root,i),ownerState:c,ref:t},s,{children:[(0,ie.tZ)(nn,{className:d.message,ownerState:c,children:a}),r?(0,ie.tZ)(rn,{className:d.action,ownerState:c,children:r}):null]}))})),an=on;function un(e){return(0,ne.Z)("MuiSnackbar",e)}(0,re.Z)("MuiSnackbar",["root","anchorOriginTopCenter","anchorOriginBottomCenter","anchorOriginTopRight","anchorOriginBottomRight","anchorOriginTopLeft","anchorOriginBottomLeft"]);var ln=["onEnter","onExited"],sn=["action","anchorOrigin","autoHideDuration","children","className","ClickAwayListenerProps","ContentProps","disableWindowBlurListener","message","onBlur","onClose","onFocus","onMouseEnter","onMouseLeave","open","resumeHideDuration","TransitionComponent","transitionDuration","TransitionProps"],cn=(0,J.ZP)("div",{name:"MuiSnackbar",slot:"Root",overridesResolver:function(e,t){var n=e.ownerState;return[t.root,t["anchorOrigin".concat((0,te.Z)(n.anchorOrigin.vertical)).concat((0,te.Z)(n.anchorOrigin.horizontal))]]}})((function(e){var t=e.theme,n=e.ownerState,r=(0,o.Z)({},!n.isRtl&&{left:"50%",right:"auto",transform:"translateX(-50%)"},n.isRtl&&{right:"50%",left:"auto",transform:"translateX(50%)"});return(0,o.Z)({zIndex:t.zIndex.snackbar,position:"fixed",display:"flex",left:8,right:8,justifyContent:"center",alignItems:"center"},"top"===n.anchorOrigin.vertical?{top:8}:{bottom:8},"left"===n.anchorOrigin.horizontal&&{justifyContent:"flex-start"},"right"===n.anchorOrigin.horizontal&&{justifyContent:"flex-end"},(0,q.Z)({},t.breakpoints.up("sm"),(0,o.Z)({},"top"===n.anchorOrigin.vertical?{top:24}:{bottom:24},"center"===n.anchorOrigin.horizontal&&r,"left"===n.anchorOrigin.horizontal&&(0,o.Z)({},!n.isRtl&&{left:24,right:"auto"},n.isRtl&&{right:24,left:"auto"}),"right"===n.anchorOrigin.horizontal&&(0,o.Z)({},!n.isRtl&&{right:24,left:"auto"},n.isRtl&&{left:24,right:"auto"}))))})),dn=t.forwardRef((function(e,n){var i=(0,ee.Z)({props:e,name:"MuiSnackbar"}),a=Ot(),u={enter:a.transitions.duration.enteringScreen,exit:a.transitions.duration.leavingScreen},l=i.action,s=i.anchorOrigin,c=(s=void 0===s?{vertical:"bottom",horizontal:"left"}:s).vertical,d=s.horizontal,f=i.autoHideDuration,p=void 0===f?null:f,h=i.children,m=i.className,v=i.ClickAwayListenerProps,g=i.ContentProps,y=i.disableWindowBlurListener,b=void 0!==y&&y,x=i.message,Z=i.onBlur,w=i.onClose,D=i.onFocus,k=i.onMouseEnter,S=i.onMouseLeave,C=i.open,_=i.resumeHideDuration,E=i.TransitionComponent,A=void 0===E?Qt:E,M=i.transitionDuration,T=void 0===M?u:M,P=i.TransitionProps,R=(P=void 0===P?{}:P).onEnter,F=P.onExited,O=(0,X.Z)(i.TransitionProps,ln),B=(0,X.Z)(i,sn),I="rtl"===a.direction,L=(0,o.Z)({},i,{anchorOrigin:{vertical:c,horizontal:d},isRtl:I}),N=function(e){var t=e.classes,n=e.anchorOrigin,r={root:["root","anchorOrigin".concat((0,te.Z)(n.vertical)).concat((0,te.Z)(n.horizontal))]};return(0,K.Z)(r,un,t)}(L),z=t.useRef(),j=t.useState(!0),W=(0,r.Z)(j,2),$=W[0],H=W[1],Y=(0,he.Z)((function(){w&&w.apply(void 0,arguments)})),V=(0,he.Z)((function(e){w&&null!=e&&(clearTimeout(z.current),z.current=setTimeout((function(){Y(null,"timeout")}),e))}));t.useEffect((function(){return C&&V(p),function(){clearTimeout(z.current)}}),[C,p,V]);var U=function(){clearTimeout(z.current)},q=t.useCallback((function(){null!=p&&V(null!=_?_:.5*p)}),[p,_,V]);return t.useEffect((function(){if(!b&&C)return window.addEventListener("focus",q),window.addEventListener("blur",U),function(){window.removeEventListener("focus",q),window.removeEventListener("blur",U)}}),[b,q,C]),t.useEffect((function(){if(C)return document.addEventListener("keydown",e),function(){document.removeEventListener("keydown",e)};function e(e){e.defaultPrevented||"Escape"!==e.key&&"Esc"!==e.key||w&&w(e,"escapeKeyDown")}}),[$,C,w]),!C&&$?null:(0,ie.tZ)(Pt,(0,o.Z)({onClickAway:function(e){w&&w(e,"clickaway")}},v,{children:(0,ie.tZ)(cn,(0,o.Z)({className:(0,G.Z)(N.root,m),onBlur:function(e){Z&&Z(e),q()},onFocus:function(e){D&&D(e),U()},onMouseEnter:function(e){k&&k(e),U()},onMouseLeave:function(e){S&&S(e),q()},ownerState:L,ref:n,role:"presentation"},B,{children:(0,ie.tZ)(A,(0,o.Z)({appear:!0,in:C,timeout:T,direction:"top"===c?"down":"up",onEnter:function(e,t){H(!1),R&&R(e,t)},onExited:function(e){H(!0),F&&F(e)}},O,{children:h||(0,ie.tZ)(an,(0,o.Z)({message:x,action:l},g))}))}))}))})),fn=dn,pn=(0,t.createContext)({showInfoMessage:function(){}}),hn=function(e){var n=e.children,o=(0,t.useState)({}),i=(0,r.Z)(o,2),a=i[0],u=i[1],l=(0,t.useState)(!1),s=(0,r.Z)(l,2),c=s[0],d=s[1],f=(0,t.useState)(void 0),p=(0,r.Z)(f,2),h=p[0],m=p[1];(0,t.useEffect)((function(){h&&(u({message:h,key:(new Date).getTime()}),d(!0))}),[h]);return(0,ie.BX)(pn.Provider,{value:{showInfoMessage:m},children:[(0,ie.tZ)(fn,{open:c,autoHideDuration:4e3,onClose:function(e,t){"clickaway"!==t&&(m(void 0),d(!1))},children:(0,ie.tZ)(_t,{children:a.message})},a.key),n]})};function mn(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function vn(e){for(var t=1;t2&&void 0!==arguments[2]?arguments[2]:window.location.search,r=kn().parse(n,{ignoreQueryPrefix:!0});return Cn()(r,e,t||"")};yn().extend(xn()),yn().extend(wn());var Mn,Tn=window.innerWidth/4,Pn=1,Rn=1578e8,Fn="YYYY-MM-DD[T]HH:mm:ss",On=[{long:"days",short:"d",possible:"day"},{long:"weeks",short:"w",possible:"week"},{long:"months",short:"M",possible:"mon"},{long:"years",short:"y",possible:"year"},{long:"hours",short:"h",possible:"hour"},{long:"minutes",short:"m",possible:"min"},{long:"seconds",short:"s",possible:"sec"},{long:"milliseconds",short:"ms",possible:"millisecond"}].map((function(e){return e.short})),Bn=function(e){return Math.round(1e3*e)/1e3},In=function(e){var t=e.match(/\d+/g),n=e.match(/[a-zA-Z]+/g);if(n&&t&&On.includes(n[0]))return(0,q.Z)({},n[0],t[0])},Ln=function(e,t){var n=(t||new Date).valueOf()/1e3,r=e.trim().split(" ").reduce((function(e,t){var n=In(t);return n?vn(vn({},e),n):vn({},e)}),{}),o=yn().duration(r).asSeconds();return{start:n-o,end:n,step:Bn(o/Tn)||.001,date:Nn(t||new Date)}},Nn=function(e){return yn()(e).utc().format(Fn)},zn=function(e){return yn()(e).format(Fn)},jn=function(e){var t=Math.floor(e%1e3),n=Math.floor(e/1e3%60),r=Math.floor(e/1e3/60%60),o=Math.floor(e/1e3/3600%24),i=Math.floor(e/864e5),a=["d","h","m","s","ms"];return[i,o,r,n,t].map((function(e,t){return e?"".concat(e).concat(a[t]):""})).filter((function(e){return e})).join(" ")},Wn=function(e){return new Date(1e3*e)},$n=[{title:"Last 5 minutes",duration:"5m"},{title:"Last 15 minutes",duration:"15m"},{title:"Last 30 minutes",duration:"30m"},{title:"Last 1 hour",duration:"1h"},{title:"Last 3 hours",duration:"3h"},{title:"Last 6 hours",duration:"6h"},{title:"Last 12 hours",duration:"12h"},{title:"Last 24 hours",duration:"24h"},{title:"Last 2 days",duration:"2d"},{title:"Last 7 days",duration:"7d"},{title:"Last 30 days",duration:"30d"},{title:"Last 90 days",duration:"90d"},{title:"Last 180 days",duration:"180d"},{title:"Last 1 year",duration:"1y"},{title:"Yesterday",duration:"1d",until:function(){return yn()().subtract(1,"day").endOf("day").toDate()}},{title:"Today",duration:"1d",until:function(){return yn()().endOf("day").toDate()}}].map((function(e){return vn({id:e.title.replace(/\s/g,"_").toLocaleLowerCase(),until:e.until?e.until:function(){return yn()().toDate()}},e)})),Hn=function(e){var t=e.relativeTimeId,n=e.defaultDuration,r=e.defaultEndInput,o=t||An("g0.relative_time",""),i=$n.find((function(e){return e.id===o}));return{relativeTimeId:o,duration:i?i.duration:n,endInput:i?i.until():r}},Yn=function(e,t){t?window.localStorage.setItem(e,JSON.stringify({value:t})):Un([e])},Vn=function(e){var t=window.localStorage.getItem(e);if(null!==t)try{var n;return null===(n=JSON.parse(t))||void 0===n?void 0:n.value}catch(r){return t}},Un=function(e){return e.forEach((function(e){return window.localStorage.removeItem(e)}))},qn=["BASIC_AUTH_DATA","BEARER_AUTH_DATA"],Xn=Hn({defaultDuration:An("g0.range_input","1h"),defaultEndInput:new Date((Mn=An("g0.end_input",new Date(yn()().utc().format(Fn))),yn()(Mn).utcOffset(0,!0).local().format(Fn)))}),Gn=Xn.duration,Kn=Xn.endInput,Qn=Xn.relativeTimeId,Jn=function(){var e,t=(null===(e=window.location.search.match(/g\d+.expr/gim))||void 0===e?void 0:e.length)||1;return new Array(t).fill(1).map((function(e,t){return An("g".concat(t,".expr"),"")}))}(),er={serverUrl:window.location.href.replace(/\/(?:prometheus\/)?(?:graph|vmui)\/.*/,"/prometheus"),displayType:An("g0.tab","chart")||"chart",query:Jn,queryHistory:Jn.map((function(e){return{index:0,values:[e]}})),time:{duration:Gn,period:Ln(Gn,Kn),relativeTime:Qn},queryControls:{autoRefresh:!1,autocomplete:Vn("AUTOCOMPLETE")||!1,nocache:Vn("NO_CACHE")||!1}};function tr(e,t){switch(t.type){case"SET_DISPLAY_TYPE":return vn(vn({},e),{},{displayType:t.payload});case"SET_SERVER":return vn(vn({},e),{},{serverUrl:t.payload});case"SET_QUERY":return vn(vn({},e),{},{query:t.payload.map((function(e){return e}))});case"SET_QUERY_HISTORY":return vn(vn({},e),{},{queryHistory:t.payload});case"SET_QUERY_HISTORY_BY_INDEX":return e.queryHistory.splice(t.payload.queryNumber,1,t.payload.value),vn(vn({},e),{},{queryHistory:e.queryHistory});case"SET_DURATION":return vn(vn({},e),{},{time:vn(vn({},e.time),{},{duration:t.payload,period:Ln(t.payload,Wn(e.time.period.end)),relativeTime:""})});case"SET_RELATIVE_TIME":return vn(vn({},e),{},{time:vn(vn({},e.time),{},{period:Ln(t.payload.duration,new Date(t.payload.until)),relativeTime:t.payload.id})});case"SET_UNTIL":return vn(vn({},e),{},{time:vn(vn({},e.time),{},{period:Ln(e.time.duration,t.payload),relativeTime:""})});case"SET_FROM":var n=jn(1e3*e.time.period.end-t.payload.valueOf());return vn(vn({},e),{},{queryControls:vn(vn({},e.queryControls),{},{autoRefresh:!1}),time:vn(vn({},e.time),{},{duration:n,period:Ln(n,yn()(1e3*e.time.period.end).toDate()),relativeTime:""})});case"SET_PERIOD":var r=function(e){var t=e.to.valueOf()-e.from.valueOf();return jn(t)}(t.payload);return vn(vn({},e),{},{queryControls:vn(vn({},e.queryControls),{},{autoRefresh:!1}),time:vn(vn({},e.time),{},{duration:r,period:Ln(r,t.payload.to),relativeTime:""})});case"TOGGLE_AUTOREFRESH":return vn(vn({},e),{},{queryControls:vn(vn({},e.queryControls),{},{autoRefresh:!e.queryControls.autoRefresh})});case"TOGGLE_AUTOCOMPLETE":return vn(vn({},e),{},{queryControls:vn(vn({},e.queryControls),{},{autocomplete:!e.queryControls.autocomplete})});case"NO_CACHE":return vn(vn({},e),{},{queryControls:vn(vn({},e.queryControls),{},{nocache:!e.queryControls.nocache})});case"RUN_QUERY":var o=Hn({relativeTimeId:e.time.relativeTime,defaultDuration:e.time.duration,defaultEndInput:Wn(e.time.period.end)}),i=o.duration,a=o.endInput;return vn(vn({},e),{},{time:vn(vn({},e.time),{},{period:Ln(i,a)})});case"RUN_QUERY_TO_NOW":return vn(vn({},e),{},{time:vn(vn({},e.time),{},{period:Ln(e.time.duration)})});default:throw new Error}}var nr=(0,t.createContext)({}),rr=function(){return(0,t.useContext)(nr).state},or=function(){return(0,t.useContext)(nr).dispatch},ir=Object.entries(er).reduce((function(e,t){var n=(0,r.Z)(t,2),o=n[0],i=n[1];return vn(vn({},e),{},(0,q.Z)({},o,An(o)||i))}),{}),ar=function(e){var n=e.children,o=(0,t.useReducer)(tr,ir),i=(0,r.Z)(o,2),a=i[0],u=i[1];(0,t.useEffect)((function(){!function(e){var t=new Map(Object.entries(_n)),n=Cn()(e,"query",""),r=[];n.forEach((function(n,o){t.forEach((function(t,n){var i=Cn()(e,n,"");if(i){var a=encodeURIComponent(i);r.push("g".concat(o,".").concat(t,"=").concat(a))}})),r.push("g".concat(o,".expr=").concat(encodeURIComponent(n)))})),En(r.join("&"))}(a)}),[a]);var l=(0,t.useMemo)((function(){return{state:a,dispatch:u}}),[a,u]);return(0,ie.tZ)(nr.Provider,{value:l,children:n})},ur={authMethod:"NO_AUTH",saveAuthLocally:!1},lr=Vn("AUTH_TYPE"),sr=Vn("BASIC_AUTH_DATA"),cr=Vn("BEARER_AUTH_DATA"),dr=vn(vn({},ur),{},{authMethod:lr||ur.authMethod,basicData:sr,bearerData:cr,saveAuthLocally:!(!sr&&!cr)}),fr=function(){Un(qn)};function pr(e,t){switch(t.type){case"SET_BASIC_AUTH":return t.payload.checkbox?Yn("BASIC_AUTH_DATA",t.payload.value):fr(),Yn("AUTH_TYPE","BASIC_AUTH"),vn(vn({},e),{},{authMethod:"BASIC_AUTH",basicData:t.payload.value});case"SET_BEARER_AUTH":return t.payload.checkbox?Yn("BEARER_AUTH_DATA",t.payload.value):fr(),Yn("AUTH_TYPE","BEARER_AUTH"),vn(vn({},e),{},{authMethod:"BEARER_AUTH",bearerData:t.payload.value});case"SET_NO_AUTH":return!t.payload.checkbox&&fr(),Yn("AUTH_TYPE","NO_AUTH"),vn(vn({},e),{},{authMethod:"NO_AUTH"});default:throw new Error}}var hr=(0,t.createContext)({}),mr=function(e){var n=e.children,o=(0,t.useReducer)(pr,dr),i=(0,r.Z)(o,2),a=i[0],u=i[1],l=(0,t.useMemo)((function(){return{state:a,dispatch:u}}),[a,u]);return(0,ie.tZ)(hr.Provider,{value:l,children:n})},vr={customStep:{enable:!1,value:1},yaxis:{limits:{enable:!1,range:{1:[0,0]}}}};function gr(e,t){switch(t.type){case"TOGGLE_ENABLE_YAXIS_LIMITS":return vn(vn({},e),{},{yaxis:vn(vn({},e.yaxis),{},{limits:vn(vn({},e.yaxis.limits),{},{enable:!e.yaxis.limits.enable})})});case"TOGGLE_CUSTOM_STEP":return vn(vn({},e),{},{customStep:vn(vn({},e.customStep),{},{enable:!e.customStep.enable})});case"SET_CUSTOM_STEP":return vn(vn({},e),{},{customStep:vn(vn({},e.customStep),{},{value:t.payload})});case"SET_YAXIS_LIMITS":return vn(vn({},e),{},{yaxis:vn(vn({},e.yaxis),{},{limits:vn(vn({},e.yaxis.limits),{},{range:t.payload})})});default:throw new Error}}var yr=(0,t.createContext)({}),br=function(){return(0,t.useContext)(yr).state},xr=function(){return(0,t.useContext)(yr).dispatch},Zr=function(e){var n=e.children,o=(0,t.useReducer)(gr,vr),i=(0,r.Z)(o,2),a=i[0],u=i[1],l=(0,t.useMemo)((function(){return{state:a,dispatch:u}}),[a,u]);return(0,ie.tZ)(yr.Provider,{value:l,children:n})},wr=n(7458),Dr=(0,wr.Z)({palette:{primary:{main:"#3F51B5"},secondary:{main:"#F50057"},error:{main:"#FF4141"}},components:{MuiFormHelperText:{styleOverrides:{root:{position:"absolute",top:"36px",left:"2px",margin:0}}},MuiInputLabel:{styleOverrides:{root:{fontSize:"12px",letterSpacing:"normal",lineHeight:"1",zIndex:0}}},MuiInputBase:{styleOverrides:{root:{"&.Mui-focused fieldset":{borderWidth:"1px !important"}}}},MuiSwitch:{defaultProps:{color:"secondary"}},MuiAccordion:{styleOverrides:{root:{boxShadow:"rgba(0, 0, 0, 0.16) 0px 1px 4px"}}},MuiPaper:{styleOverrides:{root:{boxShadow:"rgba(0, 0, 0, 0.2) 0px 3px 8px"}}},MuiButton:{styleOverrides:{contained:{boxShadow:"rgba(17, 17, 26, 0.1) 0px 0px 16px","&:hover":{boxShadow:"rgba(0, 0, 0, 0.1) 0px 4px 12px"}}}},MuiIconButton:{defaultProps:{size:"large"},styleOverrides:{sizeLarge:{borderRadius:"20%",height:"40px",width:"41px"},sizeMedium:{borderRadius:"20%"},sizeSmall:{borderRadius:"20%"}}},MuiTooltip:{styleOverrides:{tooltip:{fontSize:"10px"}}},MuiAlert:{styleOverrides:{root:{fontSize:"14px",boxShadow:"rgba(0, 0, 0, 0.08) 0px 4px 12px"}}}},typography:{fontSize:10}}),kr=(0,Ee.Z)({key:"css",prepend:!0});function Sr(e){var t=e.injectFirst,n=e.children;return t?(0,ie.tZ)(Ae.C,{value:kr,children:n}):n}var Cr=n(5693),_r=n(201),Er="function"===typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";var Ar=function(e){var n=e.children,r=e.theme,i=(0,_r.Z)(),a=t.useMemo((function(){var e=null===i?r:function(e,t){return"function"===typeof t?t(e):(0,o.Z)({},e,t)}(i,r);return null!=e&&(e[Er]=null!==i),e}),[r,i]);return(0,ie.tZ)(Cr.Z.Provider,{value:a,children:n})};function Mr(e){var t=(0,Rt.Z)();return(0,ie.tZ)(Ae.T.Provider,{value:"object"===typeof t?t:{},children:e.children})}var Tr=function(e){var t=e.children,n=e.theme;return(0,ie.tZ)(Ar,{theme:n,children:(0,ie.tZ)(Mr,{children:t})})};function Pr(e){var t=e.styles,n=e.defaultTheme,r=void 0===n?{}:n,o="function"===typeof t?function(e){return t(void 0===(n=e)||null===n||0===Object.keys(n).length?r:e);var n}:t;return(0,ie.tZ)(Re,{styles:o})}var Rr=function(e){return(0,ie.tZ)(Pr,(0,o.Z)({},e,{defaultTheme:Ft.Z}))},Fr=function(e,t){return(0,o.Z)({WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale",boxSizing:"border-box",WebkitTextSizeAdjust:"100%"},t&&{colorScheme:e.palette.mode})},Or=function(e){return(0,o.Z)({color:e.palette.text.primary},e.typography.body1,{backgroundColor:e.palette.background.default,"@media print":{backgroundColor:e.palette.common.white}})};var Br=function(e){var n=(0,ee.Z)({props:e,name:"MuiCssBaseline"}),r=n.children,i=n.enableColorScheme,a=void 0!==i&&i;return(0,ie.BX)(t.Fragment,{children:[(0,ie.tZ)(Rr,{styles:function(e){return function(e){var t,n,r={html:Fr(e,arguments.length>1&&void 0!==arguments[1]&&arguments[1]),"*, *::before, *::after":{boxSizing:"inherit"},"strong, b":{fontWeight:e.typography.fontWeightBold},body:(0,o.Z)({margin:0},Or(e),{"&::backdrop":{backgroundColor:e.palette.background.default}})},i=null==(t=e.components)||null==(n=t.MuiCssBaseline)?void 0:n.styleOverrides;return i&&(r=[r,i]),r}(e,a)}}),r]})},Ir=t.createContext(null);function Lr(e){var n=e.children,r=e.dateAdapter,o=e.dateFormats,i=e.dateLibInstance,a=e.locale,u=t.useMemo((function(){return new r({locale:a,formats:o,instance:i})}),[r,a,o,i]),l=t.useMemo((function(){return{minDate:u.date("1900-01-01T00:00:00.000"),maxDate:u.date("2099-12-31T00:00:00.000")}}),[u]),s=t.useMemo((function(){return{utils:u,defaultDates:l}}),[l,u]);return(0,ie.tZ)(Ir.Provider,{value:s,children:n})}var Nr=n(7798),zr=n.n(Nr),jr=n(3825),Wr=n.n(jr),$r=n(8743),Hr=n.n($r);yn().extend(zr()),yn().extend(Wr()),yn().extend(Hr());var Yr={normalDateWithWeekday:"ddd, MMM D",normalDate:"D MMMM",shortDate:"MMM D",monthAndDate:"MMMM D",dayOfMonth:"D",year:"YYYY",month:"MMMM",monthShort:"MMM",monthAndYear:"MMMM YYYY",weekday:"dddd",weekdayShort:"ddd",minutes:"mm",hours12h:"hh",hours24h:"HH",seconds:"ss",fullTime:"LT",fullTime12h:"hh:mm A",fullTime24h:"HH:mm",fullDate:"ll",fullDateWithWeekday:"dddd, LL",fullDateTime:"lll",fullDateTime12h:"ll hh:mm A",fullDateTime24h:"ll HH:mm",keyboardDate:"L",keyboardDateTime:"L LT",keyboardDateTime12h:"L hh:mm A",keyboardDateTime24h:"L HH:mm"},Vr=function(e){var t=this,n=void 0===e?{}:e,r=n.locale,o=n.formats,i=n.instance;this.lib="dayjs",this.is12HourCycleInCurrentLocale=function(){var e,n;return/A|a/.test(null===(n=null===(e=t.rawDayJsInstance.Ls[t.locale||"en"])||void 0===e?void 0:e.formats)||void 0===n?void 0:n.LT)},this.getCurrentLocaleCode=function(){return t.locale||"en"},this.getFormatHelperText=function(e){return e.match(/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?)|./g).map((function(e){var n,r;return"L"===e[0]&&null!==(r=null===(n=t.rawDayJsInstance.Ls[t.locale||"en"])||void 0===n?void 0:n.formats[e])&&void 0!==r?r:e})).join("").replace(/a/gi,"(a|p)m").toLocaleLowerCase()},this.parseISO=function(e){return t.dayjs(e)},this.toISO=function(e){return e.toISOString()},this.parse=function(e,n){return""===e?null:t.dayjs(e,n,t.locale,!0)},this.date=function(e){return null===e?null:t.dayjs(e)},this.toJsDate=function(e){return e.toDate()},this.isValid=function(e){return t.dayjs(e).isValid()},this.isNull=function(e){return null===e},this.getDiff=function(e,t,n){return e.diff(t,n)},this.isAfter=function(e,t){return e.isAfter(t)},this.isBefore=function(e,t){return e.isBefore(t)},this.isAfterDay=function(e,t){return e.isAfter(t,"day")},this.isBeforeDay=function(e,t){return e.isBefore(t,"day")},this.isBeforeYear=function(e,t){return e.isBefore(t,"year")},this.isAfterYear=function(e,t){return e.isAfter(t,"year")},this.startOfDay=function(e){return e.clone().startOf("day")},this.endOfDay=function(e){return e.clone().endOf("day")},this.format=function(e,n){return t.formatByString(e,t.formats[n])},this.formatByString=function(e,n){return t.dayjs(e).format(n)},this.formatNumber=function(e){return e},this.getHours=function(e){return e.hour()},this.addSeconds=function(e,t){return t<0?e.subtract(Math.abs(t),"second"):e.add(t,"second")},this.addMinutes=function(e,t){return t<0?e.subtract(Math.abs(t),"minute"):e.add(t,"minute")},this.addHours=function(e,t){return t<0?e.subtract(Math.abs(t),"hour"):e.add(t,"hour")},this.addDays=function(e,t){return t<0?e.subtract(Math.abs(t),"day"):e.add(t,"day")},this.addWeeks=function(e,t){return t<0?e.subtract(Math.abs(t),"week"):e.add(t,"week")},this.addMonths=function(e,t){return t<0?e.subtract(Math.abs(t),"month"):e.add(t,"month")},this.setMonth=function(e,t){return e.set("month",t)},this.setHours=function(e,t){return e.set("hour",t)},this.getMinutes=function(e){return e.minute()},this.setMinutes=function(e,t){return e.clone().set("minute",t)},this.getSeconds=function(e){return e.second()},this.setSeconds=function(e,t){return e.clone().set("second",t)},this.getMonth=function(e){return e.month()},this.getDaysInMonth=function(e){return e.daysInMonth()},this.isSameDay=function(e,t){return e.isSame(t,"day")},this.isSameMonth=function(e,t){return e.isSame(t,"month")},this.isSameYear=function(e,t){return e.isSame(t,"year")},this.isSameHour=function(e,t){return e.isSame(t,"hour")},this.getMeridiemText=function(e){return"am"===e?"AM":"PM"},this.startOfMonth=function(e){return e.clone().startOf("month")},this.endOfMonth=function(e){return e.clone().endOf("month")},this.startOfWeek=function(e){return e.clone().startOf("week")},this.endOfWeek=function(e){return e.clone().endOf("week")},this.getNextMonth=function(e){return e.clone().add(1,"month")},this.getPreviousMonth=function(e){return e.clone().subtract(1,"month")},this.getMonthArray=function(e){for(var n=[e.clone().startOf("year")];n.length<12;){var r=n[n.length-1];n.push(t.getNextMonth(r))}return n},this.getYear=function(e){return e.year()},this.setYear=function(e,t){return e.clone().set("year",t)},this.mergeDateAndTime=function(e,t){return e.hour(t.hour()).minute(t.minute()).second(t.second())},this.getWeekdays=function(){var e=t.dayjs().startOf("week");return[0,1,2,3,4,5,6].map((function(n){return t.formatByString(e.add(n,"day"),"dd")}))},this.isEqual=function(e,n){return null===e&&null===n||t.dayjs(e).isSame(n)},this.getWeekArray=function(e){for(var n=t.dayjs(e).clone().startOf("month").startOf("week"),r=t.dayjs(e).clone().endOf("month").endOf("week"),o=0,i=n,a=[];i.isBefore(r);){var u=Math.floor(o/7);a[u]=a[u]||[],a[u].push(i),i=i.clone().add(1,"day"),o+=1}return a},this.getYearRange=function(e,n){for(var r=t.dayjs(e).startOf("year"),o=t.dayjs(n).endOf("year"),i=[],a=r;a.isBefore(o);)i.push(a),a=a.clone().add(1,"year");return i},this.isWithinRange=function(e,t){var n=t[0],r=t[1];return e.isBetween(n,r,null,"[]")},this.rawDayJsInstance=i||yn(),this.dayjs=function(e,t){return t?function(){for(var n=[],r=0;r0&&void 0!==arguments[0]?arguments[0]:{},n=e.defaultTheme,r=e.defaultClassName,i=void 0===r?"MuiBox-root":r,a=e.generateClassName,u=e.styleFunctionSx,l=void 0===u?Gr.Z:u,s=(0,Xr.ZP)("div")(l),c=t.forwardRef((function(e,t){var r=(0,Rt.Z)(n),u=eo(e),l=u.className,c=u.component,d=void 0===c?"div":c,f=(0,X.Z)(u,to);return(0,ie.tZ)(s,(0,o.Z)({as:d,ref:t,className:(0,G.Z)(l,a?a(i):i),theme:r},f))}));return c}({defaultTheme:(0,wr.Z)(),defaultClassName:"MuiBox-root",generateClassName:no.Z.generate}),oo=ro,io=n(181);function ao(e,t){var n="undefined"!==typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=(0,io.Z)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw i}}}}var uo,lo,so="u-off",co="u-label",fo="width",po="height",ho="top",mo="bottom",vo="left",go="right",yo="#000",bo="#0000",xo="mousemove",Zo="mousedown",wo="mouseup",Do="mouseenter",ko="mouseleave",So="dblclick",Co="change",_o="dppxchange",Eo="undefined"!=typeof window,Ao=Eo?document:null,Mo=Eo?window:null,To=Eo?navigator:null;function Po(e,t){if(null!=t){var n=e.classList;!n.contains(t)&&n.add(t)}}function Ro(e,t){var n=e.classList;n.contains(t)&&n.remove(t)}function Fo(e,t,n){e.style[t]=n+"px"}function Oo(e,t,n,r){var o=Ao.createElement(e);return null!=t&&Po(o,t),null!=n&&n.insertBefore(o,r),o}function Bo(e,t){return Oo("div",e,t)}var Io=new WeakMap;function Lo(e,t,n,r,o){var i="translate("+t+"px,"+n+"px)";i!=Io.get(e)&&(e.style.transform=i,Io.set(e,i),t<0||n<0||t>r||n>o?Po(e,so):Ro(e,so))}var No=new WeakMap;function zo(e,t,n){var r=t+n;r!=No.get(e)&&(No.set(e,r),e.style.background=t,e.style.borderColor=n)}var jo=new WeakMap;function Wo(e,t,n,r){var o=t+""+n;o!=jo.get(e)&&(jo.set(e,o),e.style.height=n+"px",e.style.width=t+"px",e.style.marginLeft=r?-t/2+"px":0,e.style.marginTop=r?-n/2+"px":0)}var $o={passive:!0},Ho=vn(vn({},$o),{},{capture:!0});function Yo(e,t,n,r){t.addEventListener(e,n,r?Ho:$o)}function Vo(e,t,n,r){t.removeEventListener(e,n,r?Ho:$o)}function Uo(e,t,n,r){var o;n=n||0;for(var i=(r=r||t.length-1)<=2147483647;r-n>1;)t[o=i?n+r>>1:fi((n+r)/2)]=t&&o<=n;o+=r)if(null!=e[o])return o;return-1}function Xo(e,t,n,r){var o=wi,i=-wi;if(1==r)o=e[t],i=e[n];else if(-1==r)o=e[n],i=e[t];else for(var a=t;a<=n;a++)null!=e[a]&&(o=mi(o,e[a]),i=vi(i,e[a]));return[o,i]}function Go(e,t,n){for(var r=wi,o=-wi,i=t;i<=n;i++)e[i]>0&&(r=mi(r,e[i]),o=vi(o,e[i]));return[r==wi?1:r,o==-wi?10:o]}Eo&&function e(){var t=devicePixelRatio;uo!=t&&(uo=t,lo&&Vo(Co,lo,e),lo=matchMedia("(min-resolution: ".concat(uo-.001,"dppx) and (max-resolution: ").concat(uo+.001,"dppx)")),Yo(Co,lo,e),Mo.dispatchEvent(new CustomEvent(_o)))}();var Ko=[0,0];function Qo(e,t,n,r){return Ko[0]=n<0?Fi(e,-n):e,Ko[1]=r<0?Fi(t,-r):t,Ko}function Jo(e,t,n,r){var o,i,a,u=yi(e),l=10==n?bi:xi;return e==t&&(-1==u?(e*=n,t/=n):(e/=n,t*=n)),r?(o=fi(l(e)),i=hi(l(t)),e=(a=Qo(gi(n,o),gi(n,i),o,i))[0],t=a[1]):(o=fi(l(di(e))),i=fi(l(di(t))),e=Ri(e,(a=Qo(gi(n,o),gi(n,i),o,i))[0]),t=Pi(t,a[1])),[e,t]}function ei(e,t,n,r){var o=Jo(e,t,n,r);return 0==e&&(o[0]=0),0==t&&(o[1]=0),o}var ti={mode:3,pad:.1},ni={pad:0,soft:null,mode:0},ri={min:ni,max:ni};function oi(e,t,n,r){return $i(n)?ai(e,t,n):(ni.pad=n,ni.soft=r?0:null,ni.mode=r?3:0,ai(e,t,ri))}function ii(e,t){return null==e?t:e}function ai(e,t,n){var r=n.min,o=n.max,i=ii(r.pad,0),a=ii(o.pad,0),u=ii(r.hard,-wi),l=ii(o.hard,wi),s=ii(r.soft,wi),c=ii(o.soft,-wi),d=ii(r.mode,0),f=ii(o.mode,0),p=t-e;p<1e-9&&(p=0,0!=e&&0!=t||(p=1e-9,2==d&&s!=wi&&(i=0),2==f&&c!=-wi&&(a=0)));var h=p||di(t)||1e3,m=bi(h),v=gi(10,fi(m)),g=Fi(Ri(e-h*(0==p?0==e?.1:1:i),v/10),9),y=e>=s&&(1==d||3==d&&g<=s||2==d&&g>=s)?s:wi,b=vi(u,g=y?y:mi(y,g)),x=Fi(Pi(t+h*(0==p?0==t?.1:1:a),v/10),9),Z=t<=c&&(1==f||3==f&&x>=c||2==f&&x<=c)?c:-wi,w=mi(l,x>Z&&t<=Z?Z:vi(Z,x));return b==w&&0==b&&(w=100),[b,w]}var ui=new Intl.NumberFormat(Eo?To.language:"en-US"),li=function(e){return ui.format(e)},si=Math,ci=si.PI,di=si.abs,fi=si.floor,pi=si.round,hi=si.ceil,mi=si.min,vi=si.max,gi=si.pow,yi=si.sign,bi=si.log10,xi=si.log2,Zi=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return si.asinh(e/t)},wi=1/0;function Di(e){return 1+(0|bi((e^e>>31)-(e>>31)))}function ki(e,t){return pi(e/t)*t}function Si(e,t,n){return mi(vi(e,t),n)}function Ci(e){return"function"==typeof e?e:function(){return e}}var _i=function(e){return e},Ei=function(e,t){return t},Ai=function(e){return null},Mi=function(e){return!0},Ti=function(e,t){return e==t};function Pi(e,t){return hi(e/t)*t}function Ri(e,t){return fi(e/t)*t}function Fi(e,t){return pi(e*(t=Math.pow(10,t)))/t}var Oi=new Map;function Bi(e){return((""+e).split(".")[1]||"").length}function Ii(e,t,n,r){for(var o=[],i=r.map(Bi),a=t;a=0&&a>=0?0:u)+(a>=i[s]?0:i[s]),f=Fi(c,d);o.push(f),Oi.set(f,d)}return o}var Li={},Ni=[],zi=[null,null],ji=Array.isArray;function Wi(e){return"string"==typeof e}function $i(e){var t=!1;if(null!=e){var n=e.constructor;t=null==n||n==Object}return t}function Hi(e){return null!=e&&"object"==typeof e}function Yi(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:$i;if(ji(e)){var r=e.find((function(e){return null!=e}));if(ji(r)||n(r)){t=Array(e.length);for(var o=0;oi){for(r=a-1;r>=0&&null==e[r];)e[r--]=null;for(r=a+1;r12?t-12:t},AA:function(e){return e.getHours()>=12?"PM":"AM"},aa:function(e){return e.getHours()>=12?"pm":"am"},a:function(e){return e.getHours()>=12?"p":"a"},mm:function(e){return ta(e.getMinutes())},m:function(e){return e.getMinutes()},ss:function(e){return ta(e.getSeconds())},s:function(e){return e.getSeconds()},fff:function(e){return((t=e.getMilliseconds())<10?"00":t<100?"0":"")+t;var t}};function ra(e,t){t=t||ea;for(var n,r=[],o=/\{([a-z]+)\}|[^{]+/gi;n=o.exec(e);)r.push("{"==n[0][0]?na[n[1]]:n[0]);return function(e){for(var n="",o=0;o=a,m=d>=i&&d=o?o:d,M=b+(fi(s)-fi(g))+Pi(g-b,A);p.push(M);for(var T=t(M),P=T.getHours()+T.getMinutes()/n+T.getSeconds()/r,R=d/r,F=f/u.axes[l]._space;!((M=Fi(M+d,1==e?0:3))>c);)if(R>1){var O=fi(Fi(P+R,6))%24,B=t(M).getHours()-O;B>1&&(B=-1),P=(P+R)%24,Fi(((M-=B*r)-p[p.length-1])/d,3)*F>=.7&&p.push(M)}else p.push(M)}return p}}]}var wa=Za(1),Da=(0,r.Z)(wa,3),ka=Da[0],Sa=Da[1],Ca=Da[2],_a=Za(.001),Ea=(0,r.Z)(_a,3),Aa=Ea[0],Ma=Ea[1],Ta=Ea[2];function Pa(e,t){return e.map((function(e){return e.map((function(n,r){return 0==r||8==r||null==n?n:t(1==r||0==e[8]?n:e[1]+n)}))}))}function Ra(e,t){return function(n,r,o,i,a){var u,l,s,c,d,f,p=t.find((function(e){return a>=e[0]}))||t[t.length-1];return r.map((function(t){var n=e(t),r=n.getFullYear(),o=n.getMonth(),i=n.getDate(),a=n.getHours(),h=n.getMinutes(),m=n.getSeconds(),v=r!=u&&p[2]||o!=l&&p[3]||i!=s&&p[4]||a!=c&&p[5]||h!=d&&p[6]||m!=f&&p[7]||p[1];return u=r,l=o,s=i,c=a,d=h,f=m,v(n)}))}}function Fa(e,t,n){return new Date(e,t,n)}function Oa(e,t){return t(e)}Ii(2,-53,53,[1]);function Ba(e,t){return function(n,r){return t(e(r))}}var Ia={show:!0,live:!0,isolate:!1,markers:{show:!0,width:2,stroke:function(e,t){var n=e.series[t];return n.width?n.stroke(e,t):n.points.width?n.points.stroke(e,t):null},fill:function(e,t){return e.series[t].fill(e,t)},dash:"solid"},idx:null,idxs:null,values:[]};var La=[0,0];function Na(e,t,n){return function(e){0==e.button&&n(e)}}function za(e,t,n){return n}var ja={show:!0,x:!0,y:!0,lock:!1,move:function(e,t,n){return La[0]=t,La[1]=n,La},points:{show:function(e,t){var n=e.cursor.points,r=Bo(),o=n.size(e,t);Fo(r,fo,o),Fo(r,po,o);var i=o/-2;Fo(r,"marginLeft",i),Fo(r,"marginTop",i);var a=n.width(e,t,o);return a&&Fo(r,"borderWidth",a),r},size:function(e,t){return uu(e.series[t].points.width,1)},width:0,stroke:function(e,t){var n=e.series[t].points;return n._stroke||n._fill},fill:function(e,t){var n=e.series[t].points;return n._fill||n._stroke}},bind:{mousedown:Na,mouseup:Na,click:Na,dblclick:Na,mousemove:za,mouseleave:za,mouseenter:za},drag:{setScale:!0,x:!0,y:!1,dist:0,uni:null,_x:!1,_y:!1},focus:{prox:-1},left:-10,top:-10,idx:null,dataIdx:function(e,t,n){return n},idxs:null},Wa={show:!0,stroke:"rgba(0,0,0,0.07)",width:2},$a=Vi({},Wa,{filter:Ei}),Ha=Vi({},$a,{size:10}),Ya=Vi({},Wa,{show:!1}),Va='12px system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"',Ua="bold "+Va,qa={show:!0,scale:"x",stroke:yo,space:50,gap:5,size:50,labelGap:0,labelSize:30,labelFont:Ua,side:2,grid:$a,ticks:Ha,border:Ya,font:Va,rotate:0},Xa={show:!0,scale:"x",auto:!1,sorted:1,min:wi,max:-wi,idxs:[]};function Ga(e,t,n,r,o){return t.map((function(e){return null==e?"":li(e)}))}function Ka(e,t,n,r,o,i,a){for(var u=[],l=Oi.get(o)||0,s=n=a?n:Fi(Pi(n,o),l);s<=r;s=Fi(s+o,l))u.push(Object.is(s,-0)?0:s);return u}function Qa(e,t,n,r,o,i,a){var u=[],l=e.scales[e.axes[t].scale].log,s=fi((10==l?bi:xi)(n));o=gi(l,s),s<0&&(o=Fi(o,-s));var c=n;do{u.push(c),(c=Fi(c+o,Oi.get(o)))>=o*l&&(o=c)}while(c<=r);return u}function Ja(e,t,n,r,o,i,a){var u=e.scales[e.axes[t].scale].asinh,l=r>u?Qa(e,t,vi(u,n),r,o):[u],s=r>=0&&n<=0?[0]:[];return(n<-u?Qa(e,t,vi(u,-r),-n,o):[u]).reverse().map((function(e){return-e})).concat(s,l)}var eu=/./,tu=/[12357]/,nu=/[125]/,ru=/1/;function ou(e,t,n,r,o){var i=e.axes[n],a=i.scale,u=e.scales[a];if(3==u.distr&&2==u.log)return t;var l=e.valToPos,s=i._space,c=l(10,a),d=l(9,a)-c>=s?eu:l(7,a)-c>=s?tu:l(5,a)-c>=s?nu:ru;return t.map((function(e){return 4==u.distr&&0==e||d.test(e)?e:null}))}function iu(e,t){return null==t?"":li(t)}var au={show:!0,scale:"y",stroke:yo,space:30,gap:5,size:50,labelGap:0,labelSize:30,labelFont:Ua,side:3,grid:$a,ticks:Ha,border:Ya,font:Va,rotate:0};function uu(e,t){return Fi((3+2*(e||1))*t,3)}var lu={scale:null,auto:!0,sorted:0,min:wi,max:-wi},su={show:!0,auto:!0,sorted:0,alpha:1,facets:[Vi({},lu,{scale:"x"}),Vi({},lu,{scale:"y"})]},cu={scale:"y",auto:!0,sorted:0,show:!0,spanGaps:!1,gaps:function(e,t,n,r,o){return o},alpha:1,points:{show:function(e,t){var n=e.series[0],r=n.scale,o=n.idxs,i=e._data[0],a=e.valToPos(i[o[0]],r,!0),u=e.valToPos(i[o[1]],r,!0),l=di(u-a)/(e.series[t].points.space*uo);return o[1]-o[0]<=l},filter:null},values:null,min:wi,max:-wi,idxs:[],path:null,clip:null};function du(e,t,n,r,o){return n/10}var fu={time:!0,auto:!0,distr:1,log:10,asinh:1,min:null,max:null,dir:1,ori:0},pu=Vi({},fu,{time:!1,ori:1}),hu={};function mu(e,t){var n=hu[e];return n||(n={key:e,plots:[],sub:function(e){n.plots.push(e)},unsub:function(e){n.plots=n.plots.filter((function(t){return t!=e}))},pub:function(e,t,r,o,i,a,u){for(var l=0;l0){a=new Path2D;for(var u=0==t?Eu:Au,l=n,s=0;sc[0]){var d=c[0]-l;d>0&&u(a,l,r,d,r+i),l=c[1]}}var f=n+o-l;f>0&&u(a,l,r,f,r+i)}return a}function Zu(e,t,n){var r=e[e.length-1];r&&r[0]==t?r[1]=n:e.push([t,n])}function wu(e){return 0==e?_i:1==e?pi:function(t){return ki(t,e)}}function Du(e){var t=0==e?ku:Su,n=0==e?function(e,t,n,r,o,i){e.arcTo(t,n,r,o,i)}:function(e,t,n,r,o,i){e.arcTo(n,t,o,r,i)},r=0==e?function(e,t,n,r,o){e.rect(t,n,r,o)}:function(e,t,n,r,o){e.rect(n,t,o,r)};return function(e,o,i,a,u){var l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;0==l?r(e,o,i,a,u):(l=mi(l,a/2,u/2),t(e,o+l,i),n(e,o+a,i,o+a,i+u,l),n(e,o+a,i+u,o,i+u,l),n(e,o,i+u,o,i,l),n(e,o,i,o+a,i,l),e.closePath())}}var ku=function(e,t,n){e.moveTo(t,n)},Su=function(e,t,n){e.moveTo(n,t)},Cu=function(e,t,n){e.lineTo(t,n)},_u=function(e,t,n){e.lineTo(n,t)},Eu=Du(0),Au=Du(1),Mu=function(e,t,n,r,o,i){e.arc(t,n,r,o,i)},Tu=function(e,t,n,r,o,i){e.arc(n,t,r,o,i)},Pu=function(e,t,n,r,o,i,a){e.bezierCurveTo(t,n,r,o,i,a)},Ru=function(e,t,n,r,o,i,a){e.bezierCurveTo(n,t,o,r,a,i)};function Fu(e){return function(e,t,n,r,o){return vu(e,t,(function(t,i,a,u,l,s,c,d,f,p,h){var m,v,g=t.pxRound,y=t.points;0==u.ori?(m=ku,v=Mu):(m=Su,v=Tu);var b=Fi(y.width*uo,3),x=(y.size-y.width)/2*uo,Z=Fi(2*x,3),w=new Path2D,D=new Path2D,k=e.bbox,S=k.left,C=k.top,_=k.width,E=k.height;Eu(D,S-Z,C-Z,_+2*Z,E+2*Z);var A=function(e){if(null!=a[e]){var t=g(s(i[e],u,p,d)),n=g(c(a[e],l,h,f));m(w,t+x,n),v(w,t,n,x,0,2*ci)}};if(o)o.forEach(A);else for(var M=n;M<=r;M++)A(M);return{stroke:b>0?w:null,fill:w,clip:D,flags:3}}))}}function Ou(e){return function(t,n,r,o,i,a){r!=o&&(i!=r&&a!=r&&e(t,n,r),i!=o&&a!=o&&e(t,n,o),e(t,n,a))}}var Bu=Ou(Cu),Iu=Ou(_u);function Lu(){return function(e,t,n,o){return vu(e,t,(function(i,a,u,l,s,c,d,f,p,h,m){var v,g,y=i.pxRound,b=function(e){return y(c(e,l,h,f))},x=function(e){return y(d(e,s,m,p))};0==l.ori?(v=Cu,g=Bu):(v=_u,g=Iu);for(var Z,w,D,k=l.dir*(0==l.ori?1:-1),S={stroke:new Path2D,fill:null,clip:null,band:null,gaps:null,flags:1},C=S.stroke,_=wi,E=-wi,A=b(a[1==k?n:o]),M=qo(u,n,o,1*k),T=qo(u,n,o,-1*k),P=b(a[M]),R=b(a[T]),F=1==k?n:o;F>=n&&F<=o;F+=k){var O=b(a[F]);O==A?null!=u[F]&&(w=x(u[F]),_==wi&&(v(C,O,w),Z=w),_=mi(w,_),E=vi(w,E)):(_!=wi&&(g(C,A,_,E,Z,w),D=A),null!=u[F]?(v(C,O,w=x(u[F])),_=E=Z=w):(_=wi,E=-wi),A=O)}_!=wi&&_!=E&&D!=A&&g(C,A,_,E,Z,w);var B=gu(e,t),I=(0,r.Z)(B,2),L=I[0],N=I[1];if(null!=i.fill||0!=L){var z=S.fill=new Path2D(C),j=x(i.fillTo(e,t,i.min,i.max,L));v(z,R,j),v(z,P,j)}if(!i.spanGaps){var W,$=[];P>f&&$.push([f,P]),(W=$).push.apply(W,(0,ve.Z)(function(e,t,n,r,o,i){for(var a=[],u=1==o?n:r;u>=n&&u<=r;u+=o)if(null===t[u]){var l=u,s=u;if(1==o)for(;++u<=r&&null===t[u];)s=u;else for(;--u>=n&&null===t[u];)s=u;var c=i(e[l]),d=s==l||i(e[s]);c=i(e[l-o]),(d=i(e[s+o]))>=c&&a.push([c,d])}return a}(a,u,n,o,k,b))),R0!==s[p]>0?l[p]=0:(l[p]=3*(d[p-1]+d[p])/((2*d[p]+d[p-1])/s[p-1]+(d[p]+2*d[p-1])/s[p]),isFinite(l[p])||(l[p]=0));l[a-1]=s[a-2];for(var h=0;h=o&&i+(l<5?Oi.get(l):0)<=17)return[l,s]}while(++u0?e:t.clamp(o,e,t.min,t.max,t.key)):4==t.distr?Zi(e,t.asinh):e)-t._min)/(t._max-t._min)}function u(e,t,n,r){var o=a(e,t);return r+n*(-1==t.dir?1-o:o)}function l(e,t,n,r){var o=a(e,t);return r+n*(-1==t.dir?o:1-o)}function s(e,t,n,r){return 0==t.ori?u(e,t,n,r):l(e,t,n,r)}o.valToPosH=u,o.valToPosV=l;var c=!1;o.status=0;var d=o.root=Bo("uplot");(null!=e.id&&(d.id=e.id),Po(d,e.class),e.title)&&(Bo("u-title",d).textContent=e.title);var f=Oo("canvas"),p=o.ctx=f.getContext("2d"),h=Bo("u-wrap",d),m=o.under=Bo("u-under",h);h.appendChild(f);var v=o.over=Bo("u-over",h),g=+ii((e=Yi(e)).pxAlign,1),y=wu(g);(e.plugins||[]).forEach((function(t){t.opts&&(e=t.opts(o,e)||e)}));var b,x,Z=e.ms||.001,w=o.series=1==i?Hu(e.series||[],Xa,cu,!1):(b=e.series||[null],x=su,b.map((function(e,t){return 0==t?null:Vi({},x,e)}))),D=o.axes=Hu(e.axes||[],qa,au,!0),k=o.scales={},S=o.bands=e.bands||[];S.forEach((function(e){e.fill=Ci(e.fill||null),e.dir=ii(e.dir,-1)}));var C=2==i?w[1].facets[0].scale:w[0].scale,_={axes:function(){for(var e=function(e){var t=D[e];if(!t.show||!t._show)return"continue";var n=t.side,i=n%2,a=void 0,u=void 0,l=t.stroke(o,e),c=0==n||3==n?-1:1;if(t.label){var d=t.labelGap*c,f=pi((t._lpos+d)*uo);et(t.labelFont[0],l,"center",2==n?ho:mo),p.save(),1==i?(a=u=0,p.translate(f,pi(me+ge/2)),p.rotate((3==n?-ci:ci)/2)):(a=pi(he+ve/2),u=f),p.fillText(t.label,a,u),p.restore()}var h=(0,r.Z)(t._found,2),m=h[0],v=h[1];if(0==v)return"continue";var g=k[t.scale],b=0==i?ve:ge,x=0==i?he:me,Z=pi(t.gap*uo),w=t._splits,S=2==g.distr?w.map((function(e){return Xe[e]})):w,C=2==g.distr?Xe[w[1]]-Xe[w[0]]:m,_=t.ticks,E=t.border,A=_.show?pi(_.size*uo):0,M=t._rotate*-ci/180,T=y(t._pos*uo),P=T+(A+Z)*c;u=0==i?P:0,a=1==i?P:0,et(t.font[0],l,1==t.align?vo:2==t.align?go:M>0?vo:M<0?go:0==i?"center":3==n?go:vo,M||1==i?"middle":2==n?ho:mo);for(var R=1.5*t.font[1],F=w.map((function(e){return y(s(e,g,b,x))})),O=t._values,B=0;B0&&(w.forEach((function(e,n){if(n>0&&e.show&&null==e._paths){var r=function(e){var t=Si(Ve-1,0,Re-1),n=Si(Ue+1,0,Re-1);for(;null==e[t]&&t>0;)t--;for(;null==e[n]&&n0&&e.show){$e!=e.alpha&&(p.globalAlpha=$e=e.alpha),nt(t,!1),e._paths&&rt(t,!1),nt(t,!0);var n=e.points.show(o,t,Ve,Ue),r=e.points.filter(o,t,n,e._paths?e._paths.gaps:null);(n||r)&&(e.points._paths=e.points.paths(o,t,Ve,Ue,r),rt(t,!0)),1!=$e&&(p.globalAlpha=$e=1),un("drawSeries",t)}})))}},E=(e.drawOrder||["axes","series"]).map((function(e){return _[e]}));function A(t){var n=k[t];if(null==n){var r=(e.scales||Li)[t]||Li;if(null!=r.from)A(r.from),k[t]=Vi({},k[r.from],r,{key:t});else{(n=k[t]=Vi({},t==C?fu:pu,r)).key=t;var o=n.time,a=n.range,u=ji(a);if((t!=C||2==i&&!o)&&(!u||null!=a[0]&&null!=a[1]||(a={min:null==a[0]?ti:{mode:1,hard:a[0],soft:a[0]},max:null==a[1]?ti:{mode:1,hard:a[1],soft:a[1]}},u=!1),!u&&$i(a))){var l=a;a=function(e,t,n){return null==t?zi:oi(t,n,l)}}n.range=Ci(a||(o?Uu:t==C?3==n.distr?Gu:4==n.distr?Qu:Vu:3==n.distr?Xu:4==n.distr?Ku:qu)),n.auto=Ci(!u&&n.auto),n.clamp=Ci(n.clamp||du),n._min=n._max=null}}}for(var M in A("x"),A("y"),1==i&&w.forEach((function(e){A(e.scale)})),D.forEach((function(e){A(e.scale)})),e.scales)A(M);var T,P,R=k[C],F=R.distr;0==R.ori?(Po(d,"u-hz"),T=u,P=l):(Po(d,"u-vt"),T=l,P=u);var O={};for(var B in k){var I=k[B];null==I.min&&null==I.max||(O[B]={min:I.min,max:I.max},I.min=I.max=null)}var L,N=e.tzDate||function(e){return new Date(pi(e/Z))},z=e.fmtDate||ra,j=1==Z?Ca(N):Ta(N),W=Ra(N,Pa(1==Z?Sa:Ma,z)),$=Ba(N,Oa("{YYYY}-{MM}-{DD} {h}:{mm}{aa}",z)),H=[],Y=o.legend=Vi({},Ia,e.legend),V=Y.show,U=Y.markers;Y.idxs=H,U.width=Ci(U.width),U.dash=Ci(U.dash),U.stroke=Ci(U.stroke),U.fill=Ci(U.fill);var q,X=[],G=[],K=!1,Q={};if(Y.live){var J=w[1]?w[1].values:null;for(var ee in q=(K=null!=J)?J(o,1,0):{_:0})Q[ee]="--"}if(V)if(L=Oo("table","u-legend",d),K){var te=Oo("tr","u-thead",L);for(var ne in Oo("th",null,te),q)Oo("th",co,te).textContent=ne}else Po(L,"u-inline"),Y.live&&Po(L,"u-live");var re={show:!0},oe={show:!1};var ie=new Map;function ae(e,t,n){var r=ie.get(t)||{},i=Se.bind[e](o,t,n);i&&(Yo(e,t,r[e]=i),ie.set(t,r))}function ue(e,t,n){var r=ie.get(t)||{};for(var o in r)null!=e&&o!=e||(Vo(o,t,r[o]),delete r[o]);null==e&&ie.delete(t)}var le=0,se=0,ce=0,de=0,fe=0,pe=0,he=0,me=0,ve=0,ge=0;o.bbox={};var ye=!1,be=!1,xe=!1,Ze=!1,we=!1;function De(e,t,n){(n||e!=o.width||t!=o.height)&&ke(e,t),ct(!1),xe=!0,be=!0,Ze=we=Se.left>=0,kt()}function ke(e,t){o.width=le=ce=e,o.height=se=de=t,fe=pe=0,function(){var e=!1,t=!1,n=!1,r=!1;D.forEach((function(o,i){if(o.show&&o._show){var a=o.side,u=a%2,l=o._size+(null!=o.label?o.labelSize:0);l>0&&(u?(ce-=l,3==a?(fe+=l,r=!0):n=!0):(de-=l,0==a?(pe+=l,e=!0):t=!0))}})),Te[0]=e,Te[1]=n,Te[2]=t,Te[3]=r,ce-=Ye[1]+Ye[3],fe+=Ye[3],de-=Ye[2]+Ye[0],pe+=Ye[0]}(),function(){var e=fe+ce,t=pe+de,n=fe,r=pe;function o(o,i){switch(o){case 1:return(e+=i)-i;case 2:return(t+=i)-i;case 3:return(n-=i)+i;case 0:return(r-=i)+i}}D.forEach((function(e,t){if(e.show&&e._show){var n=e.side;e._pos=o(n,e._size),null!=e.label&&(e._lpos=o(n,e.labelSize))}}))}();var n=o.bbox;he=n.left=ki(fe*uo,.5),me=n.top=ki(pe*uo,.5),ve=n.width=ki(ce*uo,.5),ge=n.height=ki(de*uo,.5)}o.setSize=function(e){De(e.width,e.height)};var Se=o.cursor=Vi({},ja,{drag:{y:2==i}},e.cursor);Se.idxs=H,Se._lock=!1;var Ce=Se.points;Ce.show=Ci(Ce.show),Ce.size=Ci(Ce.size),Ce.stroke=Ci(Ce.stroke),Ce.width=Ci(Ce.width),Ce.fill=Ci(Ce.fill);var _e=o.focus=Vi({},e.focus||{alpha:.3},Se.focus),Ee=_e.prox>=0,Ae=[null];function Me(e,t){if(1==i||t>0){var n=1==i&&k[e.scale].time,r=e.value;e.value=n?Wi(r)?Ba(N,Oa(r,z)):r||$:r||iu,e.label=e.label||(n?"Time":"Value")}if(t>0){e.width=null==e.width?1:e.width,e.paths=e.paths||Wu||Ai,e.fillTo=Ci(e.fillTo||yu),e.pxAlign=+ii(e.pxAlign,g),e.pxRound=wu(e.pxAlign),e.stroke=Ci(e.stroke||null),e.fill=Ci(e.fill||null),e._stroke=e._fill=e._paths=e._focus=null;var a=uu(e.width,1),u=e.points=Vi({},{size:a,width:vi(1,.2*a),stroke:e.stroke,space:2*a,paths:$u,_stroke:null,_fill:null},e.points);u.show=Ci(u.show),u.filter=Ci(u.filter),u.fill=Ci(u.fill),u.stroke=Ci(u.stroke),u.paths=Ci(u.paths),u.pxAlign=e.pxAlign}if(V){var l=function(e,t){if(0==t&&(K||!Y.live||2==i))return zi;var n=[],r=Oo("tr","u-series",L,L.childNodes[t]);Po(r,e.class),e.show||Po(r,so);var a=Oo("th",null,r);if(U.show){var u=Bo("u-marker",a);if(t>0){var l=U.width(o,t);l&&(u.style.border=l+"px "+U.dash(o,t)+" "+U.stroke(o,t)),u.style.background=U.fill(o,t)}}var s=Bo(co,a);for(var c in s.textContent=e.label,t>0&&(U.show||(s.style.color=e.width>0?U.stroke(o,t):U.fill(o,t)),ae("click",a,(function(t){if(!Se._lock){var n=w.indexOf(e);if((t.ctrlKey||t.metaKey)!=Y.isolate){var r=w.some((function(e,t){return t>0&&t!=n&&e.show}));w.forEach((function(e,t){t>0&&Lt(t,r?t==n?re:oe:re,!0,ln.setSeries)}))}else Lt(n,{show:!e.show},!0,ln.setSeries)}})),Ee&&ae(Do,a,(function(t){Se._lock||Lt(w.indexOf(e),Nt,!0,ln.setSeries)}))),q){var d=Oo("td","u-value",r);d.textContent="--",n.push(d)}return[r,n]}(e,t);X.splice(t,0,l[0]),G.splice(t,0,l[1]),Y.values.push(null)}if(Se.show){H.splice(t,0,null);var s=function(e,t){if(t>0){var n=Se.points.show(o,t);if(n)return Po(n,"u-cursor-pt"),Po(n,e.class),Lo(n,-10,-10,ce,de),v.insertBefore(n,Ae[t]),n}}(e,t);s&&Ae.splice(t,0,s)}un("addSeries",t)}o.addSeries=function(e,t){e=Yu(e,t=null==t?w.length:t,Xa,cu),w.splice(t,0,e),Me(w[t],t)},o.delSeries=function(e){if(w.splice(e,1),V){Y.values.splice(e,1),G.splice(e,1);var t=X.splice(e,1)[0];ue(null,t.firstChild),t.remove()}Se.show&&(H.splice(e,1),Ae.length>1&&Ae.splice(e,1)[0].remove()),un("delSeries",e)};var Te=[!1,!1,!1,!1];function Pe(e,t,n,o){var i=(0,r.Z)(n,4),a=i[0],u=i[1],l=i[2],s=i[3],c=t%2,d=0;return 0==c&&(s||u)&&(d=0==t&&!a||2==t&&!l?pi(qa.size/3):0),1==c&&(a||l)&&(d=1==t&&!u||3==t&&!s?pi(au.size/2):0),d}var Re,Fe,Oe,Be,Ie,Le,Ne,ze,je,We,$e,He=o.padding=(e.padding||[Pe,Pe,Pe,Pe]).map((function(e){return Ci(ii(e,Pe))})),Ye=o._padding=He.map((function(e,t){return e(o,t,Te,0)})),Ve=null,Ue=null,qe=1==i?w[0].idxs:null,Xe=null,Ge=!1;function Ke(e,n){if(t=null==e?[]:Yi(e,Hi),2==i){Re=0;for(var r=1;r=0,we=!0,kt()}}function Qe(){var e,n;if(Ge=!0,1==i)if(Re>0){if(Ve=qe[0]=0,Ue=qe[1]=Re-1,e=t[0][Ve],n=t[0][Ue],2==F)e=Ve,n=Ue;else if(1==Re)if(3==F){var o=Jo(e,e,R.log,!1),a=(0,r.Z)(o,2);e=a[0],n=a[1]}else if(4==F){var u=ei(e,e,R.log,!1),l=(0,r.Z)(u,2);e=l[0],n=l[1]}else if(R.time)n=e+pi(86400/Z);else{var s=oi(e,n,.1,!0),c=(0,r.Z)(s,2);e=c[0],n=c[1]}}else Ve=qe[0]=e=null,Ue=qe[1]=n=null;It(C,e,n)}function Je(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:bo,t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Ni,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"butt",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:bo,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"round";e!=Fe&&(p.strokeStyle=Fe=e),o!=Oe&&(p.fillStyle=Oe=o),t!=Be&&(p.lineWidth=Be=t),i!=Le&&(p.lineJoin=Le=i),r!=Ne&&(p.lineCap=Ne=r),n!=Ie&&p.setLineDash(Ie=n)}function et(e,t,n,r){t!=Oe&&(p.fillStyle=Oe=t),e!=ze&&(p.font=ze=e),n!=je&&(p.textAlign=je=n),r!=We&&(p.textBaseline=We=r)}function tt(e,t,n,r){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;if(e.auto(o,Ge)&&(null==t||null==t.min)){var a=ii(Ve,0),u=ii(Ue,r.length-1),l=null==n.min?3==e.distr?Go(r,a,u):Xo(r,a,u,i):[n.min,n.max];e.min=mi(e.min,n.min=l[0]),e.max=vi(e.max,n.max=l[1])}}function nt(e,t){var n=t?w[e].points:w[e];n._stroke=n.stroke(o,e),n._fill=n.fill(o,e)}function rt(e,n){var r=n?w[e].points:w[e],i=r._stroke,a=r._fill,u=r._paths,l=u.stroke,s=u.fill,c=u.clip,d=u.flags,f=null,h=Fi(r.width*uo,3),m=h%2/2;n&&null==a&&(a=h>0?"#fff":i);var v=1==r.pxAlign;if(v&&p.translate(m,m),!n){var g=he,y=me,b=ve,x=ge,Z=h*uo/2;0==r.min&&(x+=Z),0==r.max&&(y-=Z,x+=Z),(f=new Path2D).rect(g,y,b,x)}n?ot(i,h,r.dash,r.cap,a,l,s,d,c):function(e,n,r,i,a,u,l,s,c,d,f){var p=!1;S.forEach((function(h,m){if(h.series[0]==e){var v,g=w[h.series[1]],y=t[h.series[1]],b=(g._paths||Li).band;ji(b)&&(b=1==h.dir?b[0]:b[1]);var x=null;g.show&&b&&function(e,t,n){for(t=ii(t,0),n=ii(n,e.length-1);t<=n;){if(null!=e[t])return!0;t++}return!1}(y,Ve,Ue)?(x=h.fill(o,m)||u,v=g._paths.clip):b=null,ot(n,r,i,a,x,l,s,c,d,f,v,b),p=!0}})),p||ot(n,r,i,a,u,l,s,c,d,f)}(e,i,h,r.dash,r.cap,a,l,s,d,f,c),v&&p.translate(-m,-m)}o.setData=Ke;function ot(e,t,n,r,o,i,a,u,l,s,c,d){Je(e,t,n,r,o),(l||s||d)&&(p.save(),l&&p.clip(l),s&&p.clip(s)),d?3==(3&u)?(p.clip(d),c&&p.clip(c),at(o,a),it(e,i,t)):2&u?(at(o,a),p.clip(d),it(e,i,t)):1&u&&(p.save(),p.clip(d),c&&p.clip(c),at(o,a),p.restore(),it(e,i,t)):(at(o,a),it(e,i,t)),(l||s||d)&&p.restore()}function it(e,t,n){n>0&&(t instanceof Map?t.forEach((function(e,t){p.strokeStyle=Fe=t,p.stroke(e)})):null!=t&&e&&p.stroke(t))}function at(e,t){t instanceof Map?t.forEach((function(e,t){p.fillStyle=Oe=t,p.fill(e)})):null!=t&&e&&p.fill(t)}function ut(e,t,n,r,o,i,a,u,l,s){var c=a%2/2;1==g&&p.translate(c,c),Je(u,a,l,s,u),p.beginPath();var d,f,h,m,v=o+(0==r||3==r?-i:i);0==n?(f=o,m=v):(d=o,h=v);for(var y=0;y0&&(t._paths=null,e&&(1==i?(t.min=null,t.max=null):t.facets.forEach((function(e){e.min=null,e.max=null}))))}))}var dt,ft,pt,ht,mt,vt,gt,yt,bt,xt,Zt,wt,Dt=!1;function kt(){Dt||(qi(St),Dt=!0)}function St(){ye&&(!function(){var e=Yi(k,Hi);for(var n in e){var a=e[n],u=O[n];if(null!=u&&null!=u.min)Vi(a,u),n==C&&ct(!0);else if(n!=C||2==i)if(0==Re&&null==a.from){var l=a.range(o,null,null,n);a.min=l[0],a.max=l[1]}else a.min=wi,a.max=-wi}if(Re>0)for(var s in w.forEach((function(n,a){if(1==i){var u=n.scale,l=e[u],s=O[u];if(0==a){var c=l.range(o,l.min,l.max,u);l.min=c[0],l.max=c[1],Ve=Uo(l.min,t[0]),Ue=Uo(l.max,t[0]),t[0][Ve]l.max&&Ue--,n.min=Xe[Ve],n.max=Xe[Ue]}else n.show&&n.auto&&tt(l,s,n,t[a],n.sorted);n.idxs[0]=Ve,n.idxs[1]=Ue}else if(a>0&&n.show&&n.auto){var d=(0,r.Z)(n.facets,2),f=d[0],p=d[1],h=f.scale,m=p.scale,v=(0,r.Z)(t[a],2),g=v[0],y=v[1];tt(e[h],O[h],f,g,f.sorted),tt(e[m],O[m],p,y,p.sorted),n.min=p.min,n.max=p.max}})),e){var c=e[s],d=O[s];if(null==c.from&&(null==d||null==d.min)){var f=c.range(o,c.min==wi?null:c.min,c.max==-wi?null:c.max,s);c.min=f[0],c.max=f[1]}}for(var p in e){var h=e[p];if(null!=h.from){var m=e[h.from];if(null==m.min)h.min=h.max=null;else{var v=h.range(o,m.min,m.max,p);h.min=v[0],h.max=v[1]}}}var g={},y=!1;for(var b in e){var x=e[b],Z=k[b];if(Z.min!=x.min||Z.max!=x.max){Z.min=x.min,Z.max=x.max;var D=Z.distr;Z._min=3==D?bi(Z.min):4==D?Zi(Z.min,Z.asinh):Z.min,Z._max=3==D?bi(Z.max):4==D?Zi(Z.max,Z.asinh):Z.max,g[b]=y=!0}}if(y){for(var S in w.forEach((function(e,t){2==i?t>0&&g.y&&(e._paths=null):g[e.scale]&&(e._paths=null)})),g)xe=!0,un("setScale",S);Se.show&&(Ze=we=Se.left>=0)}for(var _ in O)O[_]=null}(),ye=!1),xe&&(!function(){for(var e=!1,t=0;!e;){var n=lt(++t),r=st(t);(e=3==t||n&&r)||(ke(o.width,o.height),be=!0)}}(),xe=!1),be&&(Fo(m,vo,fe),Fo(m,ho,pe),Fo(m,fo,ce),Fo(m,po,de),Fo(v,vo,fe),Fo(v,ho,pe),Fo(v,fo,ce),Fo(v,po,de),Fo(h,fo,le),Fo(h,po,se),f.width=pi(le*uo),f.height=pi(se*uo),D.forEach((function(e){var t=e._el,n=e._show,r=e._size,o=e._pos,i=e.side;if(null!=t)if(n){var a=i%2==1;Fo(t,a?"left":"top",o-(3===i||0===i?r:0)),Fo(t,a?"width":"height",r),Fo(t,a?"top":"left",a?pe:fe),Fo(t,a?"height":"width",a?de:ce),Ro(t,so)}else Po(t,so)})),Fe=Oe=Be=Le=Ne=ze=je=We=Ie=null,$e=1,Xt(!0),un("setSize"),be=!1),le>0&&se>0&&(p.clearRect(0,0,f.width,f.height),un("drawClear"),E.forEach((function(e){return e()})),un("draw")),Se.show&&Ze&&(Ut(null,!0,!1),Ze=!1),c||(c=!0,o.status=1,un("ready")),Ge=!1,Dt=!1}function Ct(e,n){var r=k[e];if(null==r.from){if(0==Re){var i=r.range(o,n.min,n.max,e);n.min=i[0],n.max=i[1]}if(n.min>n.max){var a=n.min;n.min=n.max,n.max=a}if(Re>1&&null!=n.min&&null!=n.max&&n.max-n.min<1e-16)return;e==C&&2==r.distr&&Re>0&&(n.min=Uo(n.min,t[0]),n.max=Uo(n.max,t[0]),n.min==n.max&&n.max++),O[e]=n,ye=!0,kt()}}o.redraw=function(e,t){xe=t||!1,!1!==e?It(C,R.min,R.max):kt()},o.setScale=Ct;var _t=!1,Et=Se.drag,At=Et.x,Mt=Et.y;Se.show&&(Se.x&&(dt=Bo("u-cursor-x",v)),Se.y&&(ft=Bo("u-cursor-y",v)),0==R.ori?(pt=dt,ht=ft):(pt=ft,ht=dt),Zt=Se.left,wt=Se.top);var Tt,Pt,Rt,Ft=o.select=Vi({show:!0,over:!0,left:0,width:0,top:0,height:0},e.select),Ot=Ft.show?Bo("u-select",Ft.over?v:m):null;function Bt(e,t){if(Ft.show){for(var n in e)Fo(Ot,n,Ft[n]=e[n]);!1!==t&&un("setSelect")}}function It(e,t,n){Ct(e,{min:t,max:n})}function Lt(e,t,n,r){null!=t.focus&&function(e){if(e!=Rt){var t=null==e,n=1!=_e.alpha;w.forEach((function(r,o){var i=t||0==o||o==e;r._focus=t?null:i,n&&function(e,t){w[e].alpha=t,Se.show&&Ae[e]&&(Ae[e].style.opacity=t);V&&X[e]&&(X[e].style.opacity=t)}(o,i?1:_e.alpha)})),Rt=e,n&&kt()}}(e),null!=t.show&&w.forEach((function(n,r){r>0&&(e==r||null==e)&&(n.show=t.show,function(e,t){var n=w[e],r=V?X[e]:null;n.show?r&&Ro(r,so):(r&&Po(r,so),Ae.length>1&&Lo(Ae[e],-10,-10,ce,de))}(r,t.show),It(2==i?n.facets[1].scale:n.scale,null,null),kt())})),!1!==n&&un("setSeries",e,t),r&&dn("setSeries",o,e,t)}o.setSelect=Bt,o.setSeries=Lt,o.addBand=function(e,t){e.fill=Ci(e.fill||null),e.dir=ii(e.dir,-1),t=null==t?S.length:t,S.splice(t,0,e)},o.setBand=function(e,t){Vi(S[e],t)},o.delBand=function(e){null==e?S.length=0:S.splice(e,1)};var Nt={focus:!0};function zt(e,t,n){var r=k[t];n&&(e=e/uo-(1==r.ori?pe:fe));var o=ce;1==r.ori&&(e=(o=de)-e),-1==r.dir&&(e=o-e);var i=r._min,a=i+(r._max-i)*(e/o),u=r.distr;return 3==u?gi(10,a):4==u?function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return si.sinh(e)*t}(a,r.asinh):a}function jt(e,t){Fo(Ot,vo,Ft.left=e),Fo(Ot,fo,Ft.width=t)}function Wt(e,t){Fo(Ot,ho,Ft.top=e),Fo(Ot,po,Ft.height=t)}V&&Ee&&Yo(ko,L,(function(e){Se._lock||null!=Rt&&Lt(null,Nt,!0,ln.setSeries)})),o.valToIdx=function(e){return Uo(e,t[0])},o.posToIdx=function(e,n){return Uo(zt(e,C,n),t[0],Ve,Ue)},o.posToVal=zt,o.valToPos=function(e,t,n){return 0==k[t].ori?u(e,k[t],n?ve:ce,n?he:0):l(e,k[t],n?ge:de,n?me:0)},o.batch=function(e){e(o),kt()},o.setCursor=function(e,t,n){Zt=e.left,wt=e.top,Ut(null,t,n)};var $t=0==R.ori?jt:Wt,Ht=1==R.ori?jt:Wt;function Yt(e,t){if(null!=e){var n=e.idx;Y.idx=n,w.forEach((function(e,t){(t>0||!K)&&Vt(t,n)}))}V&&Y.live&&function(){if(V&&Y.live)for(var e=2==i?1:0;eUe;Tt=wi;var f=0==R.ori?ce:de,p=1==R.ori?ce:de;if(Zt<0||0==Re||d){u=null;for(var h=0;h0&&Ae.length>1&&Lo(Ae[h],-10,-10,ce,de);if(Ee&&Lt(null,Nt,!0,null==e&&ln.setSeries),Y.live){H.fill(null),we=!0;for(var m=0;m0&&b.show){var E=null==S?-10:Pi(P(S,1==i?k[b.scale]:k[b.facets[1].scale],p,0),.5);if(E>0&&1==i){var A=di(E-wt);A<=Tt&&(Tt=A,Pt=y)}var M=void 0,F=void 0;if(0==R.ori?(M=_,F=E):(M=E,F=_),we&&Ae.length>1){zo(Ae[y],Se.points.fill(o,y),Se.points.stroke(o,y));var O=void 0,B=void 0,I=void 0,L=void 0,N=!0,z=Se.points.bbox;if(null!=z){N=!1;var j=z(o,y);I=j.left,L=j.top,O=j.width,B=j.height}else I=M,L=F,O=B=Se.points.size(o,y);Wo(Ae[y],O,B,N),Lo(Ae[y],I,L,ce,de)}}if(Y.live){if(!we||0==y&&K)continue;Vt(y,D)}}}if(Se.idx=u,Se.left=Zt,Se.top=wt,we&&(Y.idx=u,Yt()),Ft.show&&_t)if(null!=e){var W=(0,r.Z)(ln.scales,2),$=W[0],V=W[1],U=(0,r.Z)(ln.match,2),q=U[0],X=U[1],G=(0,r.Z)(e.cursor.sync.scales,2),J=G[0],ee=G[1],te=e.cursor.drag;if(At=te._x,Mt=te._y,At||Mt){var ne,re,oe,ie,ae,ue=e.select,le=ue.left,se=ue.top,fe=ue.width,pe=ue.height,he=e.scales[$].ori,me=e.posToVal,ve=null!=$&&q($,J),ge=null!=V&&X(V,ee);ve&&At?(0==he?(ne=le,re=fe):(ne=se,re=pe),oe=k[$],ie=T(me(ne,J),oe,f,0),ae=T(me(ne+re,J),oe,f,0),$t(mi(ie,ae),di(ae-ie))):$t(0,f),ge&&Mt?(1==he?(ne=le,re=fe):(ne=se,re=pe),oe=k[V],ie=P(me(ne,ee),oe,p,0),ae=P(me(ne+re,ee),oe,p,0),Ht(mi(ie,ae),di(ae-ie))):Ht(0,p)}else Jt()}else{var ye=di(bt-mt),be=di(xt-vt);if(1==R.ori){var xe=ye;ye=be,be=xe}At=Et.x&&ye>=Et.dist,Mt=Et.y&&be>=Et.dist;var Ze,De,ke=Et.uni;null!=ke?At&&Mt&&(Mt=be>=ke,(At=ye>=ke)||Mt||(be>ye?Mt=!0:At=!0)):Et.x&&Et.y&&(At||Mt)&&(At=Mt=!0),At&&(0==R.ori?(Ze=gt,De=Zt):(Ze=yt,De=wt),$t(mi(Ze,De),di(De-Ze)),Mt||Ht(0,p)),Mt&&(1==R.ori?(Ze=gt,De=Zt):(Ze=yt,De=wt),Ht(mi(Ze,De),di(De-Ze)),At||$t(0,f)),At||Mt||($t(0,0),Ht(0,0))}if(Et._x=At,Et._y=Mt,null==e){if(a){if(null!=sn){var Ce=(0,r.Z)(ln.scales,2),Me=Ce[0],Te=Ce[1];ln.values[0]=null!=Me?zt(0==R.ori?Zt:wt,Me):null,ln.values[1]=null!=Te?zt(1==R.ori?Zt:wt,Te):null}dn(xo,o,Zt,wt,ce,de,u)}if(Ee){var Pe=a&&ln.setSeries,Fe=_e.prox;null==Rt?Tt<=Fe&&Lt(Pt,Nt,!0,Pe):Tt>Fe?Lt(null,Nt,!0,Pe):Pt!=Rt&&Lt(Pt,Nt,!0,Pe)}}c&&!1!==n&&un("setCursor")}o.setLegend=Yt;var qt=null;function Xt(e){!0===e?qt=null:un("syncRect",qt=v.getBoundingClientRect())}function Gt(e,t,n,r,o,i,a){Se._lock||(Kt(e,t,n,r,o,i,a,!1,null!=e),null!=e?Ut(null,!0,!0):Ut(t,!0,!1))}function Kt(e,t,n,i,a,u,l,c,d){if(null==qt&&Xt(!1),null!=e)n=e.clientX-qt.left,i=e.clientY-qt.top;else{if(n<0||i<0)return Zt=-10,void(wt=-10);var f=(0,r.Z)(ln.scales,2),p=f[0],h=f[1],m=t.cursor.sync,v=(0,r.Z)(m.values,2),g=v[0],y=v[1],b=(0,r.Z)(m.scales,2),x=b[0],Z=b[1],w=(0,r.Z)(ln.match,2),D=w[0],S=w[1],C=t.axes[0].side%2==1,_=0==R.ori?ce:de,E=1==R.ori?ce:de,A=C?u:a,M=C?a:u,T=C?i:n,P=C?n:i;if(n=null!=x?D(p,x)?s(g,k[p],_,0):-10:_*(T/A),i=null!=Z?S(h,Z)?s(y,k[h],E,0):-10:E*(P/M),1==R.ori){var F=n;n=i,i=F}}if(d&&((n<=1||n>=ce-1)&&(n=ki(n,ce)),(i<=1||i>=de-1)&&(i=ki(i,de))),c){mt=n,vt=i;var O=Se.move(o,n,i),B=(0,r.Z)(O,2);gt=B[0],yt=B[1]}else Zt=n,wt=i}var Qt={width:0,height:0};function Jt(){Bt(Qt,!1)}function en(e,t,n,r,i,a,u){_t=!0,At=Mt=Et._x=Et._y=!1,Kt(e,t,n,r,i,a,0,!0,!1),null!=e&&(ae(wo,Ao,tn),dn(Zo,o,gt,yt,ce,de,null))}function tn(e,t,n,r,i,a,u){_t=Et._x=Et._y=!1,Kt(e,t,n,r,i,a,0,!1,!0);var l=Ft.left,s=Ft.top,c=Ft.width,d=Ft.height,f=c>0||d>0;if(f&&Bt(Ft),Et.setScale&&f){var p=l,h=c,m=s,v=d;if(1==R.ori&&(p=s,h=d,m=l,v=c),At&&It(C,zt(p,C),zt(p+h,C)),Mt)for(var g in k){var y=k[g];g!=C&&null==y.from&&y.min!=wi&&It(g,zt(m+v,g),zt(m,g))}Jt()}else Se.lock&&(Se._lock=!Se._lock,Se._lock||Ut(null,!0,!1));null!=e&&(ue(wo,Ao),dn(wo,o,Zt,wt,ce,de,null))}function nn(e,t,n,r,i,a,u){Qe(),Jt(),null!=e&&dn(So,o,Zt,wt,ce,de,null)}function rn(){D.forEach(tl),De(o.width,o.height,!0)}Yo(_o,Mo,rn);var on={};on.mousedown=en,on.mousemove=Gt,on.mouseup=tn,on.dblclick=nn,on.setSeries=function(e,t,n,r){Lt(n,r,!0,!1)},Se.show&&(ae(Zo,v,en),ae(xo,v,Gt),ae(Do,v,Xt),ae(ko,v,(function(e,t,n,r,o,i,a){if(!Se._lock){var u=_t;if(_t){var l,s,c=!0,d=!0;0==R.ori?(l=At,s=Mt):(l=Mt,s=At),l&&s&&(c=Zt<=10||Zt>=ce-10,d=wt<=10||wt>=de-10),l&&c&&(Zt=Zt=3?ou:Ei)),e.font=el(e.font),e.labelFont=el(e.labelFont),e._size=e.size(o,null,t,0),e._space=e._rotate=e._incrs=e._found=e._splits=e._values=null,e._size>0&&(Te[t]=!0,e._el=Bo("u-axis",h))}})),n?n instanceof HTMLElement?(n.appendChild(d),fn()):n(o,fn):fn(),o}nl.assign=Vi,nl.fmtNum=li,nl.rangeNum=oi,nl.rangeLog=Jo,nl.rangeAsinh=ei,nl.orient=vu,nl.pxRatio=uo,nl.join=function(e,t){for(var n=new Set,r=0;r=i&&E<=a;E+=w){var A=s[E],M=y(f(l[E],c,v,h));if(null!=A){var T=y(p(A,d,g,m));k&&(Zu(D,_,M),k=!1),1==t?b(Z,M,S):b(Z,_,T),b(Z,M,T),S=T,_=M}else null===A&&(Zu(D,_,M),k=!0)}var P=gu(e,o),R=(0,r.Z)(P,2),F=R[0],O=R[1];if(null!=u.fill||0!=F){var B=x.fill=new Path2D(Z),I=y(p(u.fillTo(e,o,u.min,u.max,F),d,g,m));b(B,_,I),b(B,C,I)}x.gaps=D=u.gaps(e,o,i,a,D);var L=u.width*uo/2,N=n||1==t?L:-L,z=n||-1==t?-L:L;return D.forEach((function(e){e[0]+=N,e[1]+=z})),u.spanGaps||(x.clip=xu(D,c.ori,h,m,v,g)),0!=O&&(x.band=2==O?[bu(e,o,i,a,Z,-1),bu(e,o,i,a,Z,1)]:bu(e,o,i,a,Z,O)),x}))}},rl.bars=function(e){var t=ii((e=e||Li).size,[.6,wi,1]),n=e.align||0,o=(e.gap||0)*uo,i=ii(e.radius,0),a=1-t[0],u=ii(t[1],wi)*uo,l=ii(t[2],1)*uo,s=ii(e.disp,Li),c=ii(e.each,(function(e){})),d=s.fill,f=s.stroke;return function(e,t,p,h){return vu(e,t,(function(m,v,g,y,b,x,Z,w,D,k,S){var C,_,E=m.pxRound,A=y.dir*(0==y.ori?1:-1),M=b.dir*(1==b.ori?1:-1),T=0==y.ori?Eu:Au,P=0==y.ori?c:function(e,t,n,r,o,i,a){c(e,t,n,o,r,a,i)},R=gu(e,t),F=(0,r.Z)(R,2),O=F[0],B=F[1],I=3==b.distr?1==O?b.max:b.min:0,L=Z(I,b,S,D),N=E(m.width*uo),z=!1,j=null,W=null,$=null,H=null;null==d||0!=N&&null==f||(z=!0,j=d.values(e,t,p,h),W=new Map,new Set(j).forEach((function(e){null!=e&&W.set(e,new Path2D)})),N>0&&($=f.values(e,t,p,h),H=new Map,new Set($).forEach((function(e){null!=e&&H.set(e,new Path2D)}))));var Y=s.x0,V=s.size;if(null!=Y&&null!=V){v=Y.values(e,t,p,h),2==Y.unit&&(v=v.map((function(t){return e.posToVal(w+t*k,y.key,!0)})));var U=V.values(e,t,p,h);_=E((_=2==V.unit?U[0]*k:x(U[0],y,k,w)-x(0,y,k,w))-N),C=1==A?-N/2:_+N/2}else{var q=k;if(v.length>1)for(var X=null,G=0,K=1/0;G=p&&ae<=h;ae+=A){var ue=g[ae],le=x(2!=y.distr||null!=s?v[ae]:ae,y,k,w),se=Z(ii(ue,I),b,S,D);null!=ie&&null!=ue&&(L=Z(ie[ae],b,S,D));var ce=E(le-C),de=E(vi(se,L)),fe=E(mi(se,L)),pe=de-fe,he=i*_;null!=ue&&(z?(N>0&&null!=$[ae]&&T(H.get($[ae]),ce,fe+fi(N/2),_,vi(0,pe-N),he),null!=j[ae]&&T(W.get(j[ae]),ce,fe+fi(N/2),_,vi(0,pe-N),he)):T(te,ce,fe+fi(N/2),_,vi(0,pe-N),he),P(e,t,ae,ce-N/2,fe,_+N,pe)),0!=B&&(M*B==1?(de=fe,fe=J):(fe=de,de=J),T(ne,ce-N/2,fe,_+N,vi(0,pe=de-fe),0))}return N>0&&(ee.stroke=z?H:te),ee.fill=z?W:te,ee}))}},rl.spline=function(e){return t=Nu,function(e,n,o,i){return vu(e,n,(function(a,u,l,s,c,d,f,p,h,m,v){var g,y,b,x=a.pxRound;0==s.ori?(g=ku,b=Cu,y=Pu):(g=Su,b=_u,y=Ru);var Z=1*s.dir*(0==s.ori?1:-1);o=qo(l,o,i,1),i=qo(l,o,i,-1);for(var w=[],D=!1,k=x(d(u[1==Z?o:i],s,m,p)),S=k,C=[],_=[],E=1==Z?o:i;E>=o&&E<=i;E+=Z){var A=l[E],M=d(u[E],s,m,p);null!=A?(D&&(Zu(w,S,M),D=!1),C.push(S=M),_.push(f(l[E],c,v,h))):null===A&&(Zu(w,S,M),D=!0)}var T={stroke:t(C,_,g,b,y,x),fill:null,clip:null,band:null,gaps:null,flags:1},P=T.stroke,R=gu(e,n),F=(0,r.Z)(R,2),O=F[0],B=F[1];if(null!=a.fill||0!=O){var I=T.fill=new Path2D(P),L=x(f(a.fillTo(e,n,a.min,a.max,O),c,v,h));b(I,S,L),b(I,k,L)}return T.gaps=w=a.gaps(e,n,o,i,w),a.spanGaps||(T.clip=xu(w,s.ori,p,h,m,v)),0!=B&&(T.band=2==B?[bu(e,n,o,i,P,-1),bu(e,n,o,i,P,1)]:bu(e,n,o,i,P,B)),T}))};var t};var ol,il=function(e){if(7!=e.length)return"0, 0, 0";var t=parseInt(e.slice(1,3),16),n=parseInt(e.slice(3,5),16),r=parseInt(e.slice(5,7),16);return"".concat(t,", ").concat(n,", ").concat(r)},al={height:500,legend:{show:!1},cursor:{drag:{x:!1,y:!1},focus:{prox:30},points:{size:5.6,width:1.4},bind:{mouseup:function(){return null},mousedown:function(){return null},click:function(){return null},dblclick:function(){return null},mouseenter:function(){return null}}}},ul=function(e){return void 0===e||null===e?"":e.toLocaleString("en-US",{maximumSignificantDigits:20})},ll=function(e,t,n,r){var o,i=e.axes[n];if(r>1)return i._size||60;var a=6+((null===i||void 0===i||null===(o=i.ticks)||void 0===o?void 0:o.size)||0)+(i.gap||0),u=(null!==t&&void 0!==t?t:[]).reduce((function(e,t){return t.length>e.length?t:e}),"");return""!=u&&(a+=function(e,t){var n=document.createElement("span");n.innerText=e,n.style.cssText="position: absolute; z-index: -1; pointer-events: none; opacity: 0; font: ".concat(t),document.body.appendChild(n);var r=n.offsetWidth;return n.remove(),r}(u,e.ctx.font)),Math.ceil(a)},sl=function(e,t){return function(e){for(var t=0,n=0;n>8*o&255).toString(16)).substr(-2);return r}("".concat(e).concat(t))},cl=function(e){return e<=1?[]:[4*e,1.2*e]},dl=function(e){for(var t=e.length,n=-1/0;t--;){var r=e[t];Number.isFinite(r)&&r>n&&(n=r)}return Number.isFinite(n)?n:null},fl=function(e){for(var t=e.length,n=1/0;t--;){var r=e[t];Number.isFinite(r)&&r2&&void 0!==arguments[2]?arguments[2]:"";return t.map((function(e){return"".concat(ul(e)," ").concat(n)}))}(e,n,t)}};return e?Number(e)%2?n:vn(vn({},n),{},{side:1}):{space:80}}))},hl=function(e,t){if(null==e||null==t)return[-1,1];var n=.02*(Math.abs(t-e)||Math.abs(e)||1);return[e-n,t+n]},ml=function(e){var t,n,r=e.u,o=e.tooltipIdx,i=e.metrics,a=e.series,u=e.tooltip,l=e.tooltipOffset,s=e.unit,c=void 0===s?"":s,d=o.seriesIdx,f=o.dataIdx;if(null!==d&&void 0!==f){var p=r.data[d][f],h=r.data[0][f],m=(null===(t=i[d-1])||void 0===t?void 0:t.metric)||{},v=a[d],g=sl(Number(v.scale||0),v.label||""),y=r.over.getBoundingClientRect(),b=y.width,x=y.height,Z=r.valToPos(p||0,(null===(n=a[d])||void 0===n?void 0:n.scale)||"1"),w=r.valToPos(h,"x"),D=u.getBoundingClientRect(),k=D.width,S=D.height,C=w+k>=b,_=Z+S>=x;u.style.display="grid",u.style.top="".concat(l.top+Z+10-(_?S+10:0),"px"),u.style.left="".concat(l.left+w+10-(C?k+20:0),"px");var E=(v.label||"").replace(/{.+}/gim,""),A=yn()(new Date(1e3*h)).format("YYYY-MM-DD HH:mm:ss:SSS (Z)"),M=Object.keys(m).filter((function(e){return"__name__"!==e})).map((function(e){return"
";throw r}},lk.Parser=uk,lk.parser=uk.parse,lk.Renderer=ok,lk.TextRenderer=ik,lk.Lexer=rk,lk.lexer=rk.lex,lk.Tokenizer=QD,lk.Slugger=ak,lk.parse=lk;lk.options,lk.setOptions,lk.use,lk.walkTokens,lk.parseInline,uk.parse,rk.lex;var sk=function(e){var n=e.title,o=e.description,i=e.unit,a=e.expr,u=e.showLegend,l=e.filename,s=e.alias,c=rr().time.period,d=or(),f=(0,t.useRef)(null),p=(0,t.useState)(!0),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=(0,t.useState)({enable:!1,value:c.step||1}),y=(0,r.Z)(g,2),b=y[0],x=y[1],Z=(0,t.useState)({limits:{enable:!1,range:{1:[0,0]}}}),w=(0,r.Z)(Z,2),D=w[0],k=w[1],S=(0,t.useMemo)((function(){return Array.isArray(a)&&a.every((function(e){return e}))}),[a]),C=zm({predefinedQuery:S?a:[],display:"chart",visible:m,customStep:b}),_=C.isLoading,E=C.graphData,A=C.error,M=function(e){var t=vn({},D);t.limits.range=e,k(t)};return(0,t.useEffect)((function(){var e=new IntersectionObserver((function(e){e.forEach((function(e){return v(e.isIntersecting)}))}),{threshold:.1});return f.current&&e.observe(f.current),function(){f.current&&e.unobserve(f.current)}}),[]),S?(0,ie.BX)(oo,{border:"1px solid",borderRadius:"2px",borderColor:"divider",width:"100%",height:"100%",ref:f,children:[(0,ie.BX)(oo,{px:2,py:1,display:"flex",flexWrap:"wrap",width:"100%",alignItems:"center",justifyContent:"space-between",borderBottom:"1px solid",borderColor:"divider",children:[(0,ie.tZ)(pc,{arrow:!0,componentsProps:{tooltip:{sx:{maxWidth:"100%"}}},title:(0,ie.BX)(oo,{sx:{p:1},children:[o&&(0,ie.BX)(oo,{mb:2,children:[(0,ie.tZ)(am,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Description:"}),(0,ie.tZ)("div",{className:"panelDescription",dangerouslySetInnerHTML:{__html:lk.parse(o)}})]}),(0,ie.BX)(oo,{children:[(0,ie.tZ)(am,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Queries:"}),(0,ie.tZ)("div",{children:a.map((function(e,t){return(0,ie.tZ)(oo,{mb:.5,children:e},"".concat(t,"_").concat(e))}))})]})]}),children:(0,ie.tZ)(kD.Z,{color:"info",sx:{mr:1}})}),(0,ie.tZ)(am,{component:"div",variant:"subtitle1",fontWeight:500,sx:{mr:2,py:1,flexGrow:"1"},children:n||""}),(0,ie.tZ)(oo,{mr:2,py:1,children:(0,ie.tZ)(Am,{defaultStep:c.step,customStepEnable:b.enable,setStep:function(e){return x(vn(vn({},b),{},{value:e}))},toggleEnableStep:function(){return x(vn(vn({},b),{},{enable:!b.enable}))}})}),(0,ie.tZ)(qv,{yaxis:D,setYaxisLimits:M,toggleEnableLimits:function(){var e=vn({},D);e.limits.enable=!e.limits.enable,k(e)}})]}),(0,ie.BX)(oo,{px:2,pb:2,children:[_&&(0,ie.tZ)(pg,{isLoading:!0,height:"500px"}),A&&(0,ie.tZ)(_t,{color:"error",severity:"error",sx:{whiteSpace:"pre-wrap",mt:2},children:A}),E&&(0,ie.tZ)(Zc,{data:E,period:c,customStep:b,query:a,yaxis:D,unit:i,alias:s,showLegend:u,setYaxisLimits:M,setPeriod:function(e){var t=e.from,n=e.to;d({type:"SET_PERIOD",payload:{from:t,to:n}})}})]})]}):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"expr"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:l}),"."]})},ck={position:"absolute",top:0,bottom:0,width:"10px",opacity:0,cursor:"ew-resize"},dk=function(e){var n=e.index,o=e.title,i=e.panels,a=e.filename,u=yl(document.body),l=(0,t.useMemo)((function(){return u.width/12}),[u]),s=(0,t.useState)([]),c=(0,r.Z)(s,2),d=c[0],f=c[1];(0,t.useEffect)((function(){f(i.map((function(e){return e.width||12})))}),[i]);var p=(0,t.useState)({start:0,target:0,enable:!1}),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=function(e){if(m.enable){var t=m.start,n=Math.ceil((t-e.clientX)/l);if(!(Math.abs(n)>=12)){var r=d.map((function(e,t){return e-(t===m.target?n:0)}));f(r)}}},y=function(){v(vn(vn({},m),{},{enable:!1}))};return(0,t.useEffect)((function(){return window.addEventListener("mousemove",g),window.addEventListener("mouseup",y),function(){window.removeEventListener("mousemove",g),window.removeEventListener("mouseup",y)}}),[m]),(0,ie.BX)(sD,{defaultExpanded:!n,sx:{boxShadow:"none"},children:[(0,ie.tZ)(gD,{sx:{px:3,bgcolor:"rgba(227, 242, 253, 0.6)"},"aria-controls":"panel".concat(n,"-content"),id:"panel".concat(n,"-header"),expandIcon:(0,ie.tZ)(DD.Z,{}),children:(0,ie.BX)(oo,{display:"flex",alignItems:"center",width:"100%",children:[o&&(0,ie.tZ)(am,{variant:"h6",fontWeight:"bold",sx:{mr:2},children:o}),i&&(0,ie.BX)(am,{variant:"body2",fontStyle:"italic",children:["(",i.length," panels)"]})]})}),(0,ie.tZ)(wD,{sx:{display:"grid",gridGap:"10px"},children:(0,ie.tZ)(Iy,{container:!0,spacing:2,children:Array.isArray(i)&&i.length?i.map((function(e,t){return(0,ie.tZ)(Iy,{item:!0,xs:d[t],sx:{transition:"200ms"},children:(0,ie.BX)(oo,{position:"relative",height:"100%",children:[(0,ie.tZ)(sk,{title:e.title,description:e.description,unit:e.unit,expr:e.expr,alias:e.alias,filename:a,showLegend:e.showLegend}),(0,ie.tZ)("button",{style:vn(vn({},ck),{},{right:0}),onMouseDown:function(e){return function(e,t){v({start:e.clientX,target:t,enable:!0})}(e,t)}})]})},t)})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"panels"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:a}),"."]})})})]})},fk=function(){var e=(0,t.useState)(),n=(0,r.Z)(e,2),o=n[0],i=n[1],a=(0,t.useState)(0),u=(0,r.Z)(a,2),l=u[0],s=u[1],c=(0,t.useMemo)((function(){return Cn()(o,[l,"filename"],"")}),[o,l]),d=(0,t.useMemo)((function(){return Cn()(o,[l,"rows"],[])}),[o,l]);return(0,t.useEffect)((function(){Yw().then((function(e){return e.length&&i(e)}))}),[]),(0,ie.BX)(ie.HY,{children:[!o&&(0,ie.tZ)(_t,{color:"info",severity:"info",sx:{m:4},children:"Dashboards not found"}),o&&(0,ie.BX)(ie.HY,{children:[(0,ie.tZ)(oo,{sx:{borderBottom:1,borderColor:"divider"},children:(0,ie.tZ)(Tv,{value:l,onChange:function(e,t){return s(t)},"aria-label":"dashboard-tabs",children:o&&o.map((function(e,t){return(0,ie.tZ)(Lv,{label:e.title||e.filename,id:"tab-".concat(t),"aria-controls":"tabpanel-".concat(t)},t)}))})}),(0,ie.tZ)(oo,{children:Array.isArray(d)&&d.length?d.map((function(e,t){return(0,ie.tZ)(dk,{index:t,filename:c,title:e.title,panels:e.panels},"".concat(l,"_").concat(t))})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"rows"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:c}),"."]})})]})]})},pk=function(){return(0,ie.BX)(ie.HY,{children:[(0,ie.tZ)(Br,{})," ",(0,ie.BX)(Lr,{dateAdapter:Vr,children:[" ",(0,ie.tZ)(Sr,{injectFirst:!0,children:(0,ie.BX)(Pr,{theme:Dr,children:[" ",(0,ie.BX)(ar,{children:[" ",(0,ie.BX)(mr,{children:[" ",(0,ie.BX)(Zr,{children:[" ",(0,ie.BX)(hn,{children:[" ",(0,ie.tZ)(V,{children:(0,ie.tZ)(j,{children:(0,ie.BX)(N,{path:"/",element:(0,ie.tZ)($w,{}),children:[(0,ie.tZ)(N,{path:Ur,element:(0,ie.tZ)(hg,{})}),(0,ie.tZ)(N,{path:qr,element:(0,ie.tZ)(fk,{})})]})})})]})]})]})]})]})})]})]})},hk=function(e){e&&e instanceof Function&&n.e(27).then(n.bind(n,4027)).then((function(t){var n=t.getCLS,r=t.getFID,o=t.getFCP,i=t.getLCP,a=t.getTTFB;n(e),r(e),o(e),i(e),a(e)}))},mk=document.getElementById("root");mk&&(0,t.render)((0,ie.tZ)(pk,{}),mk),hk()}()}();
\ No newline at end of file
diff --git a/app/vmselect/vmui/static/media/README.40ebc3a1f4adae949154.md b/app/vmui/packages/vmui/public/dashboards/README.md
similarity index 93%
rename from app/vmselect/vmui/static/media/README.40ebc3a1f4adae949154.md
rename to app/vmui/packages/vmui/public/dashboards/README.md
index 7fd86af708..655b7cc23c 100644
--- a/app/vmselect/vmui/static/media/README.40ebc3a1f4adae949154.md
+++ b/app/vmui/packages/vmui/public/dashboards/README.md
@@ -1,3 +1,8 @@
+### Setup
+1. Create `.json` config file in a folder `dashboards`
+2. Import your config file into the `dashboards/index.js`
+3. Add imported variable into the array `window.__VMUI_PREDEFINED_DASHBOARDS__`
+
### Configuration options
diff --git a/app/vmui/packages/vmui/public/dashboards/index.js b/app/vmui/packages/vmui/public/dashboards/index.js
new file mode 100644
index 0000000000..403467fe3c
--- /dev/null
+++ b/app/vmui/packages/vmui/public/dashboards/index.js
@@ -0,0 +1,5 @@
+import perJob from "./perJobUsage.json" assert { type: "json" };
+
+window.__VMUI_PREDEFINED_DASHBOARDS__ = [
+ perJob
+];
diff --git a/app/vmui/packages/vmui/public/dashboards/perJobUsage.json b/app/vmui/packages/vmui/public/dashboards/perJobUsage.json
new file mode 100644
index 0000000000..6d134a3bea
--- /dev/null
+++ b/app/vmui/packages/vmui/public/dashboards/perJobUsage.json
@@ -0,0 +1,29 @@
+{
+ "title": "per-job resource usage",
+ "rows": [
+ {
+ "panels": [
+ {
+ "title": "Per-job CPU usage",
+ "width": 6,
+ "expr": ["sum(rate(process_cpu_seconds_total)) by (job)"]
+ },
+ {
+ "title": "Per-job RSS usage",
+ "width": 6,
+ "expr": ["sum(process_resident_memory_bytes) by (job)"]
+ },
+ {
+ "title": "Per-job disk read",
+ "width": 6,
+ "expr": ["sum(rate(process_io_storage_read_bytes_total)) by (job)"]
+ },
+ {
+ "title": "Per-job disk write",
+ "width": 6,
+ "expr": ["sum(rate(process_io_storage_written_bytes_total)) by (job)"]
+ }
+ ]
+ }
+ ]
+}
diff --git a/app/vmui/packages/vmui/public/index.html b/app/vmui/packages/vmui/public/index.html
index 144f260e30..7ee3279d10 100644
--- a/app/vmui/packages/vmui/public/index.html
+++ b/app/vmui/packages/vmui/public/index.html
@@ -27,6 +27,7 @@
-->
VM UI
+
diff --git a/app/vmui/packages/vmui/src/components/PredefinedPanels/DashboardsLayout.tsx b/app/vmui/packages/vmui/src/components/PredefinedPanels/DashboardsLayout.tsx
index 9cb3e03156..e0021beccb 100644
--- a/app/vmui/packages/vmui/src/components/PredefinedPanels/DashboardsLayout.tsx
+++ b/app/vmui/packages/vmui/src/components/PredefinedPanels/DashboardsLayout.tsx
@@ -20,7 +20,7 @@ const DashboardLayout: FC = () => {
}, [dashboards, tab]);
useEffect(() => {
- getDashboardSettings().then(d => d.length && setDashboards(d));
+ setDashboards(getDashboardSettings());
}, []);
return <>
diff --git a/app/vmui/packages/vmui/src/components/PredefinedPanels/getDashboardSettings.ts b/app/vmui/packages/vmui/src/components/PredefinedPanels/getDashboardSettings.ts
index 5f024fadb7..8e7c99404b 100755
--- a/app/vmui/packages/vmui/src/components/PredefinedPanels/getDashboardSettings.ts
+++ b/app/vmui/packages/vmui/src/components/PredefinedPanels/getDashboardSettings.ts
@@ -1,14 +1,6 @@
import {DashboardSettings} from "../../types";
-const importModule = async (filename: string) => {
- const module = await import(`../../dashboards/${filename}`);
- module.default.filename = filename;
- return module.default as DashboardSettings;
-};
-
-export default async () => {
- const context = require.context("../../dashboards", true, /\.json$/);
- const filenames = context.keys().map(r => r.replace("./", ""));
- return await Promise.all(filenames.map(async f => importModule(f)));
+export default (): DashboardSettings[] => {
+ return window.__VMUI_PREDEFINED_DASHBOARDS__ || [];
};
diff --git a/app/vmui/packages/vmui/src/types/index.ts b/app/vmui/packages/vmui/src/types/index.ts
index 8490086923..ad5ab0ba88 100644
--- a/app/vmui/packages/vmui/src/types/index.ts
+++ b/app/vmui/packages/vmui/src/types/index.ts
@@ -1,5 +1,11 @@
import {MetricBase} from "../api/types";
+declare global {
+ interface Window {
+ __VMUI_PREDEFINED_DASHBOARDS__: DashboardSettings[];
+ }
+}
+
export interface TimeParams {
start: number; // timestamp in seconds
end: number; // timestamp in seconds
From 4e6b483ef157a708117fd8fa9342a6d1ce3fe856 Mon Sep 17 00:00:00 2001
From: Yury Molodov
Date: Mon, 16 May 2022 10:44:13 +0300
Subject: [PATCH 33/51] fix: change get display type (#2553)
---
.../CustomPanel/Configurator/DisplayTypeSwitch.tsx | 10 +++++-----
app/vmui/packages/vmui/src/state/common/reducer.ts | 6 ++++--
2 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/app/vmui/packages/vmui/src/components/CustomPanel/Configurator/DisplayTypeSwitch.tsx b/app/vmui/packages/vmui/src/components/CustomPanel/Configurator/DisplayTypeSwitch.tsx
index 920d03a654..742d029277 100644
--- a/app/vmui/packages/vmui/src/components/CustomPanel/Configurator/DisplayTypeSwitch.tsx
+++ b/app/vmui/packages/vmui/src/components/CustomPanel/Configurator/DisplayTypeSwitch.tsx
@@ -9,10 +9,10 @@ import {SyntheticEvent} from "react";
export type DisplayType = "table" | "chart" | "code";
-const tabs = [
- {value: "chart", icon: , label: "Graph"},
+export const displayTypeTabs = [
+ {value: "chart", icon: , label: "Graph", prometheusCode: 0},
{value: "code", icon: , label: "JSON"},
- {value: "table", icon: , label: "Table"}
+ {value: "table", icon: , label: "Table", prometheusCode: 1}
];
export const DisplayTypeSwitch: FC = () => {
@@ -29,7 +29,7 @@ export const DisplayTypeSwitch: FC = () => {
onChange={handleChange}
sx={{minHeight: "0", marginBottom: "-1px"}}
>
- {tabs.map(t =>
+ {displayTypeTabs.map(t =>
{
sx={{minHeight: "41px"}}
/>)}
;
-};
\ No newline at end of file
+};
diff --git a/app/vmui/packages/vmui/src/state/common/reducer.ts b/app/vmui/packages/vmui/src/state/common/reducer.ts
index 47a08bf9a6..2df89c85b2 100644
--- a/app/vmui/packages/vmui/src/state/common/reducer.ts
+++ b/app/vmui/packages/vmui/src/state/common/reducer.ts
@@ -1,5 +1,5 @@
/* eslint max-lines: 0 */
-import {DisplayType} from "../../components/CustomPanel/Configurator/DisplayTypeSwitch";
+import {DisplayType, displayTypeTabs} from "../../components/CustomPanel/Configurator/DisplayTypeSwitch";
import {TimeParams, TimePeriod} from "../../types";
import {
dateFromSeconds,
@@ -62,10 +62,12 @@ const {duration, endInput, relativeTimeId} = getRelativeTime({
defaultEndInput: new Date(formatDateToLocal(getQueryStringValue("g0.end_input", getDateNowUTC()) as Date)),
});
const query = getQueryArray();
+const queryTab = getQueryStringValue("g0.tab", 0);
+const displayType = displayTypeTabs.find(t => t.prometheusCode === queryTab || t.value === queryTab);
export const initialState: AppState = {
serverUrl: getDefaultServer(),
- displayType: getQueryStringValue("g0.tab", "chart") as DisplayType || "chart",
+ displayType: (displayType?.value || "chart") as DisplayType,
query: query, // demo_memory_usage_bytes
queryHistory: query.map(q => ({index: 0, values: [q]})),
time: {
From b74c001c9223397ca24be3c52ebc3885d586bdc3 Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Mon, 16 May 2022 10:00:24 +0200
Subject: [PATCH 34/51] vmalert: support `/rules` path for Grafana's ngalert
requests (#2593)
Unexpectedly, Grafana makes an extra request to `/rules`
handler in addition to `/api/v1/rules` calls in alerts UI.
This happens only for Grafana versions older than 8.5.*.
Apparently, this is related to support of other monitoring
systems.
Prometheus responds with `text/html` content for UI page `/rules`
to such requests. Actually, returning just a blank page with
SC=200 works as well.
Returning actual response of `/api/v1/rules`
results in error in Grafana since it expects a `yaml` (?) in response.
So we add a placeholder to `vmalert`.
https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2583
Signed-off-by: hagen1778
---
app/vmalert/web.go | 2 +-
docs/CHANGELOG.md | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/app/vmalert/web.go b/app/vmalert/web.go
index ef59a89f0c..1dd98ae81f 100644
--- a/app/vmalert/web.go
+++ b/app/vmalert/web.go
@@ -69,7 +69,7 @@ func (rh *requestHandler) handler(w http.ResponseWriter, r *http.Request) bool {
case "/alerts":
WriteListAlerts(w, pathPrefix, rh.groupAlerts())
return true
- case "/groups":
+ case "/groups", "/rules":
WriteListGroups(w, rh.groups())
return true
case "/notifiers":
diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md
index e99366b3c7..341370a65f 100644
--- a/docs/CHANGELOG.md
+++ b/docs/CHANGELOG.md
@@ -18,6 +18,7 @@ The following tip changes can be tested by building VictoriaMetrics components f
* FEATURE: [vmalert](https://docs.victoriametrics.com/vmalert.html): support [reusable templates](https://prometheus.io/docs/prometheus/latest/configuration/template_examples/#defining-reusable-templates) for rules annotations. The path to the template files can be specified via `-rule.templates` flag. See more about this feature [here](https://docs.victoriametrics.com/vmalert.html#reusable-templates). Thanks to @AndrewChubatiuk for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2532).
* FEATURE: [vmctl](https://docs.victoriametrics.com/vmctl.html): add `influx-prometheus-mode` command-line flag, which allows to restore the original time series written from Prometheus into InfluxDB during data migration from InfluxDB to VictoriaMetrics. See [this feature request](https://github.com/VictoriaMetrics/vmctl/issues/8). Thanks to @mback2k for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/2545).
+* BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): proxy `/rules` requests to vmalert from Grafana's alerting UI. This removes errors in Grafana's UI for Grafana versions older than 8.5.*. See https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2583.
* BUGFIX: [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html): do not return values from [label_value()](https://docs.victoriametrics.com/MetricsQL.html#label_value) function if the original time series has no values at the selected timestamps.
* BUGFIX: [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html): limit the number of concurrently established connections from vmselect to vmstorage. This should prevent from potentially high spikes in the number of established connections after temporary slowdown in connection handshake procedure between vmselect and vmstorage because of spikes in workload. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/2552).
* BUGFIX: [vmctl](https://docs.victoriametrics.com/vmctl.html): fix build for Solaris / SmartOS. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/1322#issuecomment-1120276146).
From fcf4190d0ba80d15dbc0c33ccf3f3ce00283958b Mon Sep 17 00:00:00 2001
From: Yury Molodov
Date: Tue, 17 May 2022 14:13:15 +0300
Subject: [PATCH 35/51] vmui: add option to customize url params for individual
pages (#2582)
---
app/vmui/packages/vmui/src/App.tsx | 34 ++++++++--------
.../vmui/src/state/common/StateContext.tsx | 4 +-
.../packages/vmui/src/utils/query-string.ts | 40 ++++++++++++++++---
3 files changed, 54 insertions(+), 24 deletions(-)
diff --git a/app/vmui/packages/vmui/src/App.tsx b/app/vmui/packages/vmui/src/App.tsx
index 5c1731a9dd..012c16f3ba 100644
--- a/app/vmui/packages/vmui/src/App.tsx
+++ b/app/vmui/packages/vmui/src/App.tsx
@@ -19,29 +19,29 @@ import DashboardsLayout from "./components/PredefinedPanels/DashboardsLayout";
const App: FC = () => {
return <>
- {/* CSS Baseline: kind of normalize.css made by materialUI team - can be scoped */}
- {/* Allows datepicker to work with DayJS */}
-
- {/* Material UI theme customization */}
- {/* Serialized into query string, common app settings */}
- {/* Auth related info - optionally persisted to Local Storage */}
- {/* Graph settings */}
- {/* Display various snackbars */}
-
+
+ {/* CSS Baseline: kind of normalize.css made by materialUI team - can be scoped */}
+ {/* Allows datepicker to work with DayJS */}
+
+ {/* Material UI theme customization */}
+ {/* Serialized into query string, common app settings */}
+ {/* Auth related info - optionally persisted to Local Storage */}
+ {/* Graph settings */}
+ {/* Display various snackbars */}
}>
}/>
}/>
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
>;
};
diff --git a/app/vmui/packages/vmui/src/state/common/StateContext.tsx b/app/vmui/packages/vmui/src/state/common/StateContext.tsx
index c8e515dc27..4ff8972152 100644
--- a/app/vmui/packages/vmui/src/state/common/StateContext.tsx
+++ b/app/vmui/packages/vmui/src/state/common/StateContext.tsx
@@ -2,6 +2,7 @@ import React, {createContext, FC, useContext, useEffect, useMemo, useReducer} fr
import {Action, AppState, initialState, reducer} from "./reducer";
import {getQueryStringValue, setQueryStringValue} from "../../utils/query-string";
import {Dispatch} from "react";
+import {useLocation} from "react-router-dom";
type StateContextType = { state: AppState, dispatch: Dispatch };
@@ -17,12 +18,13 @@ export const initialPrepopulatedState = Object.entries(initialState)
}), {}) as AppState;
export const StateProvider: FC = ({children}) => {
+ const location = useLocation();
const [state, dispatch] = useReducer(reducer, initialPrepopulatedState);
useEffect(() => {
setQueryStringValue(state as unknown as Record);
- }, [state]);
+ }, [state, location]);
const contextValue = useMemo(() => {
return { state, dispatch };
diff --git a/app/vmui/packages/vmui/src/utils/query-string.ts b/app/vmui/packages/vmui/src/utils/query-string.ts
index 5d407c2c3f..afb928a629 100644
--- a/app/vmui/packages/vmui/src/utils/query-string.ts
+++ b/app/vmui/packages/vmui/src/utils/query-string.ts
@@ -1,12 +1,18 @@
import qs from "qs";
import get from "lodash.get";
+import router from "../router";
-const stateToUrlParams = {
+const graphStateToUrlParams = {
"time.duration": "range_input",
"time.period.date": "end_input",
"time.period.step": "step_input",
"time.relativeTime": "relative_time",
- "displayType": "tab"
+ "displayType": "tab",
+};
+
+const stateToUrlParams = {
+ [router.home]: graphStateToUrlParams,
+ [router.dashboards]: graphStateToUrlParams,
};
// TODO need function for detect types.
@@ -32,14 +38,23 @@ const stateToUrlParams = {
export const setQueryStringWithoutPageReload = (qsValue: string): void => {
const w = window;
if (w) {
- const newurl = `${w.location.protocol}//${w.location.host}${w.location.pathname}?${qsValue}${w.location.hash}`;
+ const qs = qsValue ? `?${qsValue}` : "";
+ const newurl = `${w.location.protocol}//${w.location.host}${w.location.pathname}${qs}${w.location.hash}`;
w.history.pushState({ path: newurl }, "", newurl);
}
};
export const setQueryStringValue = (newValue: Record): void => {
- const queryMap = new Map(Object.entries(stateToUrlParams));
- const query = get(newValue, "query", "") as string[];
+ const route = window.location.hash.replace("#", "");
+ const params = stateToUrlParams[route] || {};
+ const queryMap = new Map(Object.entries(params));
+ const isGraphRoute = route === router.home || route === router.dashboards;
+ const newQsValue = isGraphRoute ? getGraphQsValue(newValue, queryMap) : getQsValue(newValue, queryMap);
+ setQueryStringWithoutPageReload(newQsValue.join("&"));
+};
+
+const getGraphQsValue = (newValue: Record, queryMap: Map): string[] => {
+ const query = get(newValue, "query", []) as string[];
const newQsValue: string[] = [];
query.forEach((q, i) => {
queryMap.forEach((queryKey, stateKey) => {
@@ -52,7 +67,20 @@ export const setQueryStringValue = (newValue: Record): void =>
newQsValue.push(`g${i}.expr=${encodeURIComponent(q)}`);
});
- setQueryStringWithoutPageReload(newQsValue.join("&"));
+ return newQsValue;
+};
+
+const getQsValue = (newValue: Record, queryMap: Map): string[] => {
+ const newQsValue: string[] = [];
+ queryMap.forEach((queryKey, stateKey) => {
+ const value = get(newValue, stateKey, "") as string;
+ if (value) {
+ const valueEncoded = encodeURIComponent(value);
+ newQsValue.push(`${queryKey}=${valueEncoded}`);
+ }
+ });
+
+ return newQsValue;
};
export const getQueryStringValue = (
From c97c1fc1bf1f47de82f1a8ed03eb45c6c2ffbbcf Mon Sep 17 00:00:00 2001
From: Yury Molodov
Date: Tue, 17 May 2022 14:13:45 +0300
Subject: [PATCH 36/51] vmui: optimize data fetching (#2584)
---
app/vmui/packages/vmui/src/hooks/useFetchQuery.ts | 7 +++++--
app/vmui/packages/vmui/src/hooks/usePrevious.ts | 10 ++++++++++
app/vmui/packages/vmui/src/utils/array.ts | 4 ++++
3 files changed, 19 insertions(+), 2 deletions(-)
create mode 100644 app/vmui/packages/vmui/src/hooks/usePrevious.ts
create mode 100644 app/vmui/packages/vmui/src/utils/array.ts
diff --git a/app/vmui/packages/vmui/src/hooks/useFetchQuery.ts b/app/vmui/packages/vmui/src/hooks/useFetchQuery.ts
index 754aeffb55..bd6cd69e12 100644
--- a/app/vmui/packages/vmui/src/hooks/useFetchQuery.ts
+++ b/app/vmui/packages/vmui/src/hooks/useFetchQuery.ts
@@ -8,6 +8,8 @@ import {getAppModeEnable, getAppModeParams} from "../utils/app-mode";
import throttle from "lodash.throttle";
import {DisplayType} from "../components/CustomPanel/Configurator/DisplayTypeSwitch";
import {CustomStep} from "../state/graph/reducer";
+import usePrevious from "./usePrevious";
+import {arrayEquals} from "../utils/array";
interface FetchQueryParams {
predefinedQuery?: string[]
@@ -48,7 +50,6 @@ export const useFetchQuery = ({predefinedQuery, visible, display, customStep}: F
const controller = new AbortController();
setFetchQueue([...fetchQueue, controller]);
setIsLoading(true);
-
try {
const responses = await Promise.all(fetchUrl.map(url => fetch(url, {signal: controller.signal})));
const tempData = [];
@@ -114,12 +115,14 @@ export const useFetchQuery = ({predefinedQuery, visible, display, customStep}: F
},
[serverUrl, period, displayType, customStep]);
+ const prevFetchUrl = usePrevious(fetchUrl);
+
useEffect(() => {
fetchOptions();
}, [serverUrl]);
useEffect(() => {
- if (!visible) return;
+ if (!visible || (fetchUrl && prevFetchUrl && arrayEquals(fetchUrl, prevFetchUrl))) return;
throttledFetchData(fetchUrl, fetchQueue, (display || displayType));
}, [fetchUrl, visible]);
diff --git a/app/vmui/packages/vmui/src/hooks/usePrevious.ts b/app/vmui/packages/vmui/src/hooks/usePrevious.ts
new file mode 100644
index 0000000000..59975fb433
--- /dev/null
+++ b/app/vmui/packages/vmui/src/hooks/usePrevious.ts
@@ -0,0 +1,10 @@
+import { useRef, useEffect } from "react";
+
+export default (value: any) => {
+ const ref = useRef();
+ useEffect(() => {
+ ref.current = value;
+ }, [value]);
+
+ return ref.current;
+};
diff --git a/app/vmui/packages/vmui/src/utils/array.ts b/app/vmui/packages/vmui/src/utils/array.ts
new file mode 100644
index 0000000000..7b4b7881c7
--- /dev/null
+++ b/app/vmui/packages/vmui/src/utils/array.ts
@@ -0,0 +1,4 @@
+export const arrayEquals = (a: (string|number)[], b: (string|number)[]) => {
+ return a.length === b.length && a.every((val, index) => val === b[index]);
+};
+
From baf1ec46390263eed996e80a5ecd34dec3789fe7 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Tue, 17 May 2022 13:14:30 +0200
Subject: [PATCH 37/51] build(deps): bump github.com/influxdata/influxdb from
1.9.6 to 1.9.7 (#2589)
Bumps [github.com/influxdata/influxdb](https://github.com/influxdata/influxdb) from 1.9.6 to 1.9.7.
- [Release notes](https://github.com/influxdata/influxdb/releases)
- [Changelog](https://github.com/influxdata/influxdb/blob/master/CHANGELOG_OLD.md)
- [Commits](https://github.com/influxdata/influxdb/commits)
---
updated-dependencies:
- dependency-name: github.com/influxdata/influxdb
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot]
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
---
go.mod | 2 +-
go.sum | 156 +++++++++++++++++++++++++++++++++++++++++----
vendor/modules.txt | 2 +-
3 files changed, 147 insertions(+), 13 deletions(-)
diff --git a/go.mod b/go.mod
index 605aaa3fed..9d5d33dd68 100644
--- a/go.mod
+++ b/go.mod
@@ -19,7 +19,7 @@ require (
// See https://github.com/cheggaaa/pb/pull/192#issuecomment-1121285954 for details.
github.com/dmitryk-dk/pb/v3 v3.0.9
github.com/golang/snappy v0.0.4
- github.com/influxdata/influxdb v1.9.6
+ github.com/influxdata/influxdb v1.9.7
github.com/klauspost/compress v1.15.3
github.com/prometheus/prometheus v1.8.2-0.20201119142752-3ad25a6dc3d9
github.com/urfave/cli/v2 v2.6.0
diff --git a/go.sum b/go.sum
index 416971a242..a44233d28c 100644
--- a/go.sum
+++ b/go.sum
@@ -63,8 +63,12 @@ cloud.google.com/go/storage v1.22.0 h1:NUV0NNp9nkBuW66BFRLuMgldN60C57ET3dhbwLIYi
cloud.google.com/go/storage v1.22.0/go.mod h1:GbaLEoMqbVm6sx3Z0R++gSiBlgMv6yUi2q1DeGFKQgE=
collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE=
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
+dmitri.shuralyov.com/gpu/mtl v0.0.0-20201218220906-28db891af037/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
+gioui.org v0.0.0-20210308172011-57750fc8a0a6/go.mod h1:RSH6KIUZ0p2xy5zHDxgAM4zumjgTw83q2ge/PI+yyw8=
+github.com/Azure/azure-pipeline-go v0.2.3/go.mod h1:x841ezTBIMG6O3lAcl8ATHnsOPVl2bqk7S3ta6S6u4k=
github.com/Azure/azure-sdk-for-go v41.3.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
github.com/Azure/azure-sdk-for-go v48.2.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
+github.com/Azure/azure-storage-blob-go v0.14.0/go.mod h1:SMqIBi+SuiQH32bvyjngEewEeXoPfKMgWlBDaYf6fck=
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8=
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
github.com/Azure/go-autorest/autorest v0.9.0/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+BFDTQ8rEZB0s4Yfa6bI=
@@ -76,6 +80,7 @@ github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEg
github.com/Azure/go-autorest/autorest/adal v0.8.2/go.mod h1:ZjhuQClTqx435SRJ2iMlOxPYt3d2C/T/7TiQCVZSn3Q=
github.com/Azure/go-autorest/autorest/adal v0.8.3/go.mod h1:ZjhuQClTqx435SRJ2iMlOxPYt3d2C/T/7TiQCVZSn3Q=
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
+github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
github.com/Azure/go-autorest/autorest/azure/auth v0.5.3/go.mod h1:4bJZhUhcq8LB20TruwHbAQsmUs2Xh+QR7utuJpLXX3A=
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2/go.mod h1:7qkJkT+j6b+hIpzMOwPChJhTqS8VbsqqgULzMNRugoM=
github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
@@ -89,6 +94,7 @@ github.com/Azure/go-autorest/autorest/to v0.3.0/go.mod h1:MgwOyqaIuKdG4TL/2ywSsI
github.com/Azure/go-autorest/autorest/validation v0.2.0/go.mod h1:3EEqHnBxQGHXRYq3HT1WyXAvT7LLY3tl70hw6tQIbjI=
github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
@@ -100,6 +106,7 @@ github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3
github.com/HdrHistogram/hdrhistogram-go v0.9.0/go.mod h1:nxrse8/Tzg2tg3DZcZjm6qEclQKK70g0KxO61gFFZD4=
github.com/HdrHistogram/hdrhistogram-go v1.1.0/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo=
github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo=
+github.com/JohnCGriffin/overflow v0.0.0-20211019200055-46fa312c352c/go.mod h1:X0CRv0ky0k6m906ixxpzmDRLvX58TFUKS2eePweuyxk=
github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0=
github.com/Masterminds/semver v1.4.2/go.mod h1:MB6lktGJrhw8PrUyiEoblNEGEQ+RzHPF078ddwwvV3Y=
github.com/Masterminds/sprig v2.16.0+incompatible/go.mod h1:y6hNFY5UBTIWBxnzTeuNhlNS5hqE0NB0E6fgfo2Br3o=
@@ -143,11 +150,13 @@ github.com/antihax/optional v0.0.0-20180407024304-ca021399b1a6/go.mod h1:V8iCPQY
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
github.com/aokoli/goutils v1.0.1/go.mod h1:SijmP0QR8LtwsmDs8Yii5Z/S4trXFGFC2oO5g9DP+DQ=
github.com/apache/arrow/go/arrow v0.0.0-20191024131854-af6fa24be0db/go.mod h1:VTxUBvSJ3s3eHAg65PNgrsn5BtqCRPdmyXh6rAfdxN0=
-github.com/apache/arrow/go/arrow v0.0.0-20200601151325-b2287a20f230/go.mod h1:QNYViu/X0HXDHw7m3KXzWSVXIbfUvJqBFe6Gj8/pYA0=
-github.com/apache/arrow/go/arrow v0.0.0-20210722123801-4591d76fce28/go.mod h1:2qMFB56yOP3KzkB3PbYZ4AlUFg3a88F67TIx5lB/WwY=
+github.com/apache/arrow/go/arrow v0.0.0-20211112161151-bc219186db40/go.mod h1:Q7yQnSMnLvcXlZ8RV+jwz/6y1rQTqbX6C82SndT52Zs=
+github.com/apache/arrow/go/v7 v7.0.0/go.mod h1:vG2y+fH8mEUcX29tM6hOULGE06/XqEI8sG5fANM6T5w=
github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
+github.com/apache/thrift v0.15.0/go.mod h1:PHK3hniurgQaNMZYaCLEqXKsYK8upmhPbmdP2FXSqgU=
github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o=
+github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY=
github.com/armon/go-metrics v0.3.3/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
github.com/armon/go-metrics v0.3.9/go.mod h1:4O98XIr/9W0sxpJ8UaYkvjk10Iff7SnFrb4QAOwNTFc=
@@ -170,8 +179,24 @@ github.com/aws/aws-sdk-go v1.44.9 h1:s3lsEFbc8i7ghQmcEpcdyvoO/WMwyCVa9pUq3Lq//Ok
github.com/aws/aws-sdk-go v1.44.9/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo=
github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g=
github.com/aws/aws-sdk-go-v2 v1.9.1/go.mod h1:cK/D0BBs0b/oWPIcX/Z/obahJK1TT7IPVjy53i/mX/4=
+github.com/aws/aws-sdk-go-v2 v1.11.0/go.mod h1:SQfA+m2ltnu1cA0soUkj4dRSsmITiVQUJvBIZjzfPyQ=
+github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.0.0/go.mod h1:Xn6sxgRuIDflLRJFj5Ev7UxABIkNbccFPV/p8itDReM=
+github.com/aws/aws-sdk-go-v2/config v1.10.1/go.mod h1:auIv5pIIn3jIBHNRcVQcsczn6Pfa6Dyv80Fai0ueoJU=
+github.com/aws/aws-sdk-go-v2/credentials v1.6.1/go.mod h1:QyvQk1IYTqBWSi1T6UgT/W8DMxBVa5pVuLFSRLLhGf8=
+github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.8.0/go.mod h1:5E1J3/TTYy6z909QNR0QnXGBpfESYGDqd3O0zqONghU=
+github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.7.1/go.mod h1:wN/mvkow08GauDwJ70jnzJ1e+hE+Q3Q7TwpYLXOe9oI=
+github.com/aws/aws-sdk-go-v2/internal/configsources v1.1.0/go.mod h1:NO3Q5ZTTQtO2xIg2+xTXYDiT7knSejfeDm7WGDaOo0U=
+github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.0.0/go.mod h1:anlUzBoEWglcUxUQwZA7HQOEVEnQALVZsizAapB2hq8=
+github.com/aws/aws-sdk-go-v2/internal/ini v1.3.0/go.mod h1:6oXGy4GLpypD3uCh8wcqztigGgmhLToMfjavgh+VySg=
github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.8.1/go.mod h1:CM+19rL1+4dFWnOQKwDc7H1KwXTz+h61oUSHyhV0b3o=
+github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.5.0/go.mod h1:80NaCIH9YU3rzTTs/J/ECATjXuRqzo/wB6ukO6MZ0XY=
+github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.5.0/go.mod h1:Mq6AEc+oEjCUlBuLiK5YwW4shSOAKCQ3tXN0sQeYoBA=
+github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.9.0/go.mod h1:xKCZ4YFSF2s4Hnb/J0TLeOsKuGzICzcElaOKNGrVnx4=
+github.com/aws/aws-sdk-go-v2/service/s3 v1.19.0/go.mod h1:Gwz3aVctJe6mUY9T//bcALArPUaFmNAy2rTB9qN4No8=
+github.com/aws/aws-sdk-go-v2/service/sso v1.6.0/go.mod h1:Q/l0ON1annSU+mc0JybDy1Gy6dnJxIcWjphO6qJPzvM=
+github.com/aws/aws-sdk-go-v2/service/sts v1.10.0/go.mod h1:jLKCFqS+1T4i7HDqCP9GM4Uk75YW1cS0o82LdxpMyOE=
github.com/aws/smithy-go v1.8.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
+github.com/aws/smithy-go v1.9.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E=
github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA=
github.com/benbjohnson/immutable v0.3.0/go.mod h1:uc6OHo6PN2++n98KHLxW8ef4W42ylHiQSENghE1ezxI=
github.com/benbjohnson/tmpl v1.0.0/go.mod h1:igT620JFIi44B6awvU9IsDhR77IXWtFigTLil/RPdps=
@@ -183,6 +208,7 @@ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kB
github.com/bmizerany/pat v0.0.0-20170815010413-6226ea591a40/go.mod h1:8rLXio+WjiTceGBHIoTvn60HIbs7Hm7bcHjyrSqYB9c=
github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx27Ps=
github.com/bonitoo-io/go-sql-bigquery v0.3.4-1.4.0/go.mod h1:J4Y6YJm0qTWB9aFziB7cPeSyc6dOZFyJdteSeybVpXQ=
+github.com/boombuler/barcode v1.0.0/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8=
github.com/c-bata/go-prompt v0.2.2/go.mod h1:VzqtzE2ksDBcdln8G7mk2RX9QyGjH+OVqOCSiVIqS34=
github.com/cactus/go-statsd-client/statsd v0.0.0-20191106001114-12b4e2b38748/go.mod h1:l/bIBLeOl9eX+wxJAzxS4TveKRtAqlyDpHjhkfO0MEI=
github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ=
@@ -218,12 +244,17 @@ github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWH
github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8=
github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI=
github.com/containerd/containerd v1.3.4/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA=
+github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
+github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
+github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
+github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
+github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/cpuguy83/go-md2man/v2 v2.0.1/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w=
github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
@@ -238,6 +269,7 @@ github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE
github.com/denisenkom/go-mssqldb v0.10.0/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU=
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
github.com/dgryski/go-bitstream v0.0.0-20180413035011-3522498ce2c8/go.mod h1:VMaSuZ+SZcx/wljOQKvp5srsbCiKDEb6K2wC4+PiBmQ=
+github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/dgryski/go-sip13 v0.0.0-20190329191031-25c5027a8c7b/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/dgryski/go-sip13 v0.0.0-20200911182023-62edffca9245/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
github.com/digitalocean/godo v1.52.0/go.mod h1:p7dOjjtSBqCTUksqtA5Fd3uaKs9kyTq2xcz76ulEJRU=
@@ -281,22 +313,30 @@ github.com/fatih/color v1.12.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGE
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k=
+github.com/fogleman/gg v1.3.0/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k=
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
+github.com/form3tech-oss/jwt-go v3.2.5+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
github.com/foxcpp/go-mockdns v0.0.0-20201212160233-ede2f9158d15/go.mod h1:tPg4cp4nseejPd+UKxtCVQ2hUxNTZ7qQZJa7CLriIeo=
github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4=
github.com/franela/goblin v0.0.0-20210519012713-85d372ac71e2/go.mod h1:VzmDKDJVZI3aJmnRI9VjAn9nJ8qPPsN1fqzr9dqInIo=
github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20=
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
+github.com/gabriel-vasile/mimetype v1.4.0/go.mod h1:fA8fi6KUiG7MgQQ+mEWotXoEOvmxRtOJlERCzSmRvr8=
github.com/getkin/kin-openapi v0.53.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4=
github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/globalsign/mgo v0.0.0-20180905125535-1ca0a4f7cbcb/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
+github.com/glycerine/go-unsnap-stream v0.0.0-20181221182339-f9677308dec2/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE=
github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24=
github.com/go-chi/chi v4.1.0+incompatible/go.mod h1:eB3wogJHnLi3x/kFX2A+IbTBlXxmMeXJVKy9tTv1XzQ=
github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs=
+github.com/go-fonts/dejavu v0.1.0/go.mod h1:4Wt4I4OU2Nq9asgDCteaAaWZOV24E+0/Pwo0gppep4g=
+github.com/go-fonts/latin-modern v0.2.0/go.mod h1:rQVLdDMK+mK1xscDwsqM5J8U2jrRa3T0ecnM9pNujks=
+github.com/go-fonts/liberation v0.1.1/go.mod h1:K6qoJYypsmfVjWg8KOVDQhLc8UDgIK2HYqyqAO9z7GY=
+github.com/go-fonts/stix v0.1.0/go.mod h1:w/c1f0ldAUlJmLBvlbkvVXLAD+tAMqobIIQpmnUIzUY=
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
@@ -308,6 +348,7 @@ github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEai
github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY=
github.com/go-kit/log v0.2.0 h1:7i2K3eKTos3Vc0enKCfnVcgHh2olr/MyfboYq7cAcFw=
github.com/go-kit/log v0.2.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0=
+github.com/go-latex/latex v0.0.0-20210118124228-b3d85cf34e07/go.mod h1:CO1AlKB2CSIqUrmQPqA0gdRIlnLEY0gK5JGjh37zN5U=
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A=
@@ -315,6 +356,7 @@ github.com/go-logfmt/logfmt v0.5.1 h1:otpy5pqBCBZ1ng9RQ0dPu4PN7ba75Y/aA+UpowDyNV
github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs=
github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas=
github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
+github.com/go-logr/logr v0.4.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU=
github.com/go-openapi/analysis v0.0.0-20180825180245-b006789cd277/go.mod h1:k70tL6pCuVxPJOHXQ+wIac1FUrvNkHolPie/cLEU6hI=
github.com/go-openapi/analysis v0.17.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik=
github.com/go-openapi/analysis v0.18.0/go.mod h1:IowGgpVeD0vNm45So8nr+IcQ3pxVtpRoBWb8PVZO0ik=
@@ -420,6 +462,7 @@ github.com/gobuffalo/packd v0.1.0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWe
github.com/gobuffalo/packr/v2 v2.0.9/go.mod h1:emmyGweYTm6Kdper+iywB6YK5YzuKchGtJQZ0Odn4pQ=
github.com/gobuffalo/packr/v2 v2.2.0/go.mod h1:CaAwI0GPIAv+5wKLtv8Afwl+Cm78K/I/VCm/3ptBN+0=
github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw=
+github.com/goccy/go-json v0.7.10/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I=
github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
github.com/gofrs/uuid v3.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM=
github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s=
@@ -437,6 +480,7 @@ github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGw
github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
+github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
@@ -482,6 +526,7 @@ github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ
github.com/google/btree v1.0.1/go.mod h1:xXMiIv4Fb/0kKde4SpL7qlzvu5cMJDRkFDxJfI9uaxA=
github.com/google/flatbuffers v1.11.0/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8=
github.com/google/flatbuffers v2.0.0+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8=
+github.com/google/flatbuffers v2.0.5+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8=
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
@@ -528,6 +573,8 @@ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm4
github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
+github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0=
@@ -544,14 +591,18 @@ github.com/gophercloud/gophercloud v0.1.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEo
github.com/gophercloud/gophercloud v0.10.0/go.mod h1:gmC5oQqMDOMO1t1gq5DquX/yAU808e/4mzjjDA76+Ss=
github.com/gophercloud/gophercloud v0.14.0/go.mod h1:VX0Ibx85B60B5XOrZr6kaNwrmPUzcmMpwxvQ1WQIIWM=
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
+github.com/gopherjs/gopherjs v0.0.0-20190812055157-5d271430af9f/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY=
github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg=
github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So=
github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
+github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA=
+github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
+github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
github.com/grpc-ecosystem/grpc-gateway v1.14.4/go.mod h1:6CwZWGDSPRJidgKAtJVvND6soZe6fT7iteq8wDPdhb0=
github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw=
@@ -589,6 +640,7 @@ github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
github.com/hashicorp/golang-lru v0.5.4/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
+github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64=
github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ=
github.com/hashicorp/mdns v1.0.1/go.mod h1:4gW7WsVCke5TE7EPeYliwHlRUyBtfCwuFwuMg2DmyNY=
@@ -609,15 +661,17 @@ github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:
github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc=
github.com/imdario/mergo v0.3.4/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
+github.com/imdario/mergo v0.3.9/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA=
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
github.com/influxdata/flux v0.65.0/go.mod h1:BwN2XG2lMszOoquQaFdPET8FRQfrXiZsWmcMO9rkaVY=
github.com/influxdata/flux v0.65.1/go.mod h1:J754/zds0vvpfwuq7Gc2wRdVwEodfpCFM7mYlOw2LqY=
-github.com/influxdata/flux v0.140.0/go.mod h1:Q1kyXp+qkeAkX0T8wiNKCU7lqtEep1aK7QqrXntPPD4=
+github.com/influxdata/flux v0.161.0/go.mod h1:dALQQHRj+70b+o/9RtaHAAXH3toMs2M58gfY66oEll8=
+github.com/influxdata/gosnowflake v1.6.9/go.mod h1:9W/BvCXOKx2gJtQ+jdi1Vudev9t9/UDOEHnlJZ/y1nU=
github.com/influxdata/httprouter v1.3.1-0.20191122104820-ee83e2772f69/go.mod h1:pwymjR6SrP3gD3pRj9RJwdl1j5s3doEEV8gS4X9qSzA=
github.com/influxdata/influxdb v1.8.0/go.mod h1:SIzcnsjaHRFpmlxpJ4S3NT64qtEKYweNTUMb/vh0OMQ=
github.com/influxdata/influxdb v1.8.3/go.mod h1:JugdFhsvvI8gadxOI6noqNeeBHvWNTbfYGtiAn+2jhI=
-github.com/influxdata/influxdb v1.9.6 h1:S9Mdwp501HRUnX2in/hs7DoIyCrcF7asfnNq/v5EvZ8=
-github.com/influxdata/influxdb v1.9.6/go.mod h1:6waddyyJKoeLqfmLVrNxoOKxvQT/6t2Zuzdx8QyVcw4=
+github.com/influxdata/influxdb v1.9.7 h1:asjvZJ8NFFmxkSw+kOJj1ItGLQdU1nvRQE3jvdQXeRU=
+github.com/influxdata/influxdb v1.9.7/go.mod h1:YZMcI9MYeMGLcg7Td7z5YRk52tL85r5bF4qX6WCnSt4=
github.com/influxdata/influxdb-client-go/v2 v2.3.1-0.20210518120617-5d1fff431040/go.mod h1:vLNHdxTJkIf2mSLvGrpj8TCcISApPoXkaxP8g9uRlW8=
github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo=
github.com/influxdata/influxdb1-client v0.0.0-20200827194710-b269163b24ab/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo=
@@ -626,7 +680,7 @@ github.com/influxdata/influxql v1.1.1-0.20200828144457-65d3ef77d385/go.mod h1:gH
github.com/influxdata/influxql v1.1.1-0.20211004132434-7e7d61973256/go.mod h1:gHp9y86a/pxhjJ+zMjNXiQAA197Xk9wLxaz+fGG+kWk=
github.com/influxdata/line-protocol v0.0.0-20180522152040-32c6aa80de5e/go.mod h1:4kt73NQhadE3daL3WhR5EJ/J2ocX0PZzwxQ0gXJ7oFE=
github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo=
-github.com/influxdata/pkg-config v0.2.9-0.20210928145121-f721f9766b86/go.mod h1:EMS7Ll0S4qkzDk53XS3Z72/egBsPInt+BeRxb0WeSwk=
+github.com/influxdata/pkg-config v0.2.11/go.mod h1:EMS7Ll0S4qkzDk53XS3Z72/egBsPInt+BeRxb0WeSwk=
github.com/influxdata/promql/v2 v2.12.0/go.mod h1:fxOPu+DY0bqCTCECchSRtWfc+0X19ybifQhZoQNF5D8=
github.com/influxdata/roaring v0.4.13-0.20180809181101-fc520f41fab6/go.mod h1:bSgUQ7q5ZLSO+bKBGqJiCBGAl+9DxyW63zLTujjUlOE=
github.com/influxdata/tdigest v0.0.0-20181121200506-bf2b5ad3c0a9/go.mod h1:Js0mqiSBE6Ffsg94weZZ2c+v/ciT8QRHFOap7EKDrR0=
@@ -657,6 +711,7 @@ github.com/jsternberg/zap-logfmt v1.2.0/go.mod h1:kz+1CUmCutPWABnNkOu9hOHKdT2q3T
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w=
github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM=
+github.com/jung-kurt/gofpdf v1.0.0/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes=
github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes=
github.com/jwilder/encoding v0.0.0-20170811194829-b4e1701a28ef/go.mod h1:Ct9fl0F6iIOGgxJ5npU/IUOhOhqlVrGjyIZc8/MagT0=
github.com/karrick/godirwalk v1.8.0/go.mod h1:H5KPZjojv4lE+QYImBI8xVtrBRgYrIVsaRPx4tDPEn4=
@@ -665,6 +720,7 @@ github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvW
github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00=
github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8=
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
+github.com/klauspost/asmfmt v1.3.1/go.mod h1:AG8TuvYojzulgDAMCnYn50l/5QV3Bs/tp6j0HLHbNSE=
github.com/klauspost/compress v1.4.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
github.com/klauspost/compress v1.9.5/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
github.com/klauspost/compress v1.13.1/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg=
@@ -693,9 +749,11 @@ github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+
github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg=
github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k=
github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
+github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM=
github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4=
github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ=
+github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
github.com/mailru/easyjson v0.0.0-20160728113105-d5b7844b561a/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc=
@@ -716,6 +774,7 @@ github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope
github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40=
github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
+github.com/mattn/go-ieproxy v0.0.1/go.mod h1:pYabZ6IHcRpFh7vIaLfK7rdcWgFEb3SFJ6/gNWuh88E=
github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
@@ -723,14 +782,17 @@ github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2y
github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
github.com/mattn/go-isatty v0.0.11/go.mod h1:PhnuNfih5lzO57/f3n+odYbM4JtupLOxQOAqxQCu2WE=
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
+github.com/mattn/go-isatty v0.0.13/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y=
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
github.com/mattn/go-runewidth v0.0.3/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU=
+github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI=
github.com/mattn/go-runewidth v0.0.12/go.mod h1:RAqKPSqVFrSLVXbA8x7dzmKdmGzieGRCM46jaSJTDAk=
github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU=
github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w=
github.com/mattn/go-sqlite3 v1.11.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc=
+github.com/mattn/go-sqlite3 v1.14.7/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU=
github.com/mattn/go-tty v0.0.0-20180907095812-13ff1204f104/go.mod h1:XPvLUNfbS4fJH25nqRHfWLMa1ONC8Amw+mIA639KxkE=
github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU=
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
@@ -741,6 +803,8 @@ github.com/miekg/dns v1.1.29/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7
github.com/miekg/dns v1.1.35/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM=
github.com/miekg/dns v1.1.43/go.mod h1:+evo5L0630/F6ca/Z9+GAqzhjGyn8/c+TBaOyfEl0V4=
github.com/mileusna/useragent v0.0.0-20190129205925-3e331f0949a5/go.mod h1:JWhYAp2EXqUtsxTKdeGlY8Wp44M7VxThC9FEoNGi2IE=
+github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8/go.mod h1:mC1jAcsrzbxHt8iiaC+zU4b1ylILSosueou12R++wfY=
+github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3/go.mod h1:RagcQ7I8IeTMnF8JTXieKnO4Z6JCsikNEzj0DwauVzE=
github.com/minio/highwayhash v1.0.1/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY=
github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY=
github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc=
@@ -826,6 +890,7 @@ github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FI
github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc=
github.com/paulbellamy/ratecounter v0.2.0/go.mod h1:Hfx1hDpSGoqxkVVpBi/IlYD7kChlfo5C6hzIHwPqfFE=
github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k=
+github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
github.com/pelletier/go-toml v1.4.0/go.mod h1:PN7xzY2wHTK0K9p34ErDQMlFxa51Fk0OUruD3k1mMwo=
github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE=
github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac=
@@ -833,10 +898,14 @@ github.com/performancecopilot/speed/v4 v4.0.0/go.mod h1:qxrSyuDGrTOWfV+uKRFhfxw6
github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU=
github.com/peterh/liner v1.0.1-0.20180619022028-8c1271fcf47f/go.mod h1:xIteQHvHuaLYG9IFj6mSxM0fCKrs34IrEQUhOYuGPHc=
github.com/philhofer/fwd v1.0.0/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU=
+github.com/phpdave11/gofpdf v1.4.2/go.mod h1:zpO6xFn9yxo3YLyMvW8HcKWVdbNqgIfOOp2dXMnm1mY=
+github.com/phpdave11/gofpdi v1.0.12/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI=
github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc=
github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
github.com/pierrec/lz4/v4 v4.1.8/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4=
-github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4/go.mod h1:4OwLy04Bl9Ef3GJJCoec+30X3LQs/0/m4HFRt/2LUSA=
+github.com/pierrec/lz4/v4 v4.1.9/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4=
+github.com/pierrec/lz4/v4 v4.1.11/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4=
+github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8/go.mod h1:HKlIX3XHQyzLZPlr7++PzdhaXEj94dEiJgZDTsxEqUI=
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
@@ -851,6 +920,7 @@ github.com/prometheus/alertmanager v0.20.0/go.mod h1:9g2i48FAyZW6BtbsnvHtMHQXl2a
github.com/prometheus/alertmanager v0.21.0/go.mod h1:h7tJ81NA0VLWvWEayi1QltevFkLF3KxmC/malTcT8Go=
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
github.com/prometheus/client_golang v0.9.3-0.20190127221311-3c4408c8b829/go.mod h1:p2iRAGwDERtqlqzRXnrOVns+ignqQo//hLXqYxZYVNs=
+github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo=
github.com/prometheus/client_golang v1.2.1/go.mod h1:XMU6Z2MjaRKVu/dC1qupJI9SiNkDYzz3xecMgSW/F+U=
github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og=
@@ -869,7 +939,9 @@ github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:
github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
github.com/prometheus/client_model v0.2.0 h1:uq5h0d+GuxiXLJLNABMgp2qUWDPiLvgCzz2dUR+/W/M=
github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
+github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
+github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc=
github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA=
@@ -884,6 +956,7 @@ github.com/prometheus/common v0.34.0 h1:RBmGO9d/FVjqHT0yUGQwBJhkwKV+wPCn7KGpvfab
github.com/prometheus/common v0.34.0/go.mod h1:gB3sOl7P0TvJabZpLY5uQMpUqRCPPCyRLCZYc7JZTNE=
github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
+github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
github.com/prometheus/procfs v0.0.5/go.mod h1:4A/X28fw3Fc593LaREMrKMqOKvUAntwMDaekg4FpcdQ=
github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A=
@@ -896,6 +969,7 @@ github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1
github.com/prometheus/prometheus v0.0.0-20200609090129-a6600f564e3c/go.mod h1:S5n0C6tSgdnwWshBUceRx5G1OsjLv/EeZ9t3wIfEtsY=
github.com/prometheus/prometheus v1.8.2-0.20201119142752-3ad25a6dc3d9 h1:F2A86PGVYqn3P7oWbrSmSlJHae9y6wwpAdoWb/pZi6Q=
github.com/prometheus/prometheus v1.8.2-0.20201119142752-3ad25a6dc3d9/go.mod h1:1MDE/bXgu4gqd5w/otko6WQpXZX9vu8QX4KbitCmaPg=
+github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4=
github.com/retailnext/hllpp v1.0.1-0.20180308014038-101a6d2f8b52/go.mod h1:RDpi1RftBQPUCDRw6SmxeaREsAaRKnOclghuzp/WRzc=
github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
@@ -908,9 +982,12 @@ github.com/rogpeppe/go-internal v1.2.2/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFR
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
github.com/rs/cors v1.6.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU=
github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU=
+github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ=
+github.com/rs/zerolog v1.21.0/go.mod h1:ZPhntP/xmq1nnND05hhpAh2QMhSsA4UN3MGZ6O2J3hM=
github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk=
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
+github.com/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w=
github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E=
@@ -922,6 +999,7 @@ github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg
github.com/segmentio/kafka-go v0.1.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo=
github.com/segmentio/kafka-go v0.2.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo=
github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo=
+github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM=
github.com/shurcooL/httpfs v0.0.0-20190707220628-8d4bc4ba7749/go.mod h1:ZY1cvUeJuFPAdZ/B6v7RHavJWZn2YPVFQ1OSXhCGOkg=
github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
github.com/shurcooL/vfsgen v0.0.0-20181202132449-6a9ea43bcacd/go.mod h1:TrYk7fJVaAttu97ZZKrO9UbRa8izdowaMIZcxYMbVaw=
@@ -931,21 +1009,24 @@ github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPx
github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q=
github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88=
-github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0=
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc=
+github.com/smartystreets/assertions v1.0.1/go.mod h1:kHHU4qYBaI3q23Pp3VPrmWhuIUrLW/7eUrw0BU5VaoM=
github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA=
-github.com/snowflakedb/gosnowflake v1.3.13/go.mod h1:6nfka9aTXkUNha1p1cjeeyjDvcyh7jfjp0l8kGpDBok=
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY=
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
+github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ=
+github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE=
+github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
+github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
github.com/streadway/amqp v1.0.0/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw=
@@ -966,6 +1047,7 @@ github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhV
github.com/tinylib/msgp v1.0.2/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE=
github.com/tinylib/msgp v1.1.0/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE=
github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
+github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
github.com/uber-go/tally v3.3.15+incompatible/go.mod h1:YDTIBxdXyOU/sCWilKB4bgyufu1cEi0jdVnRdxvjnmU=
github.com/uber/athenadriver v1.1.4/go.mod h1:tQjho4NzXw55LGfSZEcETuYydpY1vtmixUabHkC1K/E=
@@ -975,6 +1057,7 @@ github.com/uber/jaeger-client-go v2.28.0+incompatible/go.mod h1:WVhlPFC8FDjOFMMW
github.com/uber/jaeger-lib v2.2.0+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U=
github.com/uber/jaeger-lib v2.4.0+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U=
github.com/uber/jaeger-lib v2.4.1+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U=
+github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
github.com/urfave/cli v1.22.1 h1:+mkCCcOFKPnCmVYVcURKps1Xe+3zP90gSYGNfRkjoIY=
github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
@@ -1006,11 +1089,15 @@ github.com/xdg/stringprep v0.0.0-20180714160509-73f8eece6fdc/go.mod h1:Jhud4/sHM
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg=
github.com/xlab/treeprint v1.0.0/go.mod h1:IoImgRak9i3zJyuxOKUP1v4UZd1tMoKkq/Cimt1uhCg=
+github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74=
github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
+github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
+github.com/zeebo/xxh3 v0.13.0/go.mod h1:AQY73TOrhF3jNsdiM9zZOb8MThrYbZONHj7ryDBaLpg=
+go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg=
go.etcd.io/etcd/api/v3 v3.5.0/go.mod h1:cbVKeC6lCfl7j/8jBhAK6aIYO9XOjdptoxU/nLQcPvs=
@@ -1034,8 +1121,14 @@ go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
go.opencensus.io v0.23.0 h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M=
go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
+go.opentelemetry.io/otel v0.20.0/go.mod h1:Y3ugLH2oa81t5QO+Lty+zXf8zC9L26ax4Nzoxm/dooo=
+go.opentelemetry.io/otel/metric v0.20.0/go.mod h1:598I5tYlH1vzBjn+BTuhzTCSb/9debfNp6R3s7Pr1eU=
+go.opentelemetry.io/otel/oteltest v0.20.0/go.mod h1:L7bgKf9ZB7qCwT9Up7i9/pn0PWIa9FqQ2IQ8LoxiGnw=
+go.opentelemetry.io/otel/sdk v0.20.0/go.mod h1:g/IcepuwNsoiX5Byy2nNV0ySUF1em498m7hBWC279Yc=
+go.opentelemetry.io/otel/trace v0.20.0/go.mod h1:6GjCW8zgDjwGHGa6GkyeB8+/5vjT16gUEi0Nf1iBdgw=
go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI=
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
+go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
go.uber.org/atomic v1.5.1/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
@@ -1056,7 +1149,7 @@ go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM=
go.uber.org/zap v1.14.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM=
-go.uber.org/zap v1.14.1/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc=
+go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ=
go.uber.org/zap v1.17.0/go.mod h1:MXVU+bhUf/A7Xi2HNOnopQOrmycQ5Ih87HtOu4q5SSo=
go.uber.org/zap v1.19.1/go.mod h1:j3DNczoxDZroyBnOT1L/Q79cfUMGZxlv/9dzN7SM1rI=
golang.org/x/crypto v0.0.0-20180505025534-4ec37c66abab/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
@@ -1080,7 +1173,6 @@ golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPh
golang.org/x/crypto v0.0.0-20200220183623-bac4c82f6975/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200323165209-0ec3e9974c59/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200422194213-44a606286825/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
-golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
@@ -1089,22 +1181,34 @@ golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b/go.mod h1:T9bdIzuCu7OtxOm
golang.org/x/crypto v0.0.0-20210513164829-c07d793c2f9a/go.mod h1:P+XmwS30IXTQdn5tA2iutPOUgjI07+tq3H3K9MVA1s8=
golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
golang.org/x/crypto v0.0.0-20210915214749-c084706c2272/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
+golang.org/x/crypto v0.0.0-20211117183948-ae814b36b871/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4=
golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
+golang.org/x/exp v0.0.0-20190731235908-ec7cb31e5a56/go.mod h1:JhuoJpWY28nO4Vef9tZUw9qufEGTyX1+7lmHxV5q5G4=
golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
+golang.org/x/exp v0.0.0-20191002040644-a1355ae1e2c3/go.mod h1:NOZ3BPKG0ec/BKJQgnvsSFpcKLM5xXVWnvZS97DWHgE=
golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY=
golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4=
golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM=
golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU=
+golang.org/x/exp v0.0.0-20211028214138-64b4c8e87d1a/go.mod h1:a3o/VtDNHN+dCVLEpzjjUHOzR+Ln3DHX056ZPzoZGGA=
+golang.org/x/exp v0.0.0-20211216164055-b2b84827b756/go.mod h1:b9TAUYHmRtqA6klRHApnXMnj+OyLce4yF5cZCUbk2ps=
golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs=
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20190910094157-69e4b8554b2a/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20200119044424-58c23975cae1/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20200430140353-33d19683fad8/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20200618115811-c13761719519/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20201208152932-35266b937fa6/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
+golang.org/x/image v0.0.0-20210216034530-4410531fe030/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
@@ -1119,15 +1223,20 @@ golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPI
golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY=
golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
+golang.org/x/mobile v0.0.0-20201217150744-e6ae53a27f4f/go.mod h1:skQtrUTUwhdJvXM/2KKJzY8pDgNr9I/FOMqDVRPBUS4=
golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg=
+golang.org/x/mod v0.1.1-0.20191209134235-331c550502dd/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA=
+golang.org/x/mod v0.5.1-0.20210830214625-1b1db11ec8f4/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
+golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro=
+golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY=
golang.org/x/net v0.0.0-20170114055629-f2499483f923/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
@@ -1145,6 +1254,7 @@ golang.org/x/net v0.0.0-20190320064053-1272bf9dcd53/go.mod h1:t9HGtf8HONx5eT2rtn
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
+golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
@@ -1155,6 +1265,7 @@ golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLL
golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191002035440-2ec189313ef0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191004110552-13f9640d40b9/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20191112182307-2180aed22343/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191126235420-ef20fe5d7933/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
@@ -1183,10 +1294,14 @@ golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLd
golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM=
golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk=
golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20210505024714-0287a6fb4125/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210510120150-4163338589ed/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210614182718-04defd469f4e/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20210917221730-978cfadd31cf/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
+golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
@@ -1263,6 +1378,7 @@ golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191010194322-b09406accb47/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191128015809-6d18c012aee9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1288,8 +1404,10 @@ golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200622214017-ed371f2e16b4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200727154430-2d971f7391a4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200826173525-f9321e4c35a6/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20200828194041-157a740278f4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201015000850-e3ed0017c211/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1301,6 +1419,7 @@ golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7w
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20210304124612-50617c2ba197/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
@@ -1314,6 +1433,7 @@ golang.org/x/sys v0.0.0-20210601080250-7ecdf8ef093b/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20210616045830-e2b7044e8c71/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -1321,6 +1441,9 @@ golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210917161153-d61c044b1678/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.0.0-20211117180635-dee7805ff2e1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
@@ -1387,6 +1510,7 @@ golang.org/x/tools v0.0.0-20190813034749-528a2984e271/go.mod h1:b+2E5dAYhXwXZwtn
golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
+golang.org/x/tools v0.0.0-20190927191325-030b2cf1153e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
@@ -1402,6 +1526,7 @@ golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapK
golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200108203644-89082a384178/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
+golang.org/x/tools v0.0.0-20200117012304-6edc0a871e69/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28=
@@ -1438,6 +1563,8 @@ golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk=
+golang.org/x/tools v0.1.8-0.20211029000441-d6a9af8af023/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
+golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU=
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
@@ -1448,9 +1575,11 @@ gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJ
gonum.org/v1/gonum v0.0.0-20181121035319-3f7ecaa7e8ca/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo=
gonum.org/v1/gonum v0.6.0/go.mod h1:9mxDZsDKxgMAuccQkewq682L+0eCu4dCN2yonUJTCLU=
gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0=
+gonum.org/v1/gonum v0.9.3/go.mod h1:TZumC3NeyVQskjXqmyWt4S3bINhy7B4eYwW69EbyX+0=
gonum.org/v1/netlib v0.0.0-20181029234149-ec6d1f5cefe6/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw=
gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw=
gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc=
+gonum.org/v1/plot v0.9.0/go.mod h1:3Pcqqmp6RHvJI72kgb8fThyUnav364FOsdDo2aGW5lY=
google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk=
google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
@@ -1621,6 +1750,7 @@ google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnD
google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE=
google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34=
+google.golang.org/grpc v1.41.0/go.mod h1:U3l9uK9J0sini8mHphKoXyaqDA/8VyGnDee1zzIUK6k=
google.golang.org/grpc v1.44.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU=
google.golang.org/grpc v1.45.0/go.mod h1:lN7owxKUQEqMfSyQikvvk5tf/6zMPsrK+ONuO11+0rQ=
google.golang.org/grpc v1.46.0 h1:oCjezcn6g6A75TGoKYBPgKmVBLexhYLM6MebdrPApP8=
@@ -1647,6 +1777,8 @@ gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f h1:BLraFXnmrev5lT+xlilqcH8XK9/i0At2xKjWk4p6zsU=
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
+gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
@@ -1681,6 +1813,8 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh
honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k=
+honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las=
+honnef.co/go/tools v0.2.0/go.mod h1:lPVVZ2BS5TfnjLyizF7o7hv7j9/L+8cZY2hLyjP9cGY=
k8s.io/api v0.17.5/go.mod h1:0zV5/ungglgy2Rlm3QK8fbxkXVs+BSJWpJP/+8gUVLY=
k8s.io/api v0.19.4/go.mod h1:SbtJ2aHCItirzdJ36YslycFNzWADYH3tgOhvBEFtZAk=
k8s.io/apimachinery v0.17.5/go.mod h1:ioIo1G/a+uONV7Tv+ZmCbMG1/a3kVw5YcDdncd8ugQ0=
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 2f6093d396..4a650cce44 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -143,7 +143,7 @@ github.com/googleapis/gax-go/v2/apierror/internal/proto
# github.com/googleapis/go-type-adapters v1.0.0
## explicit; go 1.11
github.com/googleapis/go-type-adapters/adapters
-# github.com/influxdata/influxdb v1.9.6
+# github.com/influxdata/influxdb v1.9.7
## explicit; go 1.17
github.com/influxdata/influxdb/client/v2
github.com/influxdata/influxdb/models
From b7536f2a0a82e4d03962f344ebc178e46a449dfa Mon Sep 17 00:00:00 2001
From: Yurii Bychenok <5410545+ipeacocks@users.noreply.github.com>
Date: Tue, 17 May 2022 14:20:35 +0300
Subject: [PATCH 38/51] Updated vmctl documentation, migration from OpenTSDB
section (#2595)
Co-authored-by: Yurii Bychenok
---
app/vmctl/README.md | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/app/vmctl/README.md b/app/vmctl/README.md
index c3d1d5bd93..77be861d41 100644
--- a/app/vmctl/README.md
+++ b/app/vmctl/README.md
@@ -16,7 +16,7 @@ To see the full list of supported modes
run the following command:
```bash
-./vmctl --help
+$ ./vmctl --help
NAME:
vmctl - VictoriaMetrics command-line tool
@@ -35,7 +35,7 @@ Each mode has its own unique set of flags specific (e.g. prefixed with `influx`
to the data source and common list of flags for destination (prefixed with `vm` for VictoriaMetrics):
```
-./vmctl influx --help
+$ ./vmctl influx --help
OPTIONS:
--influx-addr value InfluxDB server addr (default: "http://localhost:8086")
--influx-user value InfluxDB user [$INFLUX_USERNAME]
@@ -55,7 +55,7 @@ them below in corresponding sections.
For the destination flags see the full description by running the following command:
```
-./vmctl influx --help | grep vm-
+$ ./vmctl influx --help | grep vm-
```
Some flags like [--vm-extra-label](#adding-extra-labels) or [--vm-significant-figures](#significant-figures)
@@ -77,11 +77,11 @@ forget to specify the `--vm-account-id` flag. See more details for cluster versi
See `./vmctl opentsdb --help` for details and full list of flags.
-*OpenTSDB migration is not possible without a functioning [meta](http://opentsdb.net/docs/build/html/user_guide/metadata.html) table to search for metrics/series.*
+**Important:** OpenTSDB migration is not possible without a functioning [meta](http://opentsdb.net/docs/build/html/user_guide/metadata.html) table to search for metrics/series. Check in OpenTSDB config that appropriate options are [activated]( https://github.com/OpenTSDB/opentsdb/issues/681#issuecomment-177359563) and HBase meta tables are present. W/o them migration won't work.
OpenTSDB migration works like so:
-1. Find metrics based on selected filters (or the default filter set ['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z'])
+1. Find metrics based on selected filters (or the default filter set `['a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z']`)
- e.g. `curl -Ss "http://opentsdb:4242/api/suggest?type=metrics&q=sys"`
@@ -89,9 +89,11 @@ OpenTSDB migration works like so:
- e.g. `curl -Ss "http://opentsdb:4242/api/search/lookup?m=system.load5&limit=1000000"`
+Here `results` return field should not be empty. Otherwise it means that meta tables are absent and needs to be turned on previously.
+
3. Download data for each series in chunks defined in the CLI switches
-- e.g. `-retention=sum-1m-avg:1h:90d` ==
+- e.g. `-retention=sum-1m-avg:1h:90d` means
- `curl -Ss "http://opentsdb:4242/api/query?start=1h-ago&end=now&m=sum:1m-avg-none:system.load5\{host=host1\}"`
- `curl -Ss "http://opentsdb:4242/api/query?start=2h-ago&end=1h-ago&m=sum:1m-avg-none:system.load5\{host=host1\}"`
- `curl -Ss "http://opentsdb:4242/api/query?start=3h-ago&end=2h-ago&m=sum:1m-avg-none:system.load5\{host=host1\}"`
@@ -101,7 +103,7 @@ OpenTSDB migration works like so:
This means that we must stream data from OpenTSDB to VictoriaMetrics in chunks. This is where concurrency for OpenTSDB comes in. We can query multiple chunks at once, but we shouldn't perform too many chunks at a time to avoid overloading the OpenTSDB cluster.
```
-$ bin/vmctl opentsdb --otsdb-addr http://opentsdb:4242/ --otsdb-retentions sum-1m-avg:1h:1d --otsdb-filters system --otsdb-normalize --vm-addr http://victoria/
+$ ./vmctl opentsdb --otsdb-addr http://opentsdb:4242/ --otsdb-retentions sum-1m-avg:1h:1d --otsdb-filters system --otsdb-normalize --vm-addr http://victoria:8428/
OpenTSDB import mode
2021/04/09 11:52:50 Will collect data starting at TS 1617990770
2021/04/09 11:52:50 Loading all metrics from OpenTSDB for filters: [system]
@@ -109,6 +111,14 @@ Found 9 metrics to import. Continue? [Y/n]
2021/04/09 11:52:51 Starting work on system.load1
23 / 402200 [>____________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________________] 0.01% 2 p/s
```
+Where `:8428` is Prometheus port of VictoriaMetrics.
+
+For clustered VictoriaMetrics setup `--vm-account-id` flag needs to be added, for example:
+
+```
+$ ./vmctl opentsdb --otsdb-addr http://opentsdb:4242/ --otsdb-retentions sum-1m-avg:1h:1d --otsdb-filters system --otsdb-normalize --vm-addr http://victoria:8480/ --vm-account-id 0
+```
+This time `:8480` port is vminsert/Prometheus input port.
### Retention strings
From 808d0d8ffed6c18e3380f593329b2f9acbfced2b Mon Sep 17 00:00:00 2001
From: Roman Khavronenko
Date: Tue, 17 May 2022 14:06:58 +0200
Subject: [PATCH 39/51] docs: quickstart update (#2572)
docs: update docs for beginners
QuickStart page was updated with more relevant information.
Key Concepts was added to cover basics for the VictoriaMetrics.
---
docs/Makefile | 11 +
docs/Quick-Start.md | 163 +-
docs/_includes/img.html | 5 +
docs/keyConcepts.excalidraw | 7465 ++++++++++++++++++++++++++
docs/keyConcepts.md | 623 +++
docs/keyConcepts_counter.png | Bin 0 -> 121131 bytes
docs/keyConcepts_data_collection.png | Bin 0 -> 26081 bytes
docs/keyConcepts_data_samples.png | Bin 0 -> 80261 bytes
docs/keyConcepts_gauge.png | Bin 0 -> 141075 bytes
docs/keyConcepts_histogram.png | Bin 0 -> 47983 bytes
docs/keyConcepts_instant_query.png | Bin 0 -> 118553 bytes
docs/keyConcepts_pull_model.png | Bin 0 -> 33326 bytes
docs/keyConcepts_push_model.png | Bin 0 -> 33543 bytes
docs/keyConcepts_range_query.png | Bin 0 -> 271327 bytes
docs/keyConcepts_summary.png | Bin 0 -> 71653 bytes
docs/keyConcepts_two_dcs.png | Bin 0 -> 59433 bytes
docs/keyConcepts_vmui.png | Bin 0 -> 115887 bytes
17 files changed, 8233 insertions(+), 34 deletions(-)
create mode 100644 docs/Makefile
create mode 100644 docs/_includes/img.html
create mode 100644 docs/keyConcepts.excalidraw
create mode 100644 docs/keyConcepts.md
create mode 100644 docs/keyConcepts_counter.png
create mode 100644 docs/keyConcepts_data_collection.png
create mode 100644 docs/keyConcepts_data_samples.png
create mode 100644 docs/keyConcepts_gauge.png
create mode 100644 docs/keyConcepts_histogram.png
create mode 100644 docs/keyConcepts_instant_query.png
create mode 100644 docs/keyConcepts_pull_model.png
create mode 100644 docs/keyConcepts_push_model.png
create mode 100644 docs/keyConcepts_range_query.png
create mode 100644 docs/keyConcepts_summary.png
create mode 100644 docs/keyConcepts_two_dcs.png
create mode 100644 docs/keyConcepts_vmui.png
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100644
index 0000000000..4b0f261cd7
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,11 @@
+docs-install:
+ gem install jekyll bundler
+ bundle install --gemfile=Gemfile
+
+# run local server for documentation website
+# at http://127.0.0.1:4000/
+# On first use, please run `make docs-install`
+docs-up:
+ JEKYLL_GITHUB_TOKEN=blank PAGES_API_URL=http://0.0.0.0 bundle exec \
+ --gemfile=Gemfile \
+ jekyll server --livereload
diff --git a/docs/Quick-Start.md b/docs/Quick-Start.md
index 0dd9018de6..3ac8cf712d 100644
--- a/docs/Quick-Start.md
+++ b/docs/Quick-Start.md
@@ -4,74 +4,169 @@ sort: 13
# Quick start
-## Installation
+## How to install
+
+VictoriaMetrics is distributed in two forms:
+* [Single-server-VictoriaMetrics](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html) - all-in-one
+ binary, which is very easy to use and maintain.
+ Single-server-VictoriaMetrics perfectly scales vertically and easily handles millions of metrics/s;
+* [VictoriaMetrics Cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html) - set of components
+ for building horizontally scalable clusters.
Single-server-VictoriaMetrics VictoriaMetrics is available as:
* [Managed VictoriaMetrics at AWS](https://aws.amazon.com/marketplace/pp/prodview-4tbfq5icmbmyc)
-* [Docker images](https://hub.docker.com/r/victoriametrics/victoria-metrics/)
+* [Docker images](https://hub.docker.com/r/victoriametrics/victoria-metrics/)
* [Snap packages](https://snapcraft.io/victoriametrics)
* [Helm Charts](https://github.com/VictoriaMetrics/helm-charts#list-of-charts)
* [Binary releases](https://github.com/VictoriaMetrics/VictoriaMetrics/releases)
-* [Source code](https://github.com/VictoriaMetrics/VictoriaMetrics). See [How to build from sources](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-build-from-sources)
+* [Source code](https://github.com/VictoriaMetrics/VictoriaMetrics).
+ See [How to build from sources](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-build-from-sources)
* [VictoriaMetrics on Linode](https://www.linode.com/marketplace/apps/victoriametrics/victoriametrics/)
* [VictoriaMetrics on DigitalOcean](https://marketplace.digitalocean.com/apps/victoriametrics-single)
-Just download VictoriaMetrics and follow [these instructions](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-start-victoriametrics).
-Then read [Prometheus setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#prometheus-setup) and [Grafana setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#grafana-setup) docs.
+Just download VictoriaMetrics and follow
+[these instructions](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-start-victoriametrics).
+Then read [Prometheus setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#prometheus-setup)
+and [Grafana setup](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#grafana-setup) docs.
-### Starting VM-Single via Docker:
-The following commands download the latest available [Docker image of VictoriaMetrics](https://hub.docker.com/r/victoriametrics/victoria-metrics) and start it at port 8428, while storing the ingested data at `victoria-metrics-data` subdirectory under the current directory:
+### Starting VM-Single via Docker
+
+The following commands download the latest available
+[Docker image of VictoriaMetrics](https://hub.docker.com/r/victoriametrics/victoria-metrics)
+and start it at port 8428, while storing the ingested data at `victoria-metrics-data` subdirectory
+under the current directory:
+
+
```bash
docker pull victoriametrics/victoria-metrics:latest
docker run -it --rm -v `pwd`/victoria-metrics-data:/victoria-metrics-data -p 8428:8428 victoriametrics/victoria-metrics:latest
```
-Open `http://localhost:8428` in web browser and read [these docs](https://docs.victoriametrics.com/#operation).
+
-There are also the following versions of VictoriaMetrics available:
+Open http://localhost:8428 in web browser
+and read [these docs](https://docs.victoriametrics.com/#operation).
-* [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html) - horizontally scalable VictoriaMetrics, which scales to multiple nodes.
+There is also [VictoriaMetrics cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html)
+- horizontally scalable installation, which scales to multiple nodes.
-### Starting VM-Cluster via Docker:
+### Starting VM-Cluster via Docker
-The following commands clone the latest available [VictoriaMetrics cluster repository](https://github.com/VictoriaMetrics/VictoriaMetrics/tree/cluster) and start the docker container via 'docker-compose'. Further customization is possible by editing the [docker-compose.yaml](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/cluster/deployment/docker/docker-compose.yml) file.
+The following commands clone the latest available
+[VictoriaMetrics cluster repository](https://github.com/VictoriaMetrics/VictoriaMetrics/tree/cluster)
+and start the docker container via 'docker-compose'. Further customization is possible by editing
+the [docker-compose.yaml](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/cluster/deployment/docker/docker-compose.yml)
+file.
+
+
```bash
-git clone https://github.com/VictoriaMetrics/VictoriaMetrics --branch cluster && cd VictoriaMetrics/deployment/docker && docker-compose up
+git clone https://github.com/VictoriaMetrics/VictoriaMetrics --branch cluster &&
+cd VictoriaMetrics/deployment/docker &&
+docker-compose up
```
+
+
* [Cluster setup](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#cluster-setup)
-## Writing data
+## Write data
-Data can be written to VictoriaMetrics in the following ways:
+There are two main models in monitoring for data collection:
+[push](https://docs.victoriametrics.com/keyConcepts.html#push-model)
+and [pull](https://docs.victoriametrics.com/keyConcepts.html#pull-model).
+Both are used in modern monitoring and both are supported by VictoriaMetrics.
-* [DataDog agent](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-send-data-from-datadog-agent)
-* [InfluxDB-compatible agents such as Telegraf](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-send-data-from-influxdb-compatible-agents-such-as-telegraf)
-* [Graphite-compatible agents such as StatsD](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-send-data-from-graphite-compatible-agents-such-as-statsd)
-* [OpenTSDB-compatible agents](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-send-data-from-opentsdb-compatible-agents)
-* [Prometheus remote_write API](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#remote_write)
-* [In JSON line format](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-import-data-in-json-line-format)
-* [Imported in CSV format](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-import-csv-data)
-* [Imported in Prometheus exposition format](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-import-data-in-prometheus-exposition-format)
-* `/api/v1/import` for importing data obtained from [/api/v1/export](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-export-data-in-json-line-format).
- See [these docs](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#how-to-import-data-in-json-line-format) for details.
+See more details on [writing data here](https://docs.victoriametrics.com/keyConcepts.html#write-data).
-## Reading data
-VictoriaMetrics various APIs for reading the data. [This document briefly describes these APIs](https://docs.victoriametrics.com/url-examples.html).
+## Query data
-### Grafana setup:
+VictoriaMetrics provides an
+[HTTP API](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#prometheus-querying-api-usage)
+for serving read queries. The API is used in various integrations such as
+[Grafana](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#grafana-setup).
+The same API is also used by
+[VMUI](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#vmui) - graphical User Interface
+for querying and visualizing metrics.
-Create [Prometheus datasource](http://docs.grafana.org/features/datasources/prometheus/) in Grafana with the following url:
+[MetricsQL](https://docs.victoriametrics.com/MetricsQL.html) - is he query language for executing read queries
+in VictoriaMetrics. MetricsQL is a [PromQL](https://prometheus.io/docs/prometheus/latest/querying/basics)
+-like query language with a powerful set of functions and features for working specifically with time series data.
-```url
-http://:8428
-```
+See more details on [querying data here](https://docs.victoriametrics.com/keyConcepts.html#query-data)
-Substitute `` with the hostname or IP address of VictoriaMetrics.
-Then build graphs and dashboards for the created datasource using [PromQL](https://prometheus.io/docs/prometheus/latest/querying/basics/) or [MetricsQL](https://docs.victoriametrics.com/MetricsQL.html).
+## Alerting
+
+It is not possible to physically trace all changes on graphs all the time, that is why alerting exists.
+In [vmalert](https://docs.victoriametrics.com/vmalert.html) it is possible to create a set of conditions
+based on PromQL and MetricsQL queries that will send a notification when such conditions are met.
+
+## Data migration
+
+Migrating data from other TSDBs to VictoriaMetrics is as simple as importing data via any of
+[supported formats](https://docs.victoriametrics.com/keyConcepts.html#push-model).
+
+The migration might get easier when using [vmctl](https://docs.victoriametrics.com/vmctl.html) - VictoriaMetrics
+command line tool. It supports the following databases for migration to VictoriaMetrics:
+* [Prometheus using snapshot API](https://docs.victoriametrics.com/vmctl.html#migrating-data-from-prometheus);
+* [Thanos](https://docs.victoriametrics.com/vmctl.html#migrating-data-from-thanos);
+* [InfluxDB](https://docs.victoriametrics.com/vmctl.html#migrating-data-from-influxdb-1x);
+* [OpenTSDB](https://docs.victoriametrics.com/vmctl.html#migrating-data-from-opentsdb);
+* [Migrate data between VictoriaMetrics single and cluster versions](https://docs.victoriametrics.com/vmctl.html#migrating-data-from-victoriametrics).
+
+## Productionisation
+
+When going to production with VictoriaMetrics we recommend following the recommendations.
+
+### Monitoring
+
+Each VictoriaMetrics component emits its own metrics with various details regarding performance
+and health state. Docs for the components also contain a `Monitoring` section with an explanation
+of what and how should be monitored. For example,
+[Single-server-VictoriaMetrics Monitoring](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#monitoring).
+
+VictoriaMetric team prepared a list of [Grafana dashboards](https://grafana.com/orgs/victoriametrics/dashboards)
+for the main components. Each dashboard contains a lot of useful information and tips. It is recommended
+to have these dashboards installed and up to date.
+
+The list of alerts for [single](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/deployment/docker/alerts.yml)
+and [cluster](https://github.com/VictoriaMetrics/VictoriaMetrics/blob/cluster/deployment/docker/alerts.yml)
+versions would also help to identify and notify about issues with the system.
+
+The rule of the thumb is to have a separate installation of VictoriaMetrics or any other monitoring system
+to monitor the production installation of VictoriaMetrics. This would make monitoring independent and
+will help identify problems with the main monitoring installation.
+
+
+### Capacity planning
+
+See capacity planning sections in [docs](https://docs.victoriametrics.com) for
+[Single-server-VictoriaMetrics](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#capacity-planning).
+and [VictoriaMetrics Cluster](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#capacity-planning).
+
+Capacity planning isn't possible without [monitoring](#monitoring), so consider configuring it first.
+Understanding resource usage and performance of VictoriaMetrics also requires knowing the tech terms
+[active series](https://docs.victoriametrics.com/FAQ.html#what-is-an-active-time-series),
+[churn rate](https://docs.victoriametrics.com/FAQ.html#what-is-high-churn-rate),
+[cardinality](https://docs.victoriametrics.com/FAQ.html#what-is-high-cardinality),
+[slow inserts](https://docs.victoriametrics.com/FAQ.html#what-is-a-slow-insert).
+All of them are present in [Grafana dashboards](https://grafana.com/orgs/victoriametrics/dashboards).
+
+
+### Data safety
+
+It is recommended to read [Replication and data safety](https://docs.victoriametrics.com/Cluster-VictoriaMetrics.html#replication-and-data-safety),
+[Why replication doesn’t save from disaster?](https://valyala.medium.com/speeding-up-backups-for-big-time-series-databases-533c1a927883)
+and [backups](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#backups).
+
+
+### Configuring limits
+
+To avoid excessive resource usage or performance degradation limits must be in place:
+* [Resource usage limits](https://docs.victoriametrics.com/FAQ.html#how-to-set-a-memory-limit-for-victoriametrics-components);
+* [Cardinality limiter](https://docs.victoriametrics.com/Single-server-VictoriaMetrics.html#cardinality-limiter).
\ No newline at end of file
diff --git a/docs/_includes/img.html b/docs/_includes/img.html
new file mode 100644
index 0000000000..ad036f1ec0
--- /dev/null
+++ b/docs/_includes/img.html
@@ -0,0 +1,5 @@
+
+
+To get the value of `foo_bar` metric at some specific moment of time, for example `2022-05-10 10:03:00`,
+in VictoriaMetrics we need to issue an **instant query**:
+```bash
+curl "http:///api/v1/query?query=foo_bar&time=2022-05-10T10:03:00.000Z"
+```
+```json
+{"status":"success","data":{"resultType":"vector","result":[{"metric":{"__name__":"foo_bar"},"value":[1652169780,"3"]}]}}
+```
+
+In response, VictoriaMetrics returns a single sample-timestamp pair with a value of `3` for the series
+`foo_bar` at the given moment of time `2022-05-10 10:03`. But, if we take a look at the original data sample again,
+we'll see that there is no data point at `2022-05-10 10:03`. What happens here is if there is no data point at the
+requested timestamp, VictoriaMetrics will try to locate the closest sample on the left to the requested timestamp:
+
+
+
+
+The time range at which VictoriaMetrics will try to locate a missing data sample is equal to `5m`
+by default and can be overridden via `step` parameter.
+
+Instant query can return multiple time series, but always only one data sample per series.
+Instant queries are used in the following scenarios:
+* Getting the last recorded value;
+* For alerts and recording rules evaluation;
+* Plotting Stat or Table panels in Grafana.
+
+
+### Range query
+
+Range query executes the query expression at the given time range with the given step:
+```
+GET | POST /api/v1/query_range
+
+Params:
+query - MetricsQL expression, required
+start - beginning (rfc3339 | unix_timestamp) of the time rage, required
+end - end (rfc3339 | unix_timestamp) of the time range. If omitted, current timestamp is used
+step - step in seconds for evaluating query expression on the time range. If omitted, is set to 5m
+```
+
+To get the values of `foo_bar` on time range from `2022-05-10 09:59:00` to `2022-05-10 10:17:00`,
+in VictoriaMetrics we need to issue a range query:
+```bash
+curl "http:///api/v1/query_range?query=foo_bar&step=1m&start=2022-05-10T09:59:00.000Z&end=2022-05-10T10:17:00.000Z"
+```
+```json
+{"status":"success","data":{"resultType":"matrix","result":[{"metric":{"__name__":"foo_bar"},"values":[[1652169600,"1"],[1652169660,"2"],[1652169720,"3"],[1652169780,"3"],[1652169840,"7"],[1652169900,"7"],[1652169960,"7.5"],[1652170020,"7.5"],[1652170080,"6"],[1652170140,"6"],[1652170260,"5.5"],[1652170320,"5.25"],[1652170380,"5"],[1652170440,"3"],[1652170500,"1"],[1652170560,"4"],[1652170620,"4"]]}]}}
+```
+
+In response, VictoriaMetrics returns `17` sample-timestamp pairs for the series `foo_bar` at the given time range
+from `2022-05-10 09:59:00` to `2022-05-10 10:17:00`. But, if we take a look at the original data sample again,
+we'll see that it contains only 13 data points. What happens here is that the range query is actually
+an [instant query](#instant-query) executed `(start-end)/step` times on the time range from `start` to `end`.
+If we plot this request in VictoriaMetrics the graph will be shown as the following:
+
+