From a076eb06bf3da0da9a8342d6beb7218d8e36efd7 Mon Sep 17 00:00:00 2001 From: Toan Nguyen Date: Wed, 25 Sep 2024 23:32:30 +0700 Subject: [PATCH] add exclude_labels config and base64 encoding --- configuration/update.go | 38 +- connector-definition/configuration.yaml | 1 + connector/client/config.go | 109 +- connector/metadata/configuration.go | 10 + jsonschema/configuration.json | 141 +- tests/configuration/configuration.yaml | 29 +- ..._conntrack_dialer_conn_attempted_total.hml | 55 +- ...net_conntrack_dialer_conn_closed_total.hml | 55 +- ...onntrack_dialer_conn_established_total.hml | 55 +- ...net_conntrack_dialer_conn_failed_total.hml | 60 +- ...conntrack_listener_conn_accepted_total.hml | 598 ------ ...t_conntrack_listener_conn_closed_total.hml | 599 ------ .../metadata/process_cpu_seconds_total.hml | 138 +- tests/engine/app/metadata/process_max_fds.hml | 46 +- .../process_network_receive_bytes_total.hml | 46 +- .../process_network_transmit_bytes_total.hml | 46 +- .../engine/app/metadata/process_open_fds.hml | 46 +- .../process_resident_memory_bytes.hml | 46 +- .../metadata/process_start_time_seconds.hml | 46 +- .../metadata/process_virtual_memory_bytes.hml | 46 +- .../process_virtual_memory_max_bytes.hml | 46 +- .../engine/app/metadata/prometheus-types.hml | 700 ++++--- tests/engine/app/metadata/prometheus.hml | 1630 ++--------------- .../promhttp_metric_handler_errors_total.hml | 51 +- ...http_metric_handler_requests_in_flight.hml | 46 +- ...promhttp_metric_handler_requests_total.hml | 51 +- tests/engine/app/metadata/service_up.hml | 90 +- tests/engine/app/metadata/target_info.hml | 71 +- 28 files changed, 1211 insertions(+), 3684 deletions(-) delete mode 100644 tests/engine/app/metadata/net_conntrack_listener_conn_accepted_total.hml delete mode 100644 tests/engine/app/metadata/net_conntrack_listener_conn_closed_total.hml diff --git a/configuration/update.go b/configuration/update.go index 364ea3f..a84b750 100644 --- a/configuration/update.go +++ b/configuration/update.go @@ -23,12 +23,18 @@ import ( var clientTracer = otel.Tracer("PrometheusClient") var bannedLabels = []string{"__name__"} +type ExcludeLabels struct { + Regex *regexp.Regexp + Labels []string +} + type updateCommand struct { - Client *client.Client - OutputDir string - Config *metadata.Configuration - Include []*regexp.Regexp - Exclude []*regexp.Regexp + Client *client.Client + OutputDir string + Config *metadata.Configuration + Include []*regexp.Regexp + Exclude []*regexp.Regexp + ExcludeLabels []ExcludeLabels } func introspectSchema(ctx context.Context, args *UpdateArguments) error { @@ -56,6 +62,19 @@ func introspectSchema(ctx context.Context, args *UpdateArguments) error { } if originalConfig.Generator.Metrics.Enabled { + for _, el := range originalConfig.Generator.Metrics.ExcludeLabels { + if len(el.Labels) == 0 { + continue + } + rg, err := regexp.Compile(el.Pattern) + if err != nil { + return fmt.Errorf("invalid exclude_labels pattern `%s`: %s", el.Pattern, err) + } + cmd.ExcludeLabels = append(cmd.ExcludeLabels, ExcludeLabels{ + Regex: rg, + Labels: el.Labels, + }) + } if err := cmd.updateMetricsMetadata(ctx); err != nil { return err } @@ -113,11 +132,18 @@ func (uc *updateCommand) getAllLabelsOfMetric(ctx context.Context, name string) slog.Warn(fmt.Sprintf("warning when fetching labels for metric `%s`", name), slog.Any("warnings", warnings)) } + excludedLabels := bannedLabels + for _, el := range uc.ExcludeLabels { + if el.Regex.MatchString(name) { + excludedLabels = append(excludedLabels, el.Labels...) + } + } results := make(map[string]metadata.LabelInfo) for _, label := range labels { - if slices.Contains(bannedLabels, label) { + if slices.Contains(excludedLabels, label) { continue } + results[label] = metadata.LabelInfo{} } return results, nil diff --git a/connector-definition/configuration.yaml b/connector-definition/configuration.yaml index d688ac9..82977ce 100644 --- a/connector-definition/configuration.yaml +++ b/connector-definition/configuration.yaml @@ -7,6 +7,7 @@ generator: enabled: true include: [] exclude: [] + exclude_labels: [] metadata: metrics: {} native_operations: diff --git a/connector/client/config.go b/connector/client/config.go index 29e7868..28134cf 100644 --- a/connector/client/config.go +++ b/connector/client/config.go @@ -2,9 +2,11 @@ package client import ( "context" + "encoding/base64" "encoding/json" "fmt" "net/http" + "net/url" "github.com/hasura/ndc-prometheus/connector/types" "github.com/prometheus/common/config" @@ -31,11 +33,11 @@ type ClientSettings struct { // The omitempty flag is not set, because it would be hidden from the // marshalled configuration when set to false. EnableHTTP2 bool `yaml:"enable_http2,omitempty" json:"enable_http2,omitempty"` - // Proxy configuration. - config.ProxyConfig `yaml:",inline"` // HTTPHeaders specify headers to inject in the requests. Those headers // could be marshalled back to the users. - HTTPHeaders *config.Headers `yaml:"http_headers,omitempty" json:"http_headers,omitempty"` + HTTPHeaders http.Header `yaml:"http_headers,omitempty" json:"http_headers,omitempty"` + // Proxy configuration. + *ProxyConfig `yaml:",inline"` } // UnmarshalJSON implements json.Unmarshaler. @@ -61,10 +63,16 @@ func (cs ClientSettings) getHTTPClientConfig() (*config.HTTPClientConfig, error) TLSConfig: cs.TLSConfig, FollowRedirects: cs.FollowRedirects, EnableHTTP2: cs.EnableHTTP2, - ProxyConfig: cs.ProxyConfig, - HTTPHeaders: cs.HTTPHeaders, + HTTPHeaders: cs.getHTTPHeaders(), } + if cs.ProxyConfig != nil { + pc, err := cs.ProxyConfig.toClientConfig() + if err != nil { + return nil, err + } + result.ProxyConfig = *pc + } if cs.Authentication == nil { return result, nil } @@ -93,6 +101,18 @@ func (cs ClientSettings) getHTTPClientConfig() (*config.HTTPClientConfig, error) return result, nil } +func (cs ClientSettings) getHTTPHeaders() *config.Headers { + result := config.Headers{ + Headers: make(map[string]config.Header), + } + for k, v := range cs.HTTPHeaders { + result.Headers[k] = config.Header{ + Values: v, + } + } + return &result +} + func (cs ClientSettings) createHttpClient(ctx context.Context) (*http.Client, error) { httpClient, err := cs.createGoogleHttpClient(ctx) if err != nil { @@ -123,6 +143,13 @@ func (cs ClientSettings) createGoogleHttpClient(ctx context.Context) (*http.Clie return nil, err } if credJSON != "" { + if cs.Authentication.Google.Encoding != nil && *cs.Authentication.Google.Encoding == CredentialsEncodingBase64 { + credByte, err := base64.StdEncoding.DecodeString(credJSON) + if err != nil { + return nil, err + } + credJSON = string(credByte) + } opts = append(opts, option.WithCredentialsJSON([]byte(credJSON))) } } else if cs.Authentication.Google.CredentialsFile != nil { @@ -138,9 +165,8 @@ func (cs ClientSettings) createGoogleHttpClient(ctx context.Context) (*http.Clie rt, err := config.NewRoundTripperFromConfigWithContext(ctx, config.HTTPClientConfig{ TLSConfig: cs.TLSConfig, EnableHTTP2: cs.EnableHTTP2, - ProxyConfig: cs.ProxyConfig, FollowRedirects: cs.FollowRedirects, - HTTPHeaders: cs.HTTPHeaders, + HTTPHeaders: cs.getHTTPHeaders(), }, "ndc-prometheus") if err != nil { return nil, err @@ -212,13 +238,14 @@ func (hac AuthorizationConfig) toClientConfig() (*config.Authorization, error) { // OAuth2Config the OAuth2 client credentials used to fetch a token for the targets type OAuth2Config struct { - ClientID types.EnvironmentValue `yaml:"client_id" json:"client_id"` - ClientSecret types.EnvironmentValue `yaml:"client_secret" json:"client_secret"` - TokenURL types.EnvironmentValue `yaml:"token_url" json:"token_url"` - Scopes []string `yaml:"scopes,omitempty" json:"scopes,omitempty"` - EndpointParams map[string]string `yaml:"endpoint_params,omitempty" json:"endpoint_params,omitempty"` - TLSConfig config.TLSConfig `yaml:"tls_config,omitempty"` - config.ProxyConfig `yaml:",inline"` + ClientID types.EnvironmentValue `yaml:"client_id" json:"client_id"` + ClientSecret types.EnvironmentValue `yaml:"client_secret" json:"client_secret"` + TokenURL types.EnvironmentValue `yaml:"token_url" json:"token_url"` + Scopes []string `yaml:"scopes,omitempty" json:"scopes,omitempty"` + EndpointParams map[string]string `yaml:"endpoint_params,omitempty" json:"endpoint_params,omitempty"` + TLSConfig config.TLSConfig `yaml:"tls_config,omitempty"` + + *ProxyConfig `yaml:",inline"` } func (oc OAuth2Config) toClientConfig() (*config.OAuth2, error) { @@ -235,21 +262,69 @@ func (oc OAuth2Config) toClientConfig() (*config.OAuth2, error) { return nil, err } - return &config.OAuth2{ + result := &config.OAuth2{ ClientID: clientId, ClientSecret: config.Secret(clientSecret), TokenURL: tokenURL, Scopes: oc.Scopes, EndpointParams: oc.EndpointParams, TLSConfig: oc.TLSConfig, - ProxyConfig: oc.ProxyConfig, - }, nil + } + if oc.ProxyConfig != nil { + pc, err := oc.ProxyConfig.toClientConfig() + if err != nil { + return nil, err + } + result.ProxyConfig = *pc + } + return result, nil } +// CredentialsEncoding the encoding of credentials string +type CredentialsEncoding string + +const ( + CredentialsEncodingPlainText CredentialsEncoding = "plaintext" + CredentialsEncodingBase64 CredentialsEncoding = "base64" +) + // GoogleAuth the Google client credentials used to fetch a token for the targets type GoogleAuthConfig struct { + Encoding *CredentialsEncoding `yaml:"encoding,omitempty" json:"encoding,omitempty" jsonschema:"enum=plaintext,enum=base64,default=plaintext"` // Text of the Google credential JSON Credentials *types.EnvironmentValue `yaml:"credentials,omitempty" json:"credentials,omitempty"` // Path of the Google credential file CredentialsFile *types.EnvironmentValue `yaml:"credentials_file,omitempty" json:"credentials_file,omitempty"` } + +// ProxyConfig the proxy configuration +type ProxyConfig struct { + // HTTP proxy server to use to connect to the targets. + ProxyURL string `yaml:"proxy_url,omitempty" json:"proxy_url,omitempty"` + // NoProxy contains addresses that should not use a proxy. + NoProxy string `yaml:"no_proxy,omitempty" json:"no_proxy,omitempty"` + // ProxyFromEnvironment makes use of net/http ProxyFromEnvironment function + // to determine proxies. + ProxyFromEnvironment bool `yaml:"proxy_from_environment,omitempty" json:"proxy_from_environment,omitempty"` + // ProxyConnectHeader optionally specifies headers to send to + // proxies during CONNECT requests. Assume that at least _some_ of + // these headers are going to contain secrets and use Secret as the + // value type instead of string. + ProxyConnectHeader config.ProxyHeader `yaml:"proxy_connect_header,omitempty" json:"proxy_connect_header,omitempty"` +} + +func (oc ProxyConfig) toClientConfig() (*config.ProxyConfig, error) { + result := &config.ProxyConfig{ + NoProxy: oc.NoProxy, + ProxyFromEnvironment: oc.ProxyFromEnvironment, + ProxyConnectHeader: oc.ProxyConnectHeader, + } + if oc.ProxyURL != "" { + u, err := url.Parse(oc.ProxyURL) + if err != nil { + return nil, err + } + result.ProxyURL = config.URL{URL: u} + } + return result, nil +} diff --git a/connector/metadata/configuration.go b/connector/metadata/configuration.go index 446dd6a..6281ca4 100644 --- a/connector/metadata/configuration.go +++ b/connector/metadata/configuration.go @@ -23,6 +23,16 @@ type MetricsGeneratorSettings struct { // Exclude metrics with regular expression matching. // Note: exclude is higher priority than include Exclude []string `json:"exclude" yaml:"exclude"` + // Exclude unnecessary labels + ExcludeLabels []ExcludeLabelsSetting `json:"exclude_labels" yaml:"exclude_labels"` +} + +// ExcludeLabelsSetting the setting to exclude labels +type ExcludeLabelsSetting struct { + // The regular expression pattern of metric names + Pattern string `json:"pattern" yaml:"pattern"` + // List of labels to be excluded + Labels []string `json:"labels" yaml:"labels"` } // GeneratorSettings contain settings for the configuration generator diff --git a/jsonschema/configuration.json b/jsonschema/configuration.json index bab4070..8fde246 100644 --- a/jsonschema/configuration.json +++ b/jsonschema/configuration.json @@ -73,8 +73,11 @@ "enable_http2": { "type": "boolean" }, + "http_headers": { + "$ref": "#/$defs/Header" + }, "proxy_url": { - "$ref": "#/$defs/URL" + "type": "string" }, "no_proxy": { "type": "string" @@ -84,9 +87,6 @@ }, "proxy_connect_header": { "$ref": "#/$defs/ProxyHeader" - }, - "http_headers": { - "$ref": "#/$defs/Headers" } }, "additionalProperties": false, @@ -141,6 +141,25 @@ "additionalProperties": false, "type": "object" }, + "ExcludeLabelsSetting": { + "properties": { + "pattern": { + "type": "string" + }, + "labels": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "additionalProperties": false, + "type": "object", + "required": [ + "pattern", + "labels" + ] + }, "GeneratorSettings": { "properties": { "metrics": { @@ -155,6 +174,14 @@ }, "GoogleAuthConfig": { "properties": { + "encoding": { + "type": "string", + "enum": [ + "plaintext", + "base64" + ], + "default": "plaintext" + }, "credentials": { "$ref": "#/$defs/EnvironmentValue" }, @@ -166,44 +193,14 @@ "type": "object" }, "Header": { - "properties": { - "values": { - "items": { - "type": "string" - }, - "type": "array" - }, - "secrets": { - "items": { - "type": "string" - }, - "type": "array" + "additionalProperties": { + "items": { + "type": "string" }, - "files": { - "items": { - "type": "string" - }, - "type": "array" - } + "type": "array" }, - "additionalProperties": false, "type": "object" }, - "Headers": { - "properties": { - "Headers": { - "additionalProperties": { - "$ref": "#/$defs/Header" - }, - "type": "object" - } - }, - "additionalProperties": false, - "type": "object", - "required": [ - "Headers" - ] - }, "LabelInfo": { "properties": { "description": { @@ -270,6 +267,12 @@ "type": "string" }, "type": "array" + }, + "exclude_labels": { + "items": { + "$ref": "#/$defs/ExcludeLabelsSetting" + }, + "type": "array" } }, "additionalProperties": false, @@ -277,7 +280,8 @@ "required": [ "enabled", "include", - "exclude" + "exclude", + "exclude_labels" ] }, "NativeOperations": { @@ -372,7 +376,7 @@ "$ref": "#/$defs/TLSConfig" }, "proxy_url": { - "$ref": "#/$defs/URL" + "type": "string" }, "no_proxy": { "type": "string" @@ -449,63 +453,6 @@ "required": [ "insecure_skip_verify" ] - }, - "URL": { - "properties": { - "Scheme": { - "type": "string" - }, - "Opaque": { - "type": "string" - }, - "User": { - "$ref": "#/$defs/Userinfo" - }, - "Host": { - "type": "string" - }, - "Path": { - "type": "string" - }, - "RawPath": { - "type": "string" - }, - "OmitHost": { - "type": "boolean" - }, - "ForceQuery": { - "type": "boolean" - }, - "RawQuery": { - "type": "string" - }, - "Fragment": { - "type": "string" - }, - "RawFragment": { - "type": "string" - } - }, - "additionalProperties": false, - "type": "object", - "required": [ - "Scheme", - "Opaque", - "User", - "Host", - "Path", - "RawPath", - "OmitHost", - "ForceQuery", - "RawQuery", - "Fragment", - "RawFragment" - ] - }, - "Userinfo": { - "properties": {}, - "additionalProperties": false, - "type": "object" } } } \ No newline at end of file diff --git a/tests/configuration/configuration.yaml b/tests/configuration/configuration.yaml index 4128f0c..6548e02 100644 --- a/tests/configuration/configuration.yaml +++ b/tests/configuration/configuration.yaml @@ -16,58 +16,37 @@ generator: - ^prometheus_+ - ^go_+ - ^node_+ + exclude_labels: + - pattern: ^net_.+ + labels: + - dialer_name metadata: metrics: - ndc_prometheus_query_total: - type: counter - description: Total number of query requests - labels: - collection: {} - http_status: {} - instance: {} - job: {} - otel_scope_name: {} - status: {} - ndc_prometheus_query_total_time: - type: histogram - description: Total time taken to plan and execute a query, in seconds - labels: {} net_conntrack_dialer_conn_attempted_total: type: counter description: Total number of connections attempted by the given dialer a given name. labels: - dialer_name: {} instance: {} job: {} net_conntrack_dialer_conn_closed_total: type: counter description: Total number of connections closed which originated from the dialer of a given name. labels: - dialer_name: {} instance: {} job: {} net_conntrack_dialer_conn_established_total: type: counter description: Total number of connections successfully established by the given dialer a given name. labels: - dialer_name: {} instance: {} job: {} net_conntrack_dialer_conn_failed_total: type: counter description: Total number of connections failed to dial by the dialer a given name. labels: - dialer_name: {} instance: {} job: {} reason: {} - otel_scope_info: - type: gauge - description: Instrumentation Scope metadata - labels: - instance: {} - job: {} - otel_scope_name: {} process_cpu_seconds_total: type: counter description: Total user and system CPU time spent in seconds. diff --git a/tests/engine/app/metadata/net_conntrack_dialer_conn_attempted_total.hml b/tests/engine/app/metadata/net_conntrack_dialer_conn_attempted_total.hml index 2d8b4bb..cd5ddec 100644 --- a/tests/engine/app/metadata/net_conntrack_dialer_conn_attempted_total.hml +++ b/tests/engine/app/metadata/net_conntrack_dialer_conn_attempted_total.hml @@ -621,8 +621,6 @@ version: v1 definition: name: NetConntrackDialerConnAttemptedTotal fields: - - name: dialer_name - type: String! - name: instance type: String! - name: job @@ -655,7 +653,6 @@ definition: - role: admin output: allowedFields: - - dialer_name - instance - job - labels @@ -664,35 +661,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: NetConntrackDialerConnAttemptedTotal_bool_exp - objectType: NetConntrackDialerConnAttemptedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackDialerConnAttemptedTotal - comparableFields: - - fieldName: dialer_name - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: NetConntrackDialerConnAttemptedTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: NetConntrackDialerConnAttemptedTotal_bool_exp @@ -723,9 +714,6 @@ definition: collection: net_conntrack_dialer_conn_attempted_total filterExpressionType: NetConntrackDialerConnAttemptedTotal_bool_exp orderableFields: - - fieldName: dialer_name - orderByDirections: - enableAll: true - fieldName: instance orderByDirections: enableAll: true @@ -741,9 +729,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: net_conntrack_dialer_conn_attempted_total diff --git a/tests/engine/app/metadata/net_conntrack_dialer_conn_closed_total.hml b/tests/engine/app/metadata/net_conntrack_dialer_conn_closed_total.hml index b1557c1..d805b07 100644 --- a/tests/engine/app/metadata/net_conntrack_dialer_conn_closed_total.hml +++ b/tests/engine/app/metadata/net_conntrack_dialer_conn_closed_total.hml @@ -455,8 +455,6 @@ version: v1 definition: name: NetConntrackDialerConnClosedTotal fields: - - name: dialer_name - type: String! - name: instance type: String! - name: job @@ -489,7 +487,6 @@ definition: - role: admin output: allowedFields: - - dialer_name - instance - job - labels @@ -498,35 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: NetConntrackDialerConnClosedTotal_bool_exp - objectType: NetConntrackDialerConnClosedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackDialerConnClosedTotal - comparableFields: - - fieldName: dialer_name - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: NetConntrackDialerConnClosedTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: NetConntrackDialerConnClosedTotal_bool_exp @@ -557,9 +548,6 @@ definition: collection: net_conntrack_dialer_conn_closed_total filterExpressionType: NetConntrackDialerConnClosedTotal_bool_exp orderableFields: - - fieldName: dialer_name - orderByDirections: - enableAll: true - fieldName: instance orderByDirections: enableAll: true @@ -575,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: net_conntrack_dialer_conn_closed_total diff --git a/tests/engine/app/metadata/net_conntrack_dialer_conn_established_total.hml b/tests/engine/app/metadata/net_conntrack_dialer_conn_established_total.hml index c821646..e1cf516 100644 --- a/tests/engine/app/metadata/net_conntrack_dialer_conn_established_total.hml +++ b/tests/engine/app/metadata/net_conntrack_dialer_conn_established_total.hml @@ -455,8 +455,6 @@ version: v1 definition: name: NetConntrackDialerConnEstablishedTotal fields: - - name: dialer_name - type: String! - name: instance type: String! - name: job @@ -489,7 +487,6 @@ definition: - role: admin output: allowedFields: - - dialer_name - instance - job - labels @@ -498,35 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: NetConntrackDialerConnEstablishedTotal_bool_exp - objectType: NetConntrackDialerConnEstablishedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackDialerConnEstablishedTotal - comparableFields: - - fieldName: dialer_name - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: NetConntrackDialerConnEstablishedTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: NetConntrackDialerConnEstablishedTotal_bool_exp @@ -557,9 +548,6 @@ definition: collection: net_conntrack_dialer_conn_established_total filterExpressionType: NetConntrackDialerConnEstablishedTotal_bool_exp orderableFields: - - fieldName: dialer_name - orderByDirections: - enableAll: true - fieldName: instance orderByDirections: enableAll: true @@ -575,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: net_conntrack_dialer_conn_established_total diff --git a/tests/engine/app/metadata/net_conntrack_dialer_conn_failed_total.hml b/tests/engine/app/metadata/net_conntrack_dialer_conn_failed_total.hml index 6f8abf4..26736aa 100644 --- a/tests/engine/app/metadata/net_conntrack_dialer_conn_failed_total.hml +++ b/tests/engine/app/metadata/net_conntrack_dialer_conn_failed_total.hml @@ -455,8 +455,6 @@ version: v1 definition: name: NetConntrackDialerConnFailedTotal fields: - - name: dialer_name - type: String! - name: instance type: String! - name: job @@ -491,7 +489,6 @@ definition: - role: admin output: allowedFields: - - dialer_name - instance - job - labels @@ -501,38 +498,31 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: NetConntrackDialerConnFailedTotal_bool_exp - objectType: NetConntrackDialerConnFailedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackDialerConnFailedTotal - comparableFields: - - fieldName: dialer_name - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: reason - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: NetConntrackDialerConnFailedTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: reason + booleanExpressionType: String_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: NetConntrackDialerConnFailedTotal_bool_exp @@ -563,9 +553,6 @@ definition: collection: net_conntrack_dialer_conn_failed_total filterExpressionType: NetConntrackDialerConnFailedTotal_bool_exp orderableFields: - - fieldName: dialer_name - orderByDirections: - enableAll: true - fieldName: instance orderByDirections: enableAll: true @@ -584,9 +571,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: net_conntrack_dialer_conn_failed_total diff --git a/tests/engine/app/metadata/net_conntrack_listener_conn_accepted_total.hml b/tests/engine/app/metadata/net_conntrack_listener_conn_accepted_total.hml deleted file mode 100644 index cfeda7e..0000000 --- a/tests/engine/app/metadata/net_conntrack_listener_conn_accepted_total.hml +++ /dev/null @@ -1,598 +0,0 @@ ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotalLabelJoinInput - description: Input arguments for the label_join function - fields: - - name: dest_label - type: String! - description: The destination label name - - name: separator - type: String! - description: The separator between source labels - - name: source_labels - type: "[NetConntrackListenerConnAcceptedTotalLabel!]!" - description: Source labels - graphql: - typeName: NetConntrackListenerConnAcceptedTotalLabelJoinInput - inputTypeName: NetConntrackListenerConnAcceptedTotalLabelJoinInput_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnAcceptedTotalLabelJoinInput - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnAcceptedTotalLabelJoinInput - permissions: - - role: admin - output: - allowedFields: - - dest_label - - separator - - source_labels - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotalLabelReplaceInput - description: Input arguments for the label_replace function - fields: - - name: dest_label - type: String! - description: The destination label name - - name: regex - type: String! - description: The regular expression against the value of the source label - - name: replacement - type: String! - description: The replacement value - - name: source_label - type: NetConntrackListenerConnAcceptedTotalLabel! - description: Source label - graphql: - typeName: NetConntrackListenerConnAcceptedTotalLabelReplaceInput - inputTypeName: NetConntrackListenerConnAcceptedTotalLabelReplaceInput_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnAcceptedTotalLabelReplaceInput - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnAcceptedTotalLabelReplaceInput - permissions: - - role: admin - output: - allowedFields: - - dest_label - - regex - - replacement - - source_label - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotalFunctions - fields: - - name: abs - type: Boolean - description: Returns the input vector with all sample values converted to their - absolute value - - name: absent - type: Boolean - description: Returns an empty vector if the vector passed to it has any elements - (floats or native histograms) and a 1-element vector with the value 1 if - the vector passed to it has no elements - - name: absent_over_time - type: RangeResolution - description: Returns an empty vector if the range vector passed to it has any - elements (floats or native histograms) and a 1-element vector with the - value 1 if the range vector passed to it has no elements - - name: acos - type: Boolean - description: Calculates the arccosine of all elements in v - - name: acosh - type: Boolean - description: Calculates the inverse hyperbolic cosine of all elements in v - - name: asin - type: Boolean - description: Calculates the arcsine of all elements in v - - name: asinh - type: Boolean - description: Calculates the inverse hyperbolic sine of all elements in v - - name: atan - type: Boolean - description: Calculates the arctangent of all elements in v - - name: atanh - type: Boolean - description: Calculates the inverse hyperbolic tangent of all elements in v - - name: avg - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: avg_over_time - type: RangeResolution - description: The average value of all points in the specified interval - - name: bottomk - type: Int64 - description: Smallest k elements by sample value - - name: ceil - type: Boolean - description: Rounds the sample values of all elements in v up to the nearest - integer value greater than or equal to v - - name: changes - type: RangeResolution - description: Returns the number of times its value has changed within the - provided time range as an instant vector - - name: clamp - type: ValueBoundaryInput - description: Clamps the sample values of all elements in v to have a lower limit - of min and an upper limit of max - - name: clamp_max - type: Float64 - description: Clamps the sample values of all elements in v to have an upper - limit of max - - name: clamp_min - type: Float64 - description: Clamps the sample values of all elements in v to have a lower limit - of min - - name: cos - type: Boolean - description: Calculates the cosine of all elements in v - - name: cosh - type: Boolean - description: Calculates the hyperbolic cosine of all elements in v - - name: count - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: count_over_time - type: RangeResolution - description: The count of all values in the specified interval - - name: count_values - type: NetConntrackListenerConnAcceptedTotalLabel - - name: deg - type: Boolean - description: Converts radians to degrees for all elements in v - - name: delta - type: RangeResolution - description: Calculates the difference between the first and last value of each - time series element in a range vector v, returning an instant vector - with the given deltas and equivalent labels - - name: deriv - type: RangeResolution - description: Calculates the per-second derivative of the time series in a range - vector v, using simple linear regression - - name: exp - type: Boolean - description: Calculates the exponential function for all elements in v - - name: floor - type: Boolean - description: Rounds the sample values of all elements in v down to the nearest - integer value smaller than or equal to v - - name: group - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: histogram_avg - type: Boolean - description: Returns the arithmetic average of observed values stored in a - native histogram. Samples that are not native histograms are ignored and - do not show up in the returned vector - - name: histogram_count - type: Boolean - description: Returns the count of observations stored in a native histogram. - Samples that are not native histograms are ignored and do not show up in - the returned vector - - name: histogram_fraction - type: ValueBoundaryInput - description: Returns the estimated fraction of observations between the provided - lower and upper values. Samples that are not native histograms are - ignored and do not show up in the returned vector - - name: histogram_quantile - type: Float64 - description: Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or - from a native histogram - - name: histogram_stddev - type: Boolean - description: Returns the estimated standard deviation of observations in a - native histogram, based on the geometric mean of the buckets where the - observations lie. Samples that are not native histograms are ignored and - do not show up in the returned vector - - name: histogram_stdvar - type: Boolean - description: Returns the estimated standard variance of observations in a native - histogram - - name: histogram_sum - type: Boolean - description: Returns the sum of observations stored in a native histogram - - name: holt_winters - type: HoltWintersInput - description: Produces a smoothed value for time series based on the range in v - - name: idelta - type: RangeResolution - description: Calculates the difference between the last two samples in the range - vector v, returning an instant vector with the given deltas and - equivalent labels - - name: increase - type: RangeResolution - description: Calculates the increase in the time series in the range vector. - Breaks in monotonicity (such as counter resets due to target restarts) - are automatically adjusted for - - name: irate - type: RangeResolution - description: Calculates the per-second instant rate of increase of the time - series in the range vector. This is based on the last two data points - - name: label_join - type: NetConntrackListenerConnAcceptedTotalLabelJoinInput - description: Joins all the values of all the src_labels using separator and - returns the timeseries with the label dst_label containing the joined - value - - name: label_replace - type: NetConntrackListenerConnAcceptedTotalLabelReplaceInput - description: Matches the regular expression regex against the value of the label - src_label. If it matches, the value of the label dst_label in the - returned timeseries will be the expansion of replacement, together with - the original labels in the input - - name: last_over_time - type: RangeResolution - description: The most recent point value in the specified interval - - name: limit_ratio - type: Float64 - description: Sample elements with approximately 𝑟 ratio if 𝑟 > 0, and the - complement of such samples if 𝑟 = -(1.0 - 𝑟)) - - name: limitk - type: Int64 - description: Limit sample n elements - - name: ln - type: Boolean - description: Calculates the natural logarithm for all elements in v - - name: log2 - type: Boolean - description: Calculates the binary logarithm for all elements in v - - name: log10 - type: Boolean - description: Calculates the decimal logarithm for all elements in v - - name: mad_over_time - type: RangeResolution - description: The median absolute deviation of all points in the specified interval - - name: max - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: max_over_time - type: RangeResolution - description: The maximum value of all points in the specified interval - - name: min - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: min_over_time - type: RangeResolution - description: The minimum value of all points in the specified interval - - name: predict_linear - type: PredictLinearInput - description: Predicts the value of time series t seconds from now, based on the - range vector v, using simple linear regression - - name: present_over_time - type: RangeResolution - description: The value 1 for any series in the specified interval - - name: quantile - type: Float64 - description: Calculate φ-quantile (0 ≤ φ ≤ 1) over dimensions - - name: quantile_over_time - type: QuantileOverTimeInput - description: The φ-quantile (0 ≤ φ ≤ 1) of the values in the specified interval - - name: rad - type: Boolean - description: Converts degrees to radians for all elements in v - - name: rate - type: RangeResolution - description: Calculates the per-second average rate of increase of the time - series in the range vector - - name: resets - type: RangeResolution - description: Returns the number of counter resets within the provided time range - as an instant vector - - name: round - type: Float64 - description: Rounds the sample values of all elements in v to the nearest integer - - name: scalar - type: Boolean - description: Returns the sample value of that single element as a scalar - - name: sgn - type: Boolean - description: "Returns a vector with all sample values converted to their sign, - defined as this: 1 if v is positive, -1 if v is negative and 0 if v is - equal to zero" - - name: sin - type: Boolean - description: Calculates the sine of all elements in v - - name: sinh - type: Boolean - description: Calculates the hyperbolic sine of all elements in v - - name: sort - type: Boolean - description: Returns vector elements sorted by their sample values, in ascending - order. Native histograms are sorted by their sum of observations - - name: sort_by_label - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - description: Returns vector elements sorted by their label values and sample - value in case of label values being equal, in ascending order - - name: sort_by_label_desc - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - description: Same as sort_by_label, but sorts in descending order - - name: sort_desc - type: Boolean - description: Same as sort, but sorts in descending order - - name: sqrt - type: Boolean - description: Calculates the square root of all elements in v - - name: stddev - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: stddev_over_time - type: RangeResolution - description: The population standard deviation of the values in the specified interval - - name: stdvar - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: stdvar_over_time - type: RangeResolution - description: The population standard variance of the values in the specified interval - - name: sum - type: "[NetConntrackListenerConnAcceptedTotalLabel!]" - - name: sum_over_time - type: RangeResolution - description: The sum of all values in the specified interval - - name: tan - type: Boolean - description: Calculates the tangent of all elements in v - - name: tanh - type: Boolean - description: Calculates the hyperbolic tangent of all elements in v - - name: timestamp - type: Boolean - description: Returns the timestamp of each of the samples of the given vector as - the number of seconds since January 1, 1970 UTC. It also works with - histogram samples - - name: topk - type: Int64 - description: Largest k elements by sample value - graphql: - typeName: NetConntrackListenerConnAcceptedTotalFunctions - inputTypeName: NetConntrackListenerConnAcceptedTotalFunctions_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnAcceptedTotalFunctions - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnAcceptedTotalFunctions - permissions: - - role: admin - output: - allowedFields: - - abs - - absent - - absent_over_time - - acos - - acosh - - asin - - asinh - - atan - - atanh - - avg - - avg_over_time - - bottomk - - ceil - - changes - - clamp - - clamp_max - - clamp_min - - cos - - cosh - - count - - count_over_time - - count_values - - deg - - delta - - deriv - - exp - - floor - - group - - histogram_avg - - histogram_count - - histogram_fraction - - histogram_quantile - - histogram_stddev - - histogram_stdvar - - histogram_sum - - holt_winters - - idelta - - increase - - irate - - label_join - - label_replace - - last_over_time - - limit_ratio - - limitk - - ln - - log2 - - log10 - - mad_over_time - - max - - max_over_time - - min - - min_over_time - - predict_linear - - present_over_time - - quantile - - quantile_over_time - - rad - - rate - - resets - - round - - scalar - - sgn - - sin - - sinh - - sort - - sort_by_label - - sort_by_label_desc - - sort_desc - - sqrt - - stddev - - stddev_over_time - - stdvar - - stdvar_over_time - - sum - - sum_over_time - - tan - - tanh - - timestamp - - topk - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotal - fields: - - name: instance - type: String! - - name: job - type: String! - - name: labels - type: LabelSet! - description: Labels of the metric - - name: listener_name - type: String! - - name: timestamp - type: Timestamp! - description: An instant timestamp or the last timestamp of a range query result - - name: value - type: Decimal! - description: Value of the instant query or the last value of a range query - - name: values - type: "[QueryResultValue!]!" - description: An array of query result values - graphql: - typeName: NetConntrackListenerConnAcceptedTotal - inputTypeName: NetConntrackListenerConnAcceptedTotal_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnAcceptedTotal - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnAcceptedTotal - permissions: - - role: admin - output: - allowedFields: - - instance - - job - - labels - - listener_name - - timestamp - - value - - values - ---- -kind: ObjectBooleanExpressionType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotal_bool_exp - objectType: NetConntrackListenerConnAcceptedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnAcceptedTotal - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: listener_name - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true - graphql: - typeName: NetConntrackListenerConnAcceptedTotal_bool_exp - ---- -kind: Model -version: v1 -definition: - name: net_conntrack_listener_conn_accepted_total - objectType: NetConntrackListenerConnAcceptedTotal - arguments: - - name: fn - type: "[NetConntrackListenerConnAcceptedTotalFunctions!]" - description: PromQL aggregation operators and functions for - net_conntrack_listener_conn_accepted_total - - name: offset - type: Duration - description: The offset modifier allows changing the time offset for individual - instant and range vectors in a query. - - name: step - type: Duration - description: Query resolution step width in duration format or float number of - seconds. - - name: timeout - type: Duration - description: Evaluation timeout - source: - dataConnectorName: prometheus - collection: net_conntrack_listener_conn_accepted_total - filterExpressionType: NetConntrackListenerConnAcceptedTotal_bool_exp - orderableFields: - - fieldName: instance - orderByDirections: - enableAll: true - - fieldName: job - orderByDirections: - enableAll: true - - fieldName: labels - orderByDirections: - enableAll: true - - fieldName: listener_name - orderByDirections: - enableAll: true - - fieldName: timestamp - orderByDirections: - enableAll: true - - fieldName: value - orderByDirections: - enableAll: true - - fieldName: values - orderByDirections: - enableAll: true - graphql: - selectMany: - queryRootField: net_conntrack_listener_conn_accepted_total - selectUniques: [] - argumentsInputType: net_conntrack_listener_conn_accepted_total_arguments - orderByExpressionType: net_conntrack_listener_conn_accepted_total_order_by - description: Total number of connections opened to the listener of a given name. - ---- -kind: ModelPermissions -version: v1 -definition: - modelName: net_conntrack_listener_conn_accepted_total - permissions: - - role: admin - select: - filter: null - diff --git a/tests/engine/app/metadata/net_conntrack_listener_conn_closed_total.hml b/tests/engine/app/metadata/net_conntrack_listener_conn_closed_total.hml deleted file mode 100644 index 245d5d5..0000000 --- a/tests/engine/app/metadata/net_conntrack_listener_conn_closed_total.hml +++ /dev/null @@ -1,599 +0,0 @@ ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotalLabelJoinInput - description: Input arguments for the label_join function - fields: - - name: dest_label - type: String! - description: The destination label name - - name: separator - type: String! - description: The separator between source labels - - name: source_labels - type: "[NetConntrackListenerConnClosedTotalLabel!]!" - description: Source labels - graphql: - typeName: NetConntrackListenerConnClosedTotalLabelJoinInput - inputTypeName: NetConntrackListenerConnClosedTotalLabelJoinInput_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnClosedTotalLabelJoinInput - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnClosedTotalLabelJoinInput - permissions: - - role: admin - output: - allowedFields: - - dest_label - - separator - - source_labels - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotalLabelReplaceInput - description: Input arguments for the label_replace function - fields: - - name: dest_label - type: String! - description: The destination label name - - name: regex - type: String! - description: The regular expression against the value of the source label - - name: replacement - type: String! - description: The replacement value - - name: source_label - type: NetConntrackListenerConnClosedTotalLabel! - description: Source label - graphql: - typeName: NetConntrackListenerConnClosedTotalLabelReplaceInput - inputTypeName: NetConntrackListenerConnClosedTotalLabelReplaceInput_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnClosedTotalLabelReplaceInput - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnClosedTotalLabelReplaceInput - permissions: - - role: admin - output: - allowedFields: - - dest_label - - regex - - replacement - - source_label - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotalFunctions - fields: - - name: abs - type: Boolean - description: Returns the input vector with all sample values converted to their - absolute value - - name: absent - type: Boolean - description: Returns an empty vector if the vector passed to it has any elements - (floats or native histograms) and a 1-element vector with the value 1 if - the vector passed to it has no elements - - name: absent_over_time - type: RangeResolution - description: Returns an empty vector if the range vector passed to it has any - elements (floats or native histograms) and a 1-element vector with the - value 1 if the range vector passed to it has no elements - - name: acos - type: Boolean - description: Calculates the arccosine of all elements in v - - name: acosh - type: Boolean - description: Calculates the inverse hyperbolic cosine of all elements in v - - name: asin - type: Boolean - description: Calculates the arcsine of all elements in v - - name: asinh - type: Boolean - description: Calculates the inverse hyperbolic sine of all elements in v - - name: atan - type: Boolean - description: Calculates the arctangent of all elements in v - - name: atanh - type: Boolean - description: Calculates the inverse hyperbolic tangent of all elements in v - - name: avg - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: avg_over_time - type: RangeResolution - description: The average value of all points in the specified interval - - name: bottomk - type: Int64 - description: Smallest k elements by sample value - - name: ceil - type: Boolean - description: Rounds the sample values of all elements in v up to the nearest - integer value greater than or equal to v - - name: changes - type: RangeResolution - description: Returns the number of times its value has changed within the - provided time range as an instant vector - - name: clamp - type: ValueBoundaryInput - description: Clamps the sample values of all elements in v to have a lower limit - of min and an upper limit of max - - name: clamp_max - type: Float64 - description: Clamps the sample values of all elements in v to have an upper - limit of max - - name: clamp_min - type: Float64 - description: Clamps the sample values of all elements in v to have a lower limit - of min - - name: cos - type: Boolean - description: Calculates the cosine of all elements in v - - name: cosh - type: Boolean - description: Calculates the hyperbolic cosine of all elements in v - - name: count - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: count_over_time - type: RangeResolution - description: The count of all values in the specified interval - - name: count_values - type: NetConntrackListenerConnClosedTotalLabel - - name: deg - type: Boolean - description: Converts radians to degrees for all elements in v - - name: delta - type: RangeResolution - description: Calculates the difference between the first and last value of each - time series element in a range vector v, returning an instant vector - with the given deltas and equivalent labels - - name: deriv - type: RangeResolution - description: Calculates the per-second derivative of the time series in a range - vector v, using simple linear regression - - name: exp - type: Boolean - description: Calculates the exponential function for all elements in v - - name: floor - type: Boolean - description: Rounds the sample values of all elements in v down to the nearest - integer value smaller than or equal to v - - name: group - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: histogram_avg - type: Boolean - description: Returns the arithmetic average of observed values stored in a - native histogram. Samples that are not native histograms are ignored and - do not show up in the returned vector - - name: histogram_count - type: Boolean - description: Returns the count of observations stored in a native histogram. - Samples that are not native histograms are ignored and do not show up in - the returned vector - - name: histogram_fraction - type: ValueBoundaryInput - description: Returns the estimated fraction of observations between the provided - lower and upper values. Samples that are not native histograms are - ignored and do not show up in the returned vector - - name: histogram_quantile - type: Float64 - description: Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or - from a native histogram - - name: histogram_stddev - type: Boolean - description: Returns the estimated standard deviation of observations in a - native histogram, based on the geometric mean of the buckets where the - observations lie. Samples that are not native histograms are ignored and - do not show up in the returned vector - - name: histogram_stdvar - type: Boolean - description: Returns the estimated standard variance of observations in a native - histogram - - name: histogram_sum - type: Boolean - description: Returns the sum of observations stored in a native histogram - - name: holt_winters - type: HoltWintersInput - description: Produces a smoothed value for time series based on the range in v - - name: idelta - type: RangeResolution - description: Calculates the difference between the last two samples in the range - vector v, returning an instant vector with the given deltas and - equivalent labels - - name: increase - type: RangeResolution - description: Calculates the increase in the time series in the range vector. - Breaks in monotonicity (such as counter resets due to target restarts) - are automatically adjusted for - - name: irate - type: RangeResolution - description: Calculates the per-second instant rate of increase of the time - series in the range vector. This is based on the last two data points - - name: label_join - type: NetConntrackListenerConnClosedTotalLabelJoinInput - description: Joins all the values of all the src_labels using separator and - returns the timeseries with the label dst_label containing the joined - value - - name: label_replace - type: NetConntrackListenerConnClosedTotalLabelReplaceInput - description: Matches the regular expression regex against the value of the label - src_label. If it matches, the value of the label dst_label in the - returned timeseries will be the expansion of replacement, together with - the original labels in the input - - name: last_over_time - type: RangeResolution - description: The most recent point value in the specified interval - - name: limit_ratio - type: Float64 - description: Sample elements with approximately 𝑟 ratio if 𝑟 > 0, and the - complement of such samples if 𝑟 = -(1.0 - 𝑟)) - - name: limitk - type: Int64 - description: Limit sample n elements - - name: ln - type: Boolean - description: Calculates the natural logarithm for all elements in v - - name: log2 - type: Boolean - description: Calculates the binary logarithm for all elements in v - - name: log10 - type: Boolean - description: Calculates the decimal logarithm for all elements in v - - name: mad_over_time - type: RangeResolution - description: The median absolute deviation of all points in the specified interval - - name: max - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: max_over_time - type: RangeResolution - description: The maximum value of all points in the specified interval - - name: min - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: min_over_time - type: RangeResolution - description: The minimum value of all points in the specified interval - - name: predict_linear - type: PredictLinearInput - description: Predicts the value of time series t seconds from now, based on the - range vector v, using simple linear regression - - name: present_over_time - type: RangeResolution - description: The value 1 for any series in the specified interval - - name: quantile - type: Float64 - description: Calculate φ-quantile (0 ≤ φ ≤ 1) over dimensions - - name: quantile_over_time - type: QuantileOverTimeInput - description: The φ-quantile (0 ≤ φ ≤ 1) of the values in the specified interval - - name: rad - type: Boolean - description: Converts degrees to radians for all elements in v - - name: rate - type: RangeResolution - description: Calculates the per-second average rate of increase of the time - series in the range vector - - name: resets - type: RangeResolution - description: Returns the number of counter resets within the provided time range - as an instant vector - - name: round - type: Float64 - description: Rounds the sample values of all elements in v to the nearest integer - - name: scalar - type: Boolean - description: Returns the sample value of that single element as a scalar - - name: sgn - type: Boolean - description: "Returns a vector with all sample values converted to their sign, - defined as this: 1 if v is positive, -1 if v is negative and 0 if v is - equal to zero" - - name: sin - type: Boolean - description: Calculates the sine of all elements in v - - name: sinh - type: Boolean - description: Calculates the hyperbolic sine of all elements in v - - name: sort - type: Boolean - description: Returns vector elements sorted by their sample values, in ascending - order. Native histograms are sorted by their sum of observations - - name: sort_by_label - type: "[NetConntrackListenerConnClosedTotalLabel!]" - description: Returns vector elements sorted by their label values and sample - value in case of label values being equal, in ascending order - - name: sort_by_label_desc - type: "[NetConntrackListenerConnClosedTotalLabel!]" - description: Same as sort_by_label, but sorts in descending order - - name: sort_desc - type: Boolean - description: Same as sort, but sorts in descending order - - name: sqrt - type: Boolean - description: Calculates the square root of all elements in v - - name: stddev - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: stddev_over_time - type: RangeResolution - description: The population standard deviation of the values in the specified interval - - name: stdvar - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: stdvar_over_time - type: RangeResolution - description: The population standard variance of the values in the specified interval - - name: sum - type: "[NetConntrackListenerConnClosedTotalLabel!]" - - name: sum_over_time - type: RangeResolution - description: The sum of all values in the specified interval - - name: tan - type: Boolean - description: Calculates the tangent of all elements in v - - name: tanh - type: Boolean - description: Calculates the hyperbolic tangent of all elements in v - - name: timestamp - type: Boolean - description: Returns the timestamp of each of the samples of the given vector as - the number of seconds since January 1, 1970 UTC. It also works with - histogram samples - - name: topk - type: Int64 - description: Largest k elements by sample value - graphql: - typeName: NetConntrackListenerConnClosedTotalFunctions - inputTypeName: NetConntrackListenerConnClosedTotalFunctions_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnClosedTotalFunctions - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnClosedTotalFunctions - permissions: - - role: admin - output: - allowedFields: - - abs - - absent - - absent_over_time - - acos - - acosh - - asin - - asinh - - atan - - atanh - - avg - - avg_over_time - - bottomk - - ceil - - changes - - clamp - - clamp_max - - clamp_min - - cos - - cosh - - count - - count_over_time - - count_values - - deg - - delta - - deriv - - exp - - floor - - group - - histogram_avg - - histogram_count - - histogram_fraction - - histogram_quantile - - histogram_stddev - - histogram_stdvar - - histogram_sum - - holt_winters - - idelta - - increase - - irate - - label_join - - label_replace - - last_over_time - - limit_ratio - - limitk - - ln - - log2 - - log10 - - mad_over_time - - max - - max_over_time - - min - - min_over_time - - predict_linear - - present_over_time - - quantile - - quantile_over_time - - rad - - rate - - resets - - round - - scalar - - sgn - - sin - - sinh - - sort - - sort_by_label - - sort_by_label_desc - - sort_desc - - sqrt - - stddev - - stddev_over_time - - stdvar - - stdvar_over_time - - sum - - sum_over_time - - tan - - tanh - - timestamp - - topk - ---- -kind: ObjectType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotal - fields: - - name: instance - type: String! - - name: job - type: String! - - name: labels - type: LabelSet! - description: Labels of the metric - - name: listener_name - type: String! - - name: timestamp - type: Timestamp! - description: An instant timestamp or the last timestamp of a range query result - - name: value - type: Decimal! - description: Value of the instant query or the last value of a range query - - name: values - type: "[QueryResultValue!]!" - description: An array of query result values - graphql: - typeName: NetConntrackListenerConnClosedTotal - inputTypeName: NetConntrackListenerConnClosedTotal_input - dataConnectorTypeMapping: - - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnClosedTotal - ---- -kind: TypePermissions -version: v1 -definition: - typeName: NetConntrackListenerConnClosedTotal - permissions: - - role: admin - output: - allowedFields: - - instance - - job - - labels - - listener_name - - timestamp - - value - - values - ---- -kind: ObjectBooleanExpressionType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotal_bool_exp - objectType: NetConntrackListenerConnClosedTotal - dataConnectorName: prometheus - dataConnectorObjectType: NetConntrackListenerConnClosedTotal - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: listener_name - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true - graphql: - typeName: NetConntrackListenerConnClosedTotal_bool_exp - ---- -kind: Model -version: v1 -definition: - name: net_conntrack_listener_conn_closed_total - objectType: NetConntrackListenerConnClosedTotal - arguments: - - name: fn - type: "[NetConntrackListenerConnClosedTotalFunctions!]" - description: PromQL aggregation operators and functions for - net_conntrack_listener_conn_closed_total - - name: offset - type: Duration - description: The offset modifier allows changing the time offset for individual - instant and range vectors in a query. - - name: step - type: Duration - description: Query resolution step width in duration format or float number of - seconds. - - name: timeout - type: Duration - description: Evaluation timeout - source: - dataConnectorName: prometheus - collection: net_conntrack_listener_conn_closed_total - filterExpressionType: NetConntrackListenerConnClosedTotal_bool_exp - orderableFields: - - fieldName: instance - orderByDirections: - enableAll: true - - fieldName: job - orderByDirections: - enableAll: true - - fieldName: labels - orderByDirections: - enableAll: true - - fieldName: listener_name - orderByDirections: - enableAll: true - - fieldName: timestamp - orderByDirections: - enableAll: true - - fieldName: value - orderByDirections: - enableAll: true - - fieldName: values - orderByDirections: - enableAll: true - graphql: - selectMany: - queryRootField: net_conntrack_listener_conn_closed_total - selectUniques: [] - argumentsInputType: net_conntrack_listener_conn_closed_total_arguments - orderByExpressionType: net_conntrack_listener_conn_closed_total_order_by - description: Total number of connections closed that were made to the listener - of a given name. - ---- -kind: ModelPermissions -version: v1 -definition: - modelName: net_conntrack_listener_conn_closed_total - permissions: - - role: admin - select: - filter: null - diff --git a/tests/engine/app/metadata/process_cpu_seconds_total.hml b/tests/engine/app/metadata/process_cpu_seconds_total.hml index 305bdb9..cf07ece 100644 --- a/tests/engine/app/metadata/process_cpu_seconds_total.hml +++ b/tests/engine/app/metadata/process_cpu_seconds_total.hml @@ -82,19 +82,16 @@ definition: fields: - name: abs type: Boolean - description: - Returns the input vector with all sample values converted to their + description: Returns the input vector with all sample values converted to their absolute value - name: absent type: Boolean - description: - Returns an empty vector if the vector passed to it has any elements + description: Returns an empty vector if the vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the vector passed to it has no elements - name: absent_over_time type: RangeResolution - description: - Returns an empty vector if the range vector passed to it has any + description: Returns an empty vector if the range vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the range vector passed to it has no elements - name: acos @@ -125,8 +122,7 @@ definition: description: Smallest k elements by sample value - name: ceil type: Boolean - description: - Rounds the sample values of all elements in v up to the nearest + description: Rounds the sample values of all elements in v up to the nearest integer value greater than or equal to v - name: changes type: RangeResolution @@ -134,18 +130,15 @@ definition: provided time range as an instant vector - name: clamp type: ValueBoundaryInput - description: - Clamps the sample values of all elements in v to have a lower limit + description: Clamps the sample values of all elements in v to have a lower limit of min and an upper limit of max - name: clamp_max type: Float64 - description: - Clamps the sample values of all elements in v to have an upper + description: Clamps the sample values of all elements in v to have an upper limit of max - name: clamp_min type: Float64 - description: - Clamps the sample values of all elements in v to have a lower limit + description: Clamps the sample values of all elements in v to have a lower limit of min - name: cos type: Boolean @@ -165,22 +158,19 @@ definition: description: Converts radians to degrees for all elements in v - name: delta type: RangeResolution - description: - Calculates the difference between the first and last value of each + description: Calculates the difference between the first and last value of each time series element in a range vector v, returning an instant vector with the given deltas and equivalent labels - name: deriv type: RangeResolution - description: - Calculates the per-second derivative of the time series in a range + description: Calculates the per-second derivative of the time series in a range vector v, using simple linear regression - name: exp type: Boolean description: Calculates the exponential function for all elements in v - name: floor type: Boolean - description: - Rounds the sample values of all elements in v down to the nearest + description: Rounds the sample values of all elements in v down to the nearest integer value smaller than or equal to v - name: group type: "[ProcessCpuSecondsTotalLabel!]" @@ -191,20 +181,17 @@ definition: do not show up in the returned vector - name: histogram_count type: Boolean - description: - Returns the count of observations stored in a native histogram. + description: Returns the count of observations stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector - name: histogram_fraction type: ValueBoundaryInput - description: - Returns the estimated fraction of observations between the provided + description: Returns the estimated fraction of observations between the provided lower and upper values. Samples that are not native histograms are ignored and do not show up in the returned vector - name: histogram_quantile type: Float64 - description: - Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or + description: Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or from a native histogram - name: histogram_stddev type: Boolean @@ -214,8 +201,7 @@ definition: do not show up in the returned vector - name: histogram_stdvar type: Boolean - description: - Returns the estimated standard variance of observations in a native + description: Returns the estimated standard variance of observations in a native histogram - name: histogram_sum type: Boolean @@ -225,31 +211,26 @@ definition: description: Produces a smoothed value for time series based on the range in v - name: idelta type: RangeResolution - description: - Calculates the difference between the last two samples in the range + description: Calculates the difference between the last two samples in the range vector v, returning an instant vector with the given deltas and equivalent labels - name: increase type: RangeResolution - description: - Calculates the increase in the time series in the range vector. + description: Calculates the increase in the time series in the range vector. Breaks in monotonicity (such as counter resets due to target restarts) are automatically adjusted for - name: irate type: RangeResolution - description: - Calculates the per-second instant rate of increase of the time + description: Calculates the per-second instant rate of increase of the time series in the range vector. This is based on the last two data points - name: label_join type: ProcessCpuSecondsTotalLabelJoinInput - description: - Joins all the values of all the src_labels using separator and + description: Joins all the values of all the src_labels using separator and returns the timeseries with the label dst_label containing the joined value - name: label_replace type: ProcessCpuSecondsTotalLabelReplaceInput - description: - Matches the regular expression regex against the value of the label + description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input @@ -287,8 +268,7 @@ definition: description: The minimum value of all points in the specified interval - name: predict_linear type: PredictLinearInput - description: - Predicts the value of time series t seconds from now, based on the + description: Predicts the value of time series t seconds from now, based on the range vector v, using simple linear regression - name: present_over_time type: RangeResolution @@ -304,13 +284,11 @@ definition: description: Converts degrees to radians for all elements in v - name: rate type: RangeResolution - description: - Calculates the per-second average rate of increase of the time + description: Calculates the per-second average rate of increase of the time series in the range vector - name: resets type: RangeResolution - description: - Returns the number of counter resets within the provided time range + description: Returns the number of counter resets within the provided time range as an instant vector - name: round type: Float64 @@ -320,8 +298,7 @@ definition: description: Returns the sample value of that single element as a scalar - name: sgn type: Boolean - description: - "Returns a vector with all sample values converted to their sign, + description: "Returns a vector with all sample values converted to their sign, defined as this: 1 if v is positive, -1 if v is negative and 0 if v is equal to zero" - name: sin @@ -332,13 +309,11 @@ definition: description: Calculates the hyperbolic sine of all elements in v - name: sort type: Boolean - description: - Returns vector elements sorted by their sample values, in ascending + description: Returns vector elements sorted by their sample values, in ascending order. Native histograms are sorted by their sum of observations - name: sort_by_label type: "[ProcessCpuSecondsTotalLabel!]" - description: - Returns vector elements sorted by their label values and sample + description: Returns vector elements sorted by their label values and sample value in case of label values being equal, in ascending order - name: sort_by_label_desc type: "[ProcessCpuSecondsTotalLabel!]" @@ -372,8 +347,7 @@ definition: description: Calculates the hyperbolic tangent of all elements in v - name: timestamp type: Boolean - description: - Returns the timestamp of each of the samples of the given vector as + description: Returns the timestamp of each of the samples of the given vector as the number of seconds since January 1, 1970 UTC. It also works with histogram samples - name: topk @@ -521,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessCpuSecondsTotal_bool_exp - objectType: ProcessCpuSecondsTotal - dataConnectorName: prometheus - dataConnectorObjectType: ProcessCpuSecondsTotal - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessCpuSecondsTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessCpuSecondsTotal_bool_exp @@ -562,13 +533,11 @@ definition: description: PromQL aggregation operators and functions for process_cpu_seconds_total - name: offset type: Duration - description: - The offset modifier allows changing the time offset for individual + description: The offset modifier allows changing the time offset for individual instant and range vectors in a query. - name: step type: Duration - description: - Query resolution step width in duration format or float number of + description: Query resolution step width in duration format or float number of seconds. - name: timeout type: Duration @@ -593,9 +562,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_cpu_seconds_total @@ -612,9 +578,5 @@ definition: permissions: - role: admin select: - filter: - fieldComparison: - field: job - operator: _in - value: - sessionVariable: x-hasura-jobs + filter: null + diff --git a/tests/engine/app/metadata/process_max_fds.hml b/tests/engine/app/metadata/process_max_fds.hml index 6251ddf..fc29e8e 100644 --- a/tests/engine/app/metadata/process_max_fds.hml +++ b/tests/engine/app/metadata/process_max_fds.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessMaxFds_bool_exp - objectType: ProcessMaxFds - dataConnectorName: prometheus - dataConnectorObjectType: ProcessMaxFds - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessMaxFds + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessMaxFds_bool_exp @@ -565,9 +562,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_max_fds diff --git a/tests/engine/app/metadata/process_network_receive_bytes_total.hml b/tests/engine/app/metadata/process_network_receive_bytes_total.hml index 8b0f88e..88da5c6 100644 --- a/tests/engine/app/metadata/process_network_receive_bytes_total.hml +++ b/tests/engine/app/metadata/process_network_receive_bytes_total.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessNetworkReceiveBytesTotal_bool_exp - objectType: ProcessNetworkReceiveBytesTotal - dataConnectorName: prometheus - dataConnectorObjectType: ProcessNetworkReceiveBytesTotal - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessNetworkReceiveBytesTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessNetworkReceiveBytesTotal_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_network_receive_bytes_total diff --git a/tests/engine/app/metadata/process_network_transmit_bytes_total.hml b/tests/engine/app/metadata/process_network_transmit_bytes_total.hml index ef5bcf1..86f1ba2 100644 --- a/tests/engine/app/metadata/process_network_transmit_bytes_total.hml +++ b/tests/engine/app/metadata/process_network_transmit_bytes_total.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessNetworkTransmitBytesTotal_bool_exp - objectType: ProcessNetworkTransmitBytesTotal - dataConnectorName: prometheus - dataConnectorObjectType: ProcessNetworkTransmitBytesTotal - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessNetworkTransmitBytesTotal + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessNetworkTransmitBytesTotal_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_network_transmit_bytes_total diff --git a/tests/engine/app/metadata/process_open_fds.hml b/tests/engine/app/metadata/process_open_fds.hml index 5684db1..ca8848d 100644 --- a/tests/engine/app/metadata/process_open_fds.hml +++ b/tests/engine/app/metadata/process_open_fds.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessOpenFds_bool_exp - objectType: ProcessOpenFds - dataConnectorName: prometheus - dataConnectorObjectType: ProcessOpenFds - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessOpenFds + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessOpenFds_bool_exp @@ -565,9 +562,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_open_fds diff --git a/tests/engine/app/metadata/process_resident_memory_bytes.hml b/tests/engine/app/metadata/process_resident_memory_bytes.hml index 67eadbe..2392385 100644 --- a/tests/engine/app/metadata/process_resident_memory_bytes.hml +++ b/tests/engine/app/metadata/process_resident_memory_bytes.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessResidentMemoryBytes_bool_exp - objectType: ProcessResidentMemoryBytes - dataConnectorName: prometheus - dataConnectorObjectType: ProcessResidentMemoryBytes - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessResidentMemoryBytes + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessResidentMemoryBytes_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_resident_memory_bytes diff --git a/tests/engine/app/metadata/process_start_time_seconds.hml b/tests/engine/app/metadata/process_start_time_seconds.hml index 49f8607..ad26a2c 100644 --- a/tests/engine/app/metadata/process_start_time_seconds.hml +++ b/tests/engine/app/metadata/process_start_time_seconds.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessStartTimeSeconds_bool_exp - objectType: ProcessStartTimeSeconds - dataConnectorName: prometheus - dataConnectorObjectType: ProcessStartTimeSeconds - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessStartTimeSeconds + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessStartTimeSeconds_bool_exp @@ -565,9 +562,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_start_time_seconds diff --git a/tests/engine/app/metadata/process_virtual_memory_bytes.hml b/tests/engine/app/metadata/process_virtual_memory_bytes.hml index 89d2f2b..daccb18 100644 --- a/tests/engine/app/metadata/process_virtual_memory_bytes.hml +++ b/tests/engine/app/metadata/process_virtual_memory_bytes.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessVirtualMemoryBytes_bool_exp - objectType: ProcessVirtualMemoryBytes - dataConnectorName: prometheus - dataConnectorObjectType: ProcessVirtualMemoryBytes - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessVirtualMemoryBytes + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessVirtualMemoryBytes_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_virtual_memory_bytes diff --git a/tests/engine/app/metadata/process_virtual_memory_max_bytes.hml b/tests/engine/app/metadata/process_virtual_memory_max_bytes.hml index 98b7bba..3b4c43a 100644 --- a/tests/engine/app/metadata/process_virtual_memory_max_bytes.hml +++ b/tests/engine/app/metadata/process_virtual_memory_max_bytes.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: ProcessVirtualMemoryMaxBytes_bool_exp - objectType: ProcessVirtualMemoryMaxBytes - dataConnectorName: prometheus - dataConnectorObjectType: ProcessVirtualMemoryMaxBytes - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: ProcessVirtualMemoryMaxBytes + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: ProcessVirtualMemoryMaxBytes_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: process_virtual_memory_max_bytes diff --git a/tests/engine/app/metadata/prometheus-types.hml b/tests/engine/app/metadata/prometheus-types.hml index 139841e..f33c016 100644 --- a/tests/engine/app/metadata/prometheus-types.hml +++ b/tests/engine/app/metadata/prometheus-types.hml @@ -7,160 +7,298 @@ definition: typeName: RangeResolution --- -kind: ScalarType +kind: BooleanExpressionType version: v1 definition: - name: NetConntrackDialerConnAttemptedTotalLabel + name: RangeResolution_bool_exp + operand: + scalar: + type: RangeResolution + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: RangeResolution + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - typeName: NetConntrackDialerConnAttemptedTotalLabel + typeName: RangeResolution_bool_exp --- kind: ScalarType version: v1 definition: - name: Int64 + name: NetConntrackDialerConnAttemptedTotalLabel graphql: - typeName: Int64 + typeName: NetConntrackDialerConnAttemptedTotalLabel --- -kind: ScalarType +kind: BooleanExpressionType version: v1 definition: - name: Float64 + name: NetConntrackDialerConnAttemptedTotalLabel_bool_exp + operand: + scalar: + type: NetConntrackDialerConnAttemptedTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: NetConntrackDialerConnAttemptedTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - typeName: Float64 + typeName: NetConntrackDialerConnAttemptedTotalLabel_bool_exp --- kind: ScalarType version: v1 definition: - name: Duration + name: Int64 graphql: - typeName: Duration + typeName: Int64 --- -kind: ScalarType +kind: BooleanExpressionType version: v1 definition: - name: LabelSet + name: Int64_bool_exp + operand: + scalar: + type: Int64 + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: Int64 + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - typeName: LabelSet + typeName: Int64_bool_exp --- kind: ScalarType version: v1 definition: - name: Timestamp + name: Float64 graphql: - typeName: Timestamp + typeName: Float64 --- -kind: ScalarType +kind: BooleanExpressionType version: v1 definition: - name: Decimal + name: Float64_bool_exp + operand: + scalar: + type: Float64 + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: Float64 + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - typeName: Decimal + typeName: Float64_bool_exp --- -kind: DataConnectorScalarRepresentation +kind: ScalarType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: Boolean - representation: Boolean + name: Duration graphql: - comparisonExpressionTypeName: Boolean_comparison_exp + typeName: Duration --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: RangeResolution - representation: RangeResolution + name: Duration_bool_exp + operand: + scalar: + type: Duration + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: Duration + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: RangeResolution_comparison_exp + typeName: Duration_bool_exp --- -kind: DataConnectorScalarRepresentation +kind: ScalarType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackDialerConnAttemptedTotalLabel - representation: NetConntrackDialerConnAttemptedTotalLabel + name: LabelSet graphql: - comparisonExpressionTypeName: NetConntrackDialerConnAttemptedTotalLabel_comparison_exp + typeName: LabelSet --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: Int64 - representation: Int64 + name: LabelSet_bool_exp + operand: + scalar: + type: LabelSet + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: LabelSet + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: Int64_comparison_exp + typeName: LabelSet_bool_exp --- -kind: DataConnectorScalarRepresentation +kind: ScalarType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: Float64 - representation: Float64 + name: Timestamp graphql: - comparisonExpressionTypeName: Float64_comparison_exp + typeName: Timestamp --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: String - representation: String + name: Timestamp_bool_exp + operand: + scalar: + type: Timestamp + comparisonOperators: + - name: _eq + argumentType: Timestamp! + - name: _gt + argumentType: String! + - name: _lt + argumentType: String! + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: Timestamp + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: String_comparison_exp + typeName: Timestamp_bool_exp --- -kind: DataConnectorScalarRepresentation +kind: ScalarType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: Duration - representation: Duration + name: Decimal graphql: - comparisonExpressionTypeName: Duration_comparison_exp + typeName: Decimal --- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: LabelSet - representation: LabelSet - graphql: - comparisonExpressionTypeName: LabelSet_comparison_exp +kind: BooleanExpressionType +version: v1 +definition: + name: Decimal_bool_exp + operand: + scalar: + type: Decimal + comparisonOperators: + - name: _eq + argumentType: Decimal! + - name: _gt + argumentType: Decimal! + - name: _gte + argumentType: Decimal! + - name: _lt + argumentType: Decimal! + - name: _lte + argumentType: Decimal! + - name: _neq + argumentType: Decimal! + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: Decimal + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true + graphql: + typeName: Decimal_bool_exp --- -kind: DataConnectorScalarRepresentation +kind: ScalarType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: Timestamp - representation: Timestamp + name: JSON graphql: - comparisonExpressionTypeName: Timestamp_comparison_exp + typeName: JSON --- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: Decimal - representation: Decimal - graphql: - comparisonExpressionTypeName: Decimal_comparison_exp +kind: BooleanExpressionType +version: v1 +definition: + name: JSON_bool_exp + operand: + scalar: + type: JSON + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: JSON + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true + graphql: + typeName: JSON_bool_exp + +--- +kind: BooleanExpressionType +version: v1 +definition: + name: String_bool_exp + operand: + scalar: + type: String + comparisonOperators: + - name: _eq + argumentType: String! + - name: _in + argumentType: JSON! + - name: _neq + argumentType: String! + - name: _nin + argumentType: "[String!]!" + - name: _nregex + argumentType: String! + - name: _regex + argumentType: String! + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: String + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true + graphql: + typeName: String_bool_exp --- kind: ScalarType @@ -171,14 +309,24 @@ definition: typeName: NetConntrackDialerConnClosedTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackDialerConnClosedTotalLabel - representation: NetConntrackDialerConnClosedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel_bool_exp + operand: + scalar: + type: NetConntrackDialerConnClosedTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: NetConntrackDialerConnClosedTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: NetConntrackDialerConnClosedTotalLabel_comparison_exp + typeName: NetConntrackDialerConnClosedTotalLabel_bool_exp --- kind: ScalarType @@ -189,14 +337,24 @@ definition: typeName: NetConntrackDialerConnEstablishedTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackDialerConnEstablishedTotalLabel - representation: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel_bool_exp + operand: + scalar: + type: NetConntrackDialerConnEstablishedTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: NetConntrackDialerConnEstablishedTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: NetConntrackDialerConnEstablishedTotalLabel_comparison_exp + typeName: NetConntrackDialerConnEstablishedTotalLabel_bool_exp --- kind: ScalarType @@ -207,50 +365,24 @@ definition: typeName: NetConntrackDialerConnFailedTotalLabel --- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackDialerConnFailedTotalLabel - representation: NetConntrackDialerConnFailedTotalLabel - graphql: - comparisonExpressionTypeName: NetConntrackDialerConnFailedTotalLabel_comparison_exp - ---- -kind: ScalarType -version: v1 -definition: - name: NetConntrackListenerConnAcceptedTotalLabel - graphql: - typeName: NetConntrackListenerConnAcceptedTotalLabel - ---- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackListenerConnAcceptedTotalLabel - representation: NetConntrackListenerConnAcceptedTotalLabel - graphql: - comparisonExpressionTypeName: NetConntrackListenerConnAcceptedTotalLabel_comparison_exp - ---- -kind: ScalarType -version: v1 -definition: - name: NetConntrackListenerConnClosedTotalLabel - graphql: - typeName: NetConntrackListenerConnClosedTotalLabel - ---- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: NetConntrackListenerConnClosedTotalLabel - representation: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel_bool_exp + operand: + scalar: + type: NetConntrackDialerConnFailedTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: NetConntrackDialerConnFailedTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: NetConntrackListenerConnClosedTotalLabel_comparison_exp + typeName: NetConntrackDialerConnFailedTotalLabel_bool_exp --- kind: ScalarType @@ -261,14 +393,24 @@ definition: typeName: ProcessCpuSecondsTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessCpuSecondsTotalLabel - representation: ProcessCpuSecondsTotalLabel + name: ProcessCpuSecondsTotalLabel_bool_exp + operand: + scalar: + type: ProcessCpuSecondsTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessCpuSecondsTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessCpuSecondsTotalLabel_comparison_exp + typeName: ProcessCpuSecondsTotalLabel_bool_exp --- kind: ScalarType @@ -279,14 +421,24 @@ definition: typeName: ProcessMaxFdsLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessMaxFdsLabel - representation: ProcessMaxFdsLabel + name: ProcessMaxFdsLabel_bool_exp + operand: + scalar: + type: ProcessMaxFdsLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessMaxFdsLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessMaxFdsLabel_comparison_exp + typeName: ProcessMaxFdsLabel_bool_exp --- kind: ScalarType @@ -297,14 +449,24 @@ definition: typeName: ProcessNetworkReceiveBytesTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessNetworkReceiveBytesTotalLabel - representation: ProcessNetworkReceiveBytesTotalLabel + name: ProcessNetworkReceiveBytesTotalLabel_bool_exp + operand: + scalar: + type: ProcessNetworkReceiveBytesTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessNetworkReceiveBytesTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessNetworkReceiveBytesTotalLabel_comparison_exp + typeName: ProcessNetworkReceiveBytesTotalLabel_bool_exp --- kind: ScalarType @@ -315,14 +477,24 @@ definition: typeName: ProcessNetworkTransmitBytesTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessNetworkTransmitBytesTotalLabel - representation: ProcessNetworkTransmitBytesTotalLabel + name: ProcessNetworkTransmitBytesTotalLabel_bool_exp + operand: + scalar: + type: ProcessNetworkTransmitBytesTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessNetworkTransmitBytesTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessNetworkTransmitBytesTotalLabel_comparison_exp + typeName: ProcessNetworkTransmitBytesTotalLabel_bool_exp --- kind: ScalarType @@ -333,14 +505,24 @@ definition: typeName: ProcessOpenFdsLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessOpenFdsLabel - representation: ProcessOpenFdsLabel + name: ProcessOpenFdsLabel_bool_exp + operand: + scalar: + type: ProcessOpenFdsLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessOpenFdsLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessOpenFdsLabel_comparison_exp + typeName: ProcessOpenFdsLabel_bool_exp --- kind: ScalarType @@ -351,14 +533,24 @@ definition: typeName: ProcessResidentMemoryBytesLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessResidentMemoryBytesLabel - representation: ProcessResidentMemoryBytesLabel + name: ProcessResidentMemoryBytesLabel_bool_exp + operand: + scalar: + type: ProcessResidentMemoryBytesLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessResidentMemoryBytesLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessResidentMemoryBytesLabel_comparison_exp + typeName: ProcessResidentMemoryBytesLabel_bool_exp --- kind: ScalarType @@ -369,14 +561,24 @@ definition: typeName: ProcessStartTimeSecondsLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessStartTimeSecondsLabel - representation: ProcessStartTimeSecondsLabel + name: ProcessStartTimeSecondsLabel_bool_exp + operand: + scalar: + type: ProcessStartTimeSecondsLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessStartTimeSecondsLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessStartTimeSecondsLabel_comparison_exp + typeName: ProcessStartTimeSecondsLabel_bool_exp --- kind: ScalarType @@ -387,14 +589,24 @@ definition: typeName: ProcessVirtualMemoryBytesLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessVirtualMemoryBytesLabel - representation: ProcessVirtualMemoryBytesLabel + name: ProcessVirtualMemoryBytesLabel_bool_exp + operand: + scalar: + type: ProcessVirtualMemoryBytesLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessVirtualMemoryBytesLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessVirtualMemoryBytesLabel_comparison_exp + typeName: ProcessVirtualMemoryBytesLabel_bool_exp --- kind: ScalarType @@ -405,14 +617,24 @@ definition: typeName: ProcessVirtualMemoryMaxBytesLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: ProcessVirtualMemoryMaxBytesLabel - representation: ProcessVirtualMemoryMaxBytesLabel + name: ProcessVirtualMemoryMaxBytesLabel_bool_exp + operand: + scalar: + type: ProcessVirtualMemoryMaxBytesLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: ProcessVirtualMemoryMaxBytesLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: ProcessVirtualMemoryMaxBytesLabel_comparison_exp + typeName: ProcessVirtualMemoryMaxBytesLabel_bool_exp --- kind: ScalarType @@ -423,14 +645,24 @@ definition: typeName: PromhttpMetricHandlerErrorsTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: PromhttpMetricHandlerErrorsTotalLabel - representation: PromhttpMetricHandlerErrorsTotalLabel + name: PromhttpMetricHandlerErrorsTotalLabel_bool_exp + operand: + scalar: + type: PromhttpMetricHandlerErrorsTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: PromhttpMetricHandlerErrorsTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: PromhttpMetricHandlerErrorsTotalLabel_comparison_exp + typeName: PromhttpMetricHandlerErrorsTotalLabel_bool_exp --- kind: ScalarType @@ -441,14 +673,24 @@ definition: typeName: PromhttpMetricHandlerRequestsInFlightLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: PromhttpMetricHandlerRequestsInFlightLabel - representation: PromhttpMetricHandlerRequestsInFlightLabel + name: PromhttpMetricHandlerRequestsInFlightLabel_bool_exp + operand: + scalar: + type: PromhttpMetricHandlerRequestsInFlightLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: PromhttpMetricHandlerRequestsInFlightLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: PromhttpMetricHandlerRequestsInFlightLabel_comparison_exp + typeName: PromhttpMetricHandlerRequestsInFlightLabel_bool_exp --- kind: ScalarType @@ -459,14 +701,24 @@ definition: typeName: PromhttpMetricHandlerRequestsTotalLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: PromhttpMetricHandlerRequestsTotalLabel - representation: PromhttpMetricHandlerRequestsTotalLabel + name: PromhttpMetricHandlerRequestsTotalLabel_bool_exp + operand: + scalar: + type: PromhttpMetricHandlerRequestsTotalLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: PromhttpMetricHandlerRequestsTotalLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: PromhttpMetricHandlerRequestsTotalLabel_comparison_exp + typeName: PromhttpMetricHandlerRequestsTotalLabel_bool_exp --- kind: ScalarType @@ -477,14 +729,24 @@ definition: typeName: TargetInfoLabel --- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: TargetInfoLabel - representation: TargetInfoLabel + name: TargetInfoLabel_bool_exp + operand: + scalar: + type: TargetInfoLabel + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: TargetInfoLabel + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: TargetInfoLabel_comparison_exp + typeName: TargetInfoLabel_bool_exp --- kind: ScalarType @@ -495,12 +757,24 @@ definition: typeName: TimestampTZ --- -kind: ScalarType +kind: BooleanExpressionType version: v1 definition: - name: JSON + name: TimestampTZ_bool_exp + operand: + scalar: + type: TimestampTZ + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: TimestampTZ + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - typeName: JSON + typeName: TimestampTZ_bool_exp --- kind: ScalarType @@ -511,32 +785,22 @@ definition: typeName: AlertState --- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: TimestampTZ - representation: TimestampTZ - graphql: - comparisonExpressionTypeName: TimestampTZ_comparison_exp - ---- -kind: DataConnectorScalarRepresentation -version: v1 -definition: - dataConnectorName: prometheus - dataConnectorScalarType: JSON - representation: JSON - graphql: - comparisonExpressionTypeName: JSON_comparison_exp - ---- -kind: DataConnectorScalarRepresentation +kind: BooleanExpressionType version: v1 definition: - dataConnectorName: prometheus - dataConnectorScalarType: AlertState - representation: AlertState + name: AlertState_bool_exp + operand: + scalar: + type: AlertState + comparisonOperators: [] + dataConnectorOperatorMapping: + - dataConnectorName: prometheus + dataConnectorScalarType: AlertState + operatorMapping: {} + logicalOperators: + enable: true + isNull: + enable: true graphql: - comparisonExpressionTypeName: AlertState_comparison_exp + typeName: AlertState_bool_exp diff --git a/tests/engine/app/metadata/prometheus.hml b/tests/engine/app/metadata/prometheus.hml index 2175bd7..56a674f 100644 --- a/tests/engine/app/metadata/prometheus.hml +++ b/tests/engine/app/metadata/prometheus.hml @@ -88,7 +88,6 @@ definition: representation: type: enum one_of: - - dialer_name - instance - job aggregate_functions: {} @@ -97,18 +96,16 @@ definition: representation: type: enum one_of: - - dialer_name - - instance - job + - instance aggregate_functions: {} comparison_operators: {} NetConntrackDialerConnEstablishedTotalLabel: representation: type: enum one_of: - - job - - dialer_name - instance + - job aggregate_functions: {} comparison_operators: {} NetConntrackDialerConnFailedTotalLabel: @@ -118,25 +115,6 @@ definition: - instance - job - reason - - dialer_name - aggregate_functions: {} - comparison_operators: {} - NetConntrackListenerConnAcceptedTotalLabel: - representation: - type: enum - one_of: - - instance - - job - - listener_name - aggregate_functions: {} - comparison_operators: {} - NetConntrackListenerConnClosedTotalLabel: - representation: - type: enum - one_of: - - job - - listener_name - - instance aggregate_functions: {} comparison_operators: {} ProcessCpuSecondsTotalLabel: @@ -191,8 +169,8 @@ definition: representation: type: enum one_of: - - instance - job + - instance aggregate_functions: {} comparison_operators: {} ProcessVirtualMemoryBytesLabel: @@ -280,13 +258,13 @@ definition: representation: type: enum one_of: - - telemetry_sdk_language - telemetry_sdk_name - telemetry_sdk_version - instance - job - service_name - service_version + - telemetry_sdk_language aggregate_functions: {} comparison_operators: {} Timestamp: @@ -383,1358 +361,64 @@ definition: fields: activeAlertManagers: type: - type: array - element_type: - type: named - name: AlertManager - droppedAlertManagers: - type: - type: array - element_type: - type: named - name: AlertManager - DroppedTarget: - fields: - discoveredLabels: - type: - type: named - name: JSON - HoltWintersInput: - description: Input arguments for the holt_winters function - fields: - range: - description: The range value - type: - type: named - name: RangeResolution - sf: - description: The lower the smoothing factor sf, the more importance is given to old data. Must be between 0 and 1 - type: - type: named - name: Float64 - tf: - description: The higher the trend factor tf, the more trends in the data is considered. Must be between 0 and 1 - type: - type: named - name: Float64 - MetricMetadata: - fields: - help: - type: - type: named - name: String - metric: - type: - type: named - name: String - target: - type: - type: named - name: JSON - type: - type: - type: named - name: String - unit: - type: - type: named - name: String - NetConntrackDialerConnAttemptedTotal: - fields: - dialer_name: - type: - type: named - name: String - instance: - type: - type: named - name: String - job: - type: - type: named - name: String - labels: - description: Labels of the metric - type: - type: named - name: LabelSet - timestamp: - description: An instant timestamp or the last timestamp of a range query result - type: - type: named - name: Timestamp - value: - description: Value of the instant query or the last value of a range query - type: - type: named - name: Decimal - values: - description: An array of query result values - type: - type: array - element_type: - type: named - name: QueryResultValue - NetConntrackDialerConnAttemptedTotalFunctions: - fields: - abs: - description: Returns the input vector with all sample values converted to their absolute value - type: - type: nullable - underlying_type: - type: named - name: Boolean - absent: - description: Returns an empty vector if the vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the vector passed to it has no elements - type: - type: nullable - underlying_type: - type: named - name: Boolean - absent_over_time: - description: Returns an empty vector if the range vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the range vector passed to it has no elements - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - acos: - description: Calculates the arccosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - acosh: - description: Calculates the inverse hyperbolic cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - asin: - description: Calculates the arcsine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - asinh: - description: Calculates the inverse hyperbolic sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - atan: - description: Calculates the arctangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - atanh: - description: Calculates the inverse hyperbolic tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - avg: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - avg_over_time: - description: The average value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - bottomk: - description: Smallest k elements by sample value - type: - type: nullable - underlying_type: - type: named - name: Int64 - ceil: - description: Rounds the sample values of all elements in v up to the nearest integer value greater than or equal to v - type: - type: nullable - underlying_type: - type: named - name: Boolean - changes: - description: Returns the number of times its value has changed within the provided time range as an instant vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - clamp: - description: Clamps the sample values of all elements in v to have a lower limit of min and an upper limit of max - type: - type: nullable - underlying_type: - type: named - name: ValueBoundaryInput - clamp_max: - description: Clamps the sample values of all elements in v to have an upper limit of max - type: - type: nullable - underlying_type: - type: named - name: Float64 - clamp_min: - description: Clamps the sample values of all elements in v to have a lower limit of min - type: - type: nullable - underlying_type: - type: named - name: Float64 - cos: - description: Calculates the cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - cosh: - description: Calculates the hyperbolic cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - count: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - count_over_time: - description: The count of all values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - count_values: - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - deg: - description: Converts radians to degrees for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - delta: - description: Calculates the difference between the first and last value of each time series element in a range vector v, returning an instant vector with the given deltas and equivalent labels - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - deriv: - description: Calculates the per-second derivative of the time series in a range vector v, using simple linear regression - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - exp: - description: Calculates the exponential function for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - floor: - description: Rounds the sample values of all elements in v down to the nearest integer value smaller than or equal to v - type: - type: nullable - underlying_type: - type: named - name: Boolean - group: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - histogram_avg: - description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_count: - description: Returns the count of observations stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_fraction: - description: Returns the estimated fraction of observations between the provided lower and upper values. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: ValueBoundaryInput - histogram_quantile: - description: Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or from a native histogram - type: - type: nullable - underlying_type: - type: named - name: Float64 - histogram_stddev: - description: Returns the estimated standard deviation of observations in a native histogram, based on the geometric mean of the buckets where the observations lie. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_stdvar: - description: Returns the estimated standard variance of observations in a native histogram - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_sum: - description: Returns the sum of observations stored in a native histogram - type: - type: nullable - underlying_type: - type: named - name: Boolean - holt_winters: - description: Produces a smoothed value for time series based on the range in v - type: - type: nullable - underlying_type: - type: named - name: HoltWintersInput - idelta: - description: Calculates the difference between the last two samples in the range vector v, returning an instant vector with the given deltas and equivalent labels - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - increase: - description: Calculates the increase in the time series in the range vector. Breaks in monotonicity (such as counter resets due to target restarts) are automatically adjusted for - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - irate: - description: Calculates the per-second instant rate of increase of the time series in the range vector. This is based on the last two data points - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - label_join: - description: Joins all the values of all the src_labels using separator and returns the timeseries with the label dst_label containing the joined value - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabelJoinInput - label_replace: - description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabelReplaceInput - last_over_time: - description: The most recent point value in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - limit_ratio: - description: "Sample elements with approximately \U0001D45F ratio if \U0001D45F > 0, and the complement of such samples if \U0001D45F = -(1.0 - \U0001D45F))" - type: - type: nullable - underlying_type: - type: named - name: Float64 - limitk: - description: Limit sample n elements - type: - type: nullable - underlying_type: - type: named - name: Int64 - ln: - description: Calculates the natural logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - log2: - description: Calculates the binary logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - log10: - description: Calculates the decimal logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - mad_over_time: - description: The median absolute deviation of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - max: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - max_over_time: - description: The maximum value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - min: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - min_over_time: - description: The minimum value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - predict_linear: - description: Predicts the value of time series t seconds from now, based on the range vector v, using simple linear regression - type: - type: nullable - underlying_type: - type: named - name: PredictLinearInput - present_over_time: - description: The value 1 for any series in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - quantile: - description: Calculate φ-quantile (0 ≤ φ ≤ 1) over dimensions - type: - type: nullable - underlying_type: - type: named - name: Float64 - quantile_over_time: - description: The φ-quantile (0 ≤ φ ≤ 1) of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: QuantileOverTimeInput - rad: - description: Converts degrees to radians for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - rate: - description: Calculates the per-second average rate of increase of the time series in the range vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - resets: - description: Returns the number of counter resets within the provided time range as an instant vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - round: - description: Rounds the sample values of all elements in v to the nearest integer - type: - type: nullable - underlying_type: - type: named - name: Float64 - scalar: - description: Returns the sample value of that single element as a scalar - type: - type: nullable - underlying_type: - type: named - name: Boolean - sgn: - description: 'Returns a vector with all sample values converted to their sign, defined as this: 1 if v is positive, -1 if v is negative and 0 if v is equal to zero' - type: - type: nullable - underlying_type: - type: named - name: Boolean - sin: - description: Calculates the sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - sinh: - description: Calculates the hyperbolic sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - sort: - description: Returns vector elements sorted by their sample values, in ascending order. Native histograms are sorted by their sum of observations - type: - type: nullable - underlying_type: - type: named - name: Boolean - sort_by_label: - description: Returns vector elements sorted by their label values and sample value in case of label values being equal, in ascending order - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - sort_by_label_desc: - description: Same as sort_by_label, but sorts in descending order - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - sort_desc: - description: Same as sort, but sorts in descending order - type: - type: nullable - underlying_type: - type: named - name: Boolean - sqrt: - description: Calculates the square root of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - stddev: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - stddev_over_time: - description: The population standard deviation of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - stdvar: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - stdvar_over_time: - description: The population standard variance of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - sum: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - sum_over_time: - description: The sum of all values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - tan: - description: Calculates the tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - tanh: - description: Calculates the hyperbolic tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - timestamp: - description: Returns the timestamp of each of the samples of the given vector as the number of seconds since January 1, 1970 UTC. It also works with histogram samples - type: - type: nullable - underlying_type: - type: named - name: Boolean - topk: - description: Largest k elements by sample value - type: - type: nullable - underlying_type: - type: named - name: Int64 - NetConntrackDialerConnAttemptedTotalLabelJoinInput: - description: Input arguments for the label_join function - fields: - dest_label: - description: The destination label name - type: - type: named - name: String - separator: - description: The separator between source labels - type: - type: named - name: String - source_labels: - description: Source labels - type: - type: array - element_type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - NetConntrackDialerConnAttemptedTotalLabelReplaceInput: - description: Input arguments for the label_replace function - fields: - dest_label: - description: The destination label name - type: - type: named - name: String - regex: - description: The regular expression against the value of the source label - type: - type: named - name: String - replacement: - description: The replacement value - type: - type: named - name: String - source_label: - description: Source label - type: - type: named - name: NetConntrackDialerConnAttemptedTotalLabel - NetConntrackDialerConnClosedTotal: - fields: - dialer_name: - type: - type: named - name: String - instance: - type: - type: named - name: String - job: - type: - type: named - name: String - labels: - description: Labels of the metric - type: - type: named - name: LabelSet - timestamp: - description: An instant timestamp or the last timestamp of a range query result - type: - type: named - name: Timestamp - value: - description: Value of the instant query or the last value of a range query - type: - type: named - name: Decimal - values: - description: An array of query result values - type: - type: array - element_type: - type: named - name: QueryResultValue - NetConntrackDialerConnClosedTotalFunctions: - fields: - abs: - description: Returns the input vector with all sample values converted to their absolute value - type: - type: nullable - underlying_type: - type: named - name: Boolean - absent: - description: Returns an empty vector if the vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the vector passed to it has no elements - type: - type: nullable - underlying_type: - type: named - name: Boolean - absent_over_time: - description: Returns an empty vector if the range vector passed to it has any elements (floats or native histograms) and a 1-element vector with the value 1 if the range vector passed to it has no elements - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - acos: - description: Calculates the arccosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - acosh: - description: Calculates the inverse hyperbolic cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - asin: - description: Calculates the arcsine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - asinh: - description: Calculates the inverse hyperbolic sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - atan: - description: Calculates the arctangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - atanh: - description: Calculates the inverse hyperbolic tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - avg: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - avg_over_time: - description: The average value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - bottomk: - description: Smallest k elements by sample value - type: - type: nullable - underlying_type: - type: named - name: Int64 - ceil: - description: Rounds the sample values of all elements in v up to the nearest integer value greater than or equal to v - type: - type: nullable - underlying_type: - type: named - name: Boolean - changes: - description: Returns the number of times its value has changed within the provided time range as an instant vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - clamp: - description: Clamps the sample values of all elements in v to have a lower limit of min and an upper limit of max - type: - type: nullable - underlying_type: - type: named - name: ValueBoundaryInput - clamp_max: - description: Clamps the sample values of all elements in v to have an upper limit of max - type: - type: nullable - underlying_type: - type: named - name: Float64 - clamp_min: - description: Clamps the sample values of all elements in v to have a lower limit of min - type: - type: nullable - underlying_type: - type: named - name: Float64 - cos: - description: Calculates the cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - cosh: - description: Calculates the hyperbolic cosine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - count: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - count_over_time: - description: The count of all values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - count_values: - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - deg: - description: Converts radians to degrees for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - delta: - description: Calculates the difference between the first and last value of each time series element in a range vector v, returning an instant vector with the given deltas and equivalent labels - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - deriv: - description: Calculates the per-second derivative of the time series in a range vector v, using simple linear regression - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - exp: - description: Calculates the exponential function for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - floor: - description: Rounds the sample values of all elements in v down to the nearest integer value smaller than or equal to v - type: - type: nullable - underlying_type: - type: named - name: Boolean - group: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - histogram_avg: - description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_count: - description: Returns the count of observations stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_fraction: - description: Returns the estimated fraction of observations between the provided lower and upper values. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: ValueBoundaryInput - histogram_quantile: - description: Calculates the φ-quantile (0 ≤ φ ≤ 1) from a classic histogram or from a native histogram - type: - type: nullable - underlying_type: - type: named - name: Float64 - histogram_stddev: - description: Returns the estimated standard deviation of observations in a native histogram, based on the geometric mean of the buckets where the observations lie. Samples that are not native histograms are ignored and do not show up in the returned vector - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_stdvar: - description: Returns the estimated standard variance of observations in a native histogram - type: - type: nullable - underlying_type: - type: named - name: Boolean - histogram_sum: - description: Returns the sum of observations stored in a native histogram - type: - type: nullable - underlying_type: - type: named - name: Boolean - holt_winters: - description: Produces a smoothed value for time series based on the range in v - type: - type: nullable - underlying_type: - type: named - name: HoltWintersInput - idelta: - description: Calculates the difference between the last two samples in the range vector v, returning an instant vector with the given deltas and equivalent labels - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - increase: - description: Calculates the increase in the time series in the range vector. Breaks in monotonicity (such as counter resets due to target restarts) are automatically adjusted for - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - irate: - description: Calculates the per-second instant rate of increase of the time series in the range vector. This is based on the last two data points - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - label_join: - description: Joins all the values of all the src_labels using separator and returns the timeseries with the label dst_label containing the joined value - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnClosedTotalLabelJoinInput - label_replace: - description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input - type: - type: nullable - underlying_type: - type: named - name: NetConntrackDialerConnClosedTotalLabelReplaceInput - last_over_time: - description: The most recent point value in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - limit_ratio: - description: "Sample elements with approximately \U0001D45F ratio if \U0001D45F > 0, and the complement of such samples if \U0001D45F = -(1.0 - \U0001D45F))" - type: - type: nullable - underlying_type: - type: named - name: Float64 - limitk: - description: Limit sample n elements - type: - type: nullable - underlying_type: - type: named - name: Int64 - ln: - description: Calculates the natural logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - log2: - description: Calculates the binary logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - log10: - description: Calculates the decimal logarithm for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - mad_over_time: - description: The median absolute deviation of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - max: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - max_over_time: - description: The maximum value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - min: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - min_over_time: - description: The minimum value of all points in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - predict_linear: - description: Predicts the value of time series t seconds from now, based on the range vector v, using simple linear regression - type: - type: nullable - underlying_type: - type: named - name: PredictLinearInput - present_over_time: - description: The value 1 for any series in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - quantile: - description: Calculate φ-quantile (0 ≤ φ ≤ 1) over dimensions - type: - type: nullable - underlying_type: - type: named - name: Float64 - quantile_over_time: - description: The φ-quantile (0 ≤ φ ≤ 1) of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: QuantileOverTimeInput - rad: - description: Converts degrees to radians for all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - rate: - description: Calculates the per-second average rate of increase of the time series in the range vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - resets: - description: Returns the number of counter resets within the provided time range as an instant vector - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - round: - description: Rounds the sample values of all elements in v to the nearest integer - type: - type: nullable - underlying_type: - type: named - name: Float64 - scalar: - description: Returns the sample value of that single element as a scalar - type: - type: nullable - underlying_type: - type: named - name: Boolean - sgn: - description: 'Returns a vector with all sample values converted to their sign, defined as this: 1 if v is positive, -1 if v is negative and 0 if v is equal to zero' - type: - type: nullable - underlying_type: - type: named - name: Boolean - sin: - description: Calculates the sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - sinh: - description: Calculates the hyperbolic sine of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - sort: - description: Returns vector elements sorted by their sample values, in ascending order. Native histograms are sorted by their sum of observations - type: - type: nullable - underlying_type: - type: named - name: Boolean - sort_by_label: - description: Returns vector elements sorted by their label values and sample value in case of label values being equal, in ascending order - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - sort_by_label_desc: - description: Same as sort_by_label, but sorts in descending order - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - sort_desc: - description: Same as sort, but sorts in descending order - type: - type: nullable - underlying_type: - type: named - name: Boolean - sqrt: - description: Calculates the square root of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - stddev: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - stddev_over_time: - description: The population standard deviation of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - stdvar: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - stdvar_over_time: - description: The population standard variance of the values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - sum: - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - sum_over_time: - description: The sum of all values in the specified interval - type: - type: nullable - underlying_type: - type: named - name: RangeResolution - tan: - description: Calculates the tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - tanh: - description: Calculates the hyperbolic tangent of all elements in v - type: - type: nullable - underlying_type: - type: named - name: Boolean - timestamp: - description: Returns the timestamp of each of the samples of the given vector as the number of seconds since January 1, 1970 UTC. It also works with histogram samples - type: - type: nullable - underlying_type: + type: array + element_type: type: named - name: Boolean - topk: - description: Largest k elements by sample value + name: AlertManager + droppedAlertManagers: type: - type: nullable - underlying_type: + type: array + element_type: type: named - name: Int64 - NetConntrackDialerConnClosedTotalLabelJoinInput: - description: Input arguments for the label_join function + name: AlertManager + DroppedTarget: fields: - dest_label: - description: The destination label name + discoveredLabels: type: type: named - name: String - separator: - description: The separator between source labels + name: JSON + HoltWintersInput: + description: Input arguments for the holt_winters function + fields: + range: + description: The range value type: type: named - name: String - source_labels: - description: Source labels + name: RangeResolution + sf: + description: The lower the smoothing factor sf, the more importance is given to old data. Must be between 0 and 1 type: - type: array - element_type: - type: named - name: NetConntrackDialerConnClosedTotalLabel - NetConntrackDialerConnClosedTotalLabelReplaceInput: - description: Input arguments for the label_replace function + type: named + name: Float64 + tf: + description: The higher the trend factor tf, the more trends in the data is considered. Must be between 0 and 1 + type: + type: named + name: Float64 + MetricMetadata: fields: - dest_label: - description: The destination label name + help: type: type: named name: String - regex: - description: The regular expression against the value of the source label + metric: type: type: named name: String - replacement: - description: The replacement value + target: type: type: named - name: String - source_label: - description: Source label + name: JSON + type: type: type: named - name: NetConntrackDialerConnClosedTotalLabel - NetConntrackDialerConnEstablishedTotal: - fields: - dialer_name: + name: String + unit: type: type: named name: String + NetConntrackDialerConnAttemptedTotal: + fields: instance: type: type: named @@ -1765,7 +449,7 @@ definition: element_type: type: named name: QueryResultValue - NetConntrackDialerConnEstablishedTotalFunctions: + NetConntrackDialerConnAttemptedTotalFunctions: fields: abs: description: Returns the input vector with all sample values converted to their absolute value @@ -1837,7 +521,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel avg_over_time: description: The average value of all points in the specified interval type: @@ -1908,7 +592,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel count_over_time: description: The count of all values in the specified interval type: @@ -1921,7 +605,7 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel deg: description: Converts radians to degrees for all elements in v type: @@ -1964,7 +648,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel histogram_avg: description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector type: @@ -2048,14 +732,14 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabelJoinInput + name: NetConntrackDialerConnAttemptedTotalLabelJoinInput label_replace: description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input type: type: nullable underlying_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabelReplaceInput + name: NetConntrackDialerConnAttemptedTotalLabelReplaceInput last_over_time: description: The most recent point value in the specified interval type: @@ -2112,7 +796,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel max_over_time: description: The maximum value of all points in the specified interval type: @@ -2127,7 +811,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel min_over_time: description: The minimum value of all points in the specified interval type: @@ -2234,7 +918,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel sort_by_label_desc: description: Same as sort_by_label, but sorts in descending order type: @@ -2243,7 +927,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel sort_desc: description: Same as sort, but sorts in descending order type: @@ -2265,7 +949,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel stddev_over_time: description: The population standard deviation of the values in the specified interval type: @@ -2280,7 +964,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel stdvar_over_time: description: The population standard variance of the values in the specified interval type: @@ -2295,7 +979,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel + name: NetConntrackDialerConnAttemptedTotalLabel sum_over_time: description: The sum of all values in the specified interval type: @@ -2331,7 +1015,7 @@ definition: underlying_type: type: named name: Int64 - NetConntrackDialerConnEstablishedTotalLabelJoinInput: + NetConntrackDialerConnAttemptedTotalLabelJoinInput: description: Input arguments for the label_join function fields: dest_label: @@ -2350,8 +1034,8 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel - NetConntrackDialerConnEstablishedTotalLabelReplaceInput: + name: NetConntrackDialerConnAttemptedTotalLabel + NetConntrackDialerConnAttemptedTotalLabelReplaceInput: description: Input arguments for the label_replace function fields: dest_label: @@ -2373,13 +1057,9 @@ definition: description: Source label type: type: named - name: NetConntrackDialerConnEstablishedTotalLabel - NetConntrackDialerConnFailedTotal: + name: NetConntrackDialerConnAttemptedTotalLabel + NetConntrackDialerConnClosedTotal: fields: - dialer_name: - type: - type: named - name: String instance: type: type: named @@ -2393,10 +1073,6 @@ definition: type: type: named name: LabelSet - reason: - type: - type: named - name: String timestamp: description: An instant timestamp or the last timestamp of a range query result type: @@ -2414,7 +1090,7 @@ definition: element_type: type: named name: QueryResultValue - NetConntrackDialerConnFailedTotalFunctions: + NetConntrackDialerConnClosedTotalFunctions: fields: abs: description: Returns the input vector with all sample values converted to their absolute value @@ -2486,7 +1162,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel avg_over_time: description: The average value of all points in the specified interval type: @@ -2557,7 +1233,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel count_over_time: description: The count of all values in the specified interval type: @@ -2570,7 +1246,7 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel deg: description: Converts radians to degrees for all elements in v type: @@ -2613,7 +1289,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel histogram_avg: description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector type: @@ -2697,14 +1373,14 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackDialerConnFailedTotalLabelJoinInput + name: NetConntrackDialerConnClosedTotalLabelJoinInput label_replace: description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input type: type: nullable underlying_type: type: named - name: NetConntrackDialerConnFailedTotalLabelReplaceInput + name: NetConntrackDialerConnClosedTotalLabelReplaceInput last_over_time: description: The most recent point value in the specified interval type: @@ -2761,7 +1437,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel max_over_time: description: The maximum value of all points in the specified interval type: @@ -2776,7 +1452,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel min_over_time: description: The minimum value of all points in the specified interval type: @@ -2883,7 +1559,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel sort_by_label_desc: description: Same as sort_by_label, but sorts in descending order type: @@ -2892,7 +1568,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel sort_desc: description: Same as sort, but sorts in descending order type: @@ -2914,7 +1590,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel stddev_over_time: description: The population standard deviation of the values in the specified interval type: @@ -2929,7 +1605,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel stdvar_over_time: description: The population standard variance of the values in the specified interval type: @@ -2944,7 +1620,7 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel + name: NetConntrackDialerConnClosedTotalLabel sum_over_time: description: The sum of all values in the specified interval type: @@ -2980,7 +1656,7 @@ definition: underlying_type: type: named name: Int64 - NetConntrackDialerConnFailedTotalLabelJoinInput: + NetConntrackDialerConnClosedTotalLabelJoinInput: description: Input arguments for the label_join function fields: dest_label: @@ -2999,8 +1675,8 @@ definition: type: array element_type: type: named - name: NetConntrackDialerConnFailedTotalLabel - NetConntrackDialerConnFailedTotalLabelReplaceInput: + name: NetConntrackDialerConnClosedTotalLabel + NetConntrackDialerConnClosedTotalLabelReplaceInput: description: Input arguments for the label_replace function fields: dest_label: @@ -3022,8 +1698,8 @@ definition: description: Source label type: type: named - name: NetConntrackDialerConnFailedTotalLabel - NetConntrackListenerConnAcceptedTotal: + name: NetConntrackDialerConnClosedTotalLabel + NetConntrackDialerConnEstablishedTotal: fields: instance: type: @@ -3038,10 +1714,6 @@ definition: type: type: named name: LabelSet - listener_name: - type: - type: named - name: String timestamp: description: An instant timestamp or the last timestamp of a range query result type: @@ -3059,7 +1731,7 @@ definition: element_type: type: named name: QueryResultValue - NetConntrackListenerConnAcceptedTotalFunctions: + NetConntrackDialerConnEstablishedTotalFunctions: fields: abs: description: Returns the input vector with all sample values converted to their absolute value @@ -3131,7 +1803,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel avg_over_time: description: The average value of all points in the specified interval type: @@ -3202,7 +1874,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel count_over_time: description: The count of all values in the specified interval type: @@ -3215,7 +1887,7 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel deg: description: Converts radians to degrees for all elements in v type: @@ -3258,7 +1930,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel histogram_avg: description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector type: @@ -3342,14 +2014,14 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabelJoinInput + name: NetConntrackDialerConnEstablishedTotalLabelJoinInput label_replace: description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input type: type: nullable underlying_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabelReplaceInput + name: NetConntrackDialerConnEstablishedTotalLabelReplaceInput last_over_time: description: The most recent point value in the specified interval type: @@ -3406,7 +2078,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel max_over_time: description: The maximum value of all points in the specified interval type: @@ -3421,7 +2093,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel min_over_time: description: The minimum value of all points in the specified interval type: @@ -3528,7 +2200,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel sort_by_label_desc: description: Same as sort_by_label, but sorts in descending order type: @@ -3537,7 +2209,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel sort_desc: description: Same as sort, but sorts in descending order type: @@ -3559,7 +2231,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel stddev_over_time: description: The population standard deviation of the values in the specified interval type: @@ -3574,7 +2246,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel stdvar_over_time: description: The population standard variance of the values in the specified interval type: @@ -3589,7 +2261,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel + name: NetConntrackDialerConnEstablishedTotalLabel sum_over_time: description: The sum of all values in the specified interval type: @@ -3625,7 +2297,7 @@ definition: underlying_type: type: named name: Int64 - NetConntrackListenerConnAcceptedTotalLabelJoinInput: + NetConntrackDialerConnEstablishedTotalLabelJoinInput: description: Input arguments for the label_join function fields: dest_label: @@ -3644,8 +2316,8 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel - NetConntrackListenerConnAcceptedTotalLabelReplaceInput: + name: NetConntrackDialerConnEstablishedTotalLabel + NetConntrackDialerConnEstablishedTotalLabelReplaceInput: description: Input arguments for the label_replace function fields: dest_label: @@ -3667,8 +2339,8 @@ definition: description: Source label type: type: named - name: NetConntrackListenerConnAcceptedTotalLabel - NetConntrackListenerConnClosedTotal: + name: NetConntrackDialerConnEstablishedTotalLabel + NetConntrackDialerConnFailedTotal: fields: instance: type: @@ -3683,7 +2355,7 @@ definition: type: type: named name: LabelSet - listener_name: + reason: type: type: named name: String @@ -3704,7 +2376,7 @@ definition: element_type: type: named name: QueryResultValue - NetConntrackListenerConnClosedTotalFunctions: + NetConntrackDialerConnFailedTotalFunctions: fields: abs: description: Returns the input vector with all sample values converted to their absolute value @@ -3776,7 +2448,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel avg_over_time: description: The average value of all points in the specified interval type: @@ -3847,7 +2519,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel count_over_time: description: The count of all values in the specified interval type: @@ -3860,7 +2532,7 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel deg: description: Converts radians to degrees for all elements in v type: @@ -3903,7 +2575,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel histogram_avg: description: Returns the arithmetic average of observed values stored in a native histogram. Samples that are not native histograms are ignored and do not show up in the returned vector type: @@ -3987,14 +2659,14 @@ definition: type: nullable underlying_type: type: named - name: NetConntrackListenerConnClosedTotalLabelJoinInput + name: NetConntrackDialerConnFailedTotalLabelJoinInput label_replace: description: Matches the regular expression regex against the value of the label src_label. If it matches, the value of the label dst_label in the returned timeseries will be the expansion of replacement, together with the original labels in the input type: type: nullable underlying_type: type: named - name: NetConntrackListenerConnClosedTotalLabelReplaceInput + name: NetConntrackDialerConnFailedTotalLabelReplaceInput last_over_time: description: The most recent point value in the specified interval type: @@ -4051,7 +2723,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel max_over_time: description: The maximum value of all points in the specified interval type: @@ -4066,7 +2738,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel min_over_time: description: The minimum value of all points in the specified interval type: @@ -4173,7 +2845,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel sort_by_label_desc: description: Same as sort_by_label, but sorts in descending order type: @@ -4182,7 +2854,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel sort_desc: description: Same as sort, but sorts in descending order type: @@ -4204,7 +2876,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel stddev_over_time: description: The population standard deviation of the values in the specified interval type: @@ -4219,7 +2891,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel stdvar_over_time: description: The population standard variance of the values in the specified interval type: @@ -4234,7 +2906,7 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel sum_over_time: description: The sum of all values in the specified interval type: @@ -4270,7 +2942,7 @@ definition: underlying_type: type: named name: Int64 - NetConntrackListenerConnClosedTotalLabelJoinInput: + NetConntrackDialerConnFailedTotalLabelJoinInput: description: Input arguments for the label_join function fields: dest_label: @@ -4289,8 +2961,8 @@ definition: type: array element_type: type: named - name: NetConntrackListenerConnClosedTotalLabel - NetConntrackListenerConnClosedTotalLabelReplaceInput: + name: NetConntrackDialerConnFailedTotalLabel + NetConntrackDialerConnFailedTotalLabelReplaceInput: description: Input arguments for the label_replace function fields: dest_label: @@ -4312,7 +2984,7 @@ definition: description: Source label type: type: named - name: NetConntrackListenerConnClosedTotalLabel + name: NetConntrackDialerConnFailedTotalLabel PredictLinearInput: description: Input arguments for the predict_linear function fields: @@ -12997,78 +11669,6 @@ definition: type: NetConntrackDialerConnFailedTotal uniqueness_constraints: {} foreign_keys: {} - - name: net_conntrack_listener_conn_accepted_total - description: Total number of connections opened to the listener of a given name. - arguments: - fn: - description: PromQL aggregation operators and functions for net_conntrack_listener_conn_accepted_total - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackListenerConnAcceptedTotalFunctions - offset: - description: The offset modifier allows changing the time offset for individual instant and range vectors in a query. - type: - type: nullable - underlying_type: - type: named - name: Duration - step: - description: Query resolution step width in duration format or float number of seconds. - type: - type: nullable - underlying_type: - type: named - name: Duration - timeout: - description: Evaluation timeout - type: - type: nullable - underlying_type: - type: named - name: Duration - type: NetConntrackListenerConnAcceptedTotal - uniqueness_constraints: {} - foreign_keys: {} - - name: net_conntrack_listener_conn_closed_total - description: Total number of connections closed that were made to the listener of a given name. - arguments: - fn: - description: PromQL aggregation operators and functions for net_conntrack_listener_conn_closed_total - type: - type: nullable - underlying_type: - type: array - element_type: - type: named - name: NetConntrackListenerConnClosedTotalFunctions - offset: - description: The offset modifier allows changing the time offset for individual instant and range vectors in a query. - type: - type: nullable - underlying_type: - type: named - name: Duration - step: - description: Query resolution step width in duration format or float number of seconds. - type: - type: nullable - underlying_type: - type: named - name: Duration - timeout: - description: Evaluation timeout - type: - type: nullable - underlying_type: - type: named - name: Duration - type: NetConntrackListenerConnClosedTotal - uniqueness_constraints: {} - foreign_keys: {} - name: process_cpu_seconds_total description: Total user and system CPU time spent in seconds. arguments: diff --git a/tests/engine/app/metadata/promhttp_metric_handler_errors_total.hml b/tests/engine/app/metadata/promhttp_metric_handler_errors_total.hml index 6a81d98..fa1951e 100644 --- a/tests/engine/app/metadata/promhttp_metric_handler_errors_total.hml +++ b/tests/engine/app/metadata/promhttp_metric_handler_errors_total.hml @@ -498,35 +498,31 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: PromhttpMetricHandlerErrorsTotal_bool_exp - objectType: PromhttpMetricHandlerErrorsTotal - dataConnectorName: prometheus - dataConnectorObjectType: PromhttpMetricHandlerErrorsTotal - comparableFields: - - fieldName: cause - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: PromhttpMetricHandlerErrorsTotal + comparableFields: + - fieldName: cause + booleanExpressionType: String_bool_exp + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: PromhttpMetricHandlerErrorsTotal_bool_exp @@ -575,9 +571,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: promhttp_metric_handler_errors_total diff --git a/tests/engine/app/metadata/promhttp_metric_handler_requests_in_flight.hml b/tests/engine/app/metadata/promhttp_metric_handler_requests_in_flight.hml index 1c9afc1..7389e72 100644 --- a/tests/engine/app/metadata/promhttp_metric_handler_requests_in_flight.hml +++ b/tests/engine/app/metadata/promhttp_metric_handler_requests_in_flight.hml @@ -495,32 +495,29 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: PromhttpMetricHandlerRequestsInFlight_bool_exp - objectType: PromhttpMetricHandlerRequestsInFlight - dataConnectorName: prometheus - dataConnectorObjectType: PromhttpMetricHandlerRequestsInFlight - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: PromhttpMetricHandlerRequestsInFlight + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: PromhttpMetricHandlerRequestsInFlight_bool_exp @@ -566,9 +563,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: promhttp_metric_handler_requests_in_flight diff --git a/tests/engine/app/metadata/promhttp_metric_handler_requests_total.hml b/tests/engine/app/metadata/promhttp_metric_handler_requests_total.hml index 7394245..580fc43 100644 --- a/tests/engine/app/metadata/promhttp_metric_handler_requests_total.hml +++ b/tests/engine/app/metadata/promhttp_metric_handler_requests_total.hml @@ -498,35 +498,31 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: PromhttpMetricHandlerRequestsTotal_bool_exp - objectType: PromhttpMetricHandlerRequestsTotal - dataConnectorName: prometheus - dataConnectorObjectType: PromhttpMetricHandlerRequestsTotal - comparableFields: - - fieldName: code - operators: - enableAll: true - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: PromhttpMetricHandlerRequestsTotal + comparableFields: + - fieldName: code + booleanExpressionType: String_bool_exp + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: PromhttpMetricHandlerRequestsTotal_bool_exp @@ -575,9 +571,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: promhttp_metric_handler_requests_total diff --git a/tests/engine/app/metadata/service_up.hml b/tests/engine/app/metadata/service_up.hml index a8c9c76..a417479 100644 --- a/tests/engine/app/metadata/service_up.hml +++ b/tests/engine/app/metadata/service_up.hml @@ -1,48 +1,3 @@ ---- -kind: Command -version: v1 -definition: - name: service_up - outputType: "[ServiceUpResult!]!" - arguments: - - name: end - type: Timestamp - description: End timestamp. Use this argument if you want to run an range query - - name: instance - type: String! - - name: job - type: String! - - name: start - type: Timestamp - description: Start timestamp. Use this argument if you want to run an range query - - name: step - type: Duration - description: Query resolution step width in duration format or float number of - seconds. - - name: time - type: Timestamp - description: Evaluation timestamp. Use this argument if you want to run an - instant query - - name: timeout - type: Duration - description: Evaluation timeout - source: - dataConnectorName: prometheus - dataConnectorCommand: - function: service_up - graphql: - rootFieldName: service_up - rootFieldKind: Query - ---- -kind: CommandPermissions -version: v1 -definition: - commandName: service_up - permissions: - - role: admin - allowExecution: true - --- kind: ObjectType version: v1 @@ -88,3 +43,48 @@ definition: - value - values +--- +kind: Command +version: v1 +definition: + name: service_up + outputType: "[ServiceUpResult!]!" + arguments: + - name: end + type: Timestamp + description: End timestamp. Use this argument if you want to run an range query + - name: instance + type: String! + - name: job + type: String! + - name: start + type: Timestamp + description: Start timestamp. Use this argument if you want to run an range query + - name: step + type: Duration + description: Query resolution step width in duration format or float number of + seconds. + - name: time + type: Timestamp + description: Evaluation timestamp. Use this argument if you want to run an + instant query + - name: timeout + type: Duration + description: Evaluation timeout + source: + dataConnectorName: prometheus + dataConnectorCommand: + function: service_up + graphql: + rootFieldName: service_up + rootFieldKind: Query + +--- +kind: CommandPermissions +version: v1 +definition: + commandName: service_up + permissions: + - role: admin + allowExecution: true + diff --git a/tests/engine/app/metadata/target_info.hml b/tests/engine/app/metadata/target_info.hml index 5f54a9b..52bc6fe 100644 --- a/tests/engine/app/metadata/target_info.hml +++ b/tests/engine/app/metadata/target_info.hml @@ -510,47 +510,39 @@ definition: - values --- -kind: ObjectBooleanExpressionType +kind: BooleanExpressionType version: v1 definition: name: TargetInfo_bool_exp - objectType: TargetInfo - dataConnectorName: prometheus - dataConnectorObjectType: TargetInfo - comparableFields: - - fieldName: instance - operators: - enableAll: true - - fieldName: job - operators: - enableAll: true - - fieldName: labels - operators: - enableAll: true - - fieldName: service_name - operators: - enableAll: true - - fieldName: service_version - operators: - enableAll: true - - fieldName: telemetry_sdk_language - operators: - enableAll: true - - fieldName: telemetry_sdk_name - operators: - enableAll: true - - fieldName: telemetry_sdk_version - operators: - enableAll: true - - fieldName: timestamp - operators: - enableAll: true - - fieldName: value - operators: - enableAll: true - - fieldName: values - operators: - enableAll: true + operand: + object: + type: TargetInfo + comparableFields: + - fieldName: instance + booleanExpressionType: String_bool_exp + - fieldName: job + booleanExpressionType: String_bool_exp + - fieldName: labels + booleanExpressionType: LabelSet_bool_exp + - fieldName: service_name + booleanExpressionType: String_bool_exp + - fieldName: service_version + booleanExpressionType: String_bool_exp + - fieldName: telemetry_sdk_language + booleanExpressionType: String_bool_exp + - fieldName: telemetry_sdk_name + booleanExpressionType: String_bool_exp + - fieldName: telemetry_sdk_version + booleanExpressionType: String_bool_exp + - fieldName: timestamp + booleanExpressionType: Timestamp_bool_exp + - fieldName: value + booleanExpressionType: Decimal_bool_exp + comparableRelationships: [] + logicalOperators: + enable: true + isNull: + enable: true graphql: typeName: TargetInfo_bool_exp @@ -610,9 +602,6 @@ definition: - fieldName: value orderByDirections: enableAll: true - - fieldName: values - orderByDirections: - enableAll: true graphql: selectMany: queryRootField: target_info