diff --git a/cmd/agent-operator/DEVELOPERS.md b/cmd/agent-operator/DEVELOPERS.md index 703c947e8c8b..7ed2236e7325 100644 --- a/cmd/agent-operator/DEVELOPERS.md +++ b/cmd/agent-operator/DEVELOPERS.md @@ -41,6 +41,12 @@ go install sigs.k8s.io/controller-tools/cmd/controller-gen@v0.6.2 go install github.com/ahmetb/gen-crd-api-reference-docs@v0.3.1-0.20220618162802-424739b250f5 ``` +Use the following to run the script in a container: + +``` +docker build -t grafana/agent-build-image:latest ./build-image +BUILD_IMAGE=grafana/agent-build-image:latest USE_CONTAINER=1 make generate-crds +``` ## Testing Locally Create a k3d cluster (depending on k3d v4.x): diff --git a/docs/sources/operator/api.md b/docs/sources/operator/api.md index dd92db0d0d2d..295dd972bb54 100644 --- a/docs/sources/operator/api.md +++ b/docs/sources/operator/api.md @@ -828,13 +828,13 @@ string -

RE2 regular exprssion.

-

If source is provided, the regex will attempt +

RE2 regular expression.

+

If source is provided, the regex attempts to match the source.

-

If no source is provided, then the regex will attempt +

If no source is provided, then the regex attempts to attach the log line.

If the provided regex matches the log line or a provided source, the -line will be dropped.

+line is dropped.

@@ -860,7 +860,7 @@ string

OlderThan will be parsed as a Go duration. If the log line’s timestamp -is older than the current time minus the provided duration it will be +is older than the current time minus the provided duration, it will be dropped.

@@ -885,9 +885,9 @@ string -

Every time a log line is dropped the metric logentry_dropped_lines_total -will be incremented. A “reason” label is added, and can be customized by -providing a custom value here. Defaults to “drop_stage.”

+

Every time a log line is dropped, the metric logentry_dropped_lines_total +is incremented. A “reason” label is added, and can be customized by +providing a custom value here. Defaults to “drop_stage”.

@@ -1312,11 +1312,11 @@ bool

Integration runs a single Grafana Agent integration. Integrations that -generate telemetry must be configured to send that telemetry somewhere; such +generate telemetry must be configured to send that telemetry somewhere, such as autoscrape for exporter-based integrations.

Integrations have access to the LogsInstances and MetricsInstances in the same GrafanaAgent resource set, referenced by the / of the -*Instance resource.

+Instance resource.

For example, if there is a default/production MetricsInstance, you can configure a supported integration’s autoscrape block with:

autoscrape:
@@ -1383,7 +1383,7 @@ IntegrationType
 
 
 
-

Type informs Grafana Agent Operator how to manage the integration being +

Type informs Grafana Agent Operator about how to manage the integration being configured.

@@ -1397,7 +1397,7 @@ k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1.JSON -

The configuration for the named integration. Note that integrations are +

The configuration for the named integration. Note that Integrations are deployed with the integrations-next feature flag, which has different common settings:

https://grafana.com/docs/agent/latest/configuration/integrations/integrations-next/

@@ -1414,11 +1414,11 @@ common settings:

An extra list of Volumes to be associated with the Grafana Agent pods -running this integration. Volume names will be mutated to be unique across +running this integration. Volume names are mutated to be unique across all Integrations. Note that the specified volumes should be able to tolerate existing on multiple pods at once when type is daemonset.

-

Don’t use volumes for loading secrets/configMaps from the same namespace -as the Integration; use the secrets and configMaps fields instead.

+

Don’t use volumes for loading Secrets or ConfigMaps from the same namespace +as the Integration; use the Secrets and ConfigMaps fields instead.

@@ -1432,7 +1432,7 @@ as the Integration; use the secrets and configMaps fields instead.

An extra list of VolumeMounts to be associated with the Grafana Agent pods -running this integration. VolumeMount names will be mutated to be unique +running this integration. VolumeMount names are mutated to be unique across all used IntegrationSpecs.

Mount paths should include the namespace/name of the Integration CR to avoid potentially colliding with other resources.

@@ -1450,7 +1450,7 @@ avoid potentially colliding with other resources.

An extra list of keys from Secrets in the same namespace as the Integration which will be mounted into the Grafana Agent pod running this -integration.

+Integration.

Secrets will be mounted at /etc/grafana-agent/integrations/secrets///.

@@ -1467,8 +1467,8 @@ integration.

An extra list of keys from ConfigMaps in the same namespace as the Integration which will be mounted into the Grafana Agent pod running this -integration.

-

ConfigMaps will be mounted at +Integration.

+

ConfigMaps are mounted at /etc/grafana-agent/integrations/configMaps///.

@@ -1515,7 +1515,7 @@ IntegrationType -

Type informs Grafana Agent Operator how to manage the integration being +

Type informs Grafana Agent Operator about how to manage the integration being configured.

@@ -1529,7 +1529,7 @@ k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1.JSON -

The configuration for the named integration. Note that integrations are +

The configuration for the named integration. Note that Integrations are deployed with the integrations-next feature flag, which has different common settings:

https://grafana.com/docs/agent/latest/configuration/integrations/integrations-next/

@@ -1546,11 +1546,11 @@ common settings:

An extra list of Volumes to be associated with the Grafana Agent pods -running this integration. Volume names will be mutated to be unique across +running this integration. Volume names are mutated to be unique across all Integrations. Note that the specified volumes should be able to tolerate existing on multiple pods at once when type is daemonset.

-

Don’t use volumes for loading secrets/configMaps from the same namespace -as the Integration; use the secrets and configMaps fields instead.

+

Don’t use volumes for loading Secrets or ConfigMaps from the same namespace +as the Integration; use the Secrets and ConfigMaps fields instead.

@@ -1564,7 +1564,7 @@ as the Integration; use the secrets and configMaps fields instead.

An extra list of VolumeMounts to be associated with the Grafana Agent pods -running this integration. VolumeMount names will be mutated to be unique +running this integration. VolumeMount names are mutated to be unique across all used IntegrationSpecs.

Mount paths should include the namespace/name of the Integration CR to avoid potentially colliding with other resources.

@@ -1582,7 +1582,7 @@ avoid potentially colliding with other resources.

An extra list of keys from Secrets in the same namespace as the Integration which will be mounted into the Grafana Agent pod running this -integration.

+Integration.

Secrets will be mounted at /etc/grafana-agent/integrations/secrets///.

@@ -1599,8 +1599,8 @@ integration.

An extra list of keys from ConfigMaps in the same namespace as the Integration which will be mounted into the Grafana Agent pod running this -integration.

-

ConfigMaps will be mounted at +Integration.

+

ConfigMaps are mounted at /etc/grafana-agent/integrations/configMaps///.

@@ -1631,7 +1631,7 @@ bool

When true, the configured integration should be run on every Node in the -cluster. This is required for integrations that generate Node-specific +cluster. This is required for Integrations that generate Node-specific metrics like node_exporter, otherwise it must be false to avoid generating duplicate metrics.

@@ -1646,7 +1646,7 @@ bool

Whether this integration can only be defined once for a Grafana Agent process, such as statsd_exporter. It is invalid for a GrafanaAgent to -discover multiple unique Integrations with the same integration name +discover multiple unique Integrations with the same Integration name (i.e., a single GrafanaAgent cannot deploy two statsd_exporters).

@@ -1741,7 +1741,7 @@ map[string]string

Set of the key/value pairs of JMESPath expressions. The key will be the key in the extracted data while the expression will be the value, evaluated as a JMESPath from the source data.

-

Literal JMESPath exprssions can be done by wrapping a key in double +

Literal JMESPath expressions can be used by wrapping a key in double quotes, which then must be wrapped again in single quotes in YAML so they get passed to the JMESPath parser.

@@ -2088,7 +2088,7 @@ LogsTargetConfigSpec -

Configures how tailed targets will be watched.

+

Configures how tailed targets are watched.

@@ -2189,7 +2189,7 @@ LogsTargetConfigSpec -

Configures how tailed targets will be watched.

+

Configures how tailed targets are watched.

@@ -2221,7 +2221,7 @@ subsystem.

-

Global set of clients to use when a discovered LogsInstance does not +

A global set of clients to use when a discovered LogsInstance does not have any clients defined.

@@ -2377,8 +2377,8 @@ string

Determines what action is taken when the selector matches the log line. -Can be keep or drop. Defaults to keep. When set to drop, entries will be -dropped and no later metrics will be recorded. +Can be keep or drop. Defaults to keep. When set to drop, entries are +dropped and no later metrics are recorded. Stages must be empty when dropping metrics.

@@ -2390,8 +2390,8 @@ string -

Every time a log line is dropped the metric logentry_dropped_lines_total -will be incremented. A “reason” label is added, and can be customized by +

Every time a log line is dropped, the metric logentry_dropped_lines_total +is incremented. A “reason” label is added, and can be customized by providing a custom value here. Defaults to “match_stage.”

@@ -2403,7 +2403,7 @@ string -

Nested set of pipeline stages to execute when action: keep and the log +

Nested set of pipeline stages to execute when action is keep and the log line matches selector.

An example value for stages may be:

stages: | @@ -2968,7 +2968,7 @@ string

Label values on metrics are dynamic which can cause exported metrics to go stale. To prevent unbounded cardinality, any metrics not updated -within MaxIdleDuration will be removed.

+within MaxIdleDuration are removed.

Must be greater or equal to 1s. Defaults to 5m.

@@ -2980,7 +2980,7 @@ bool -

If true all log lines will be counted without attempting to match the +

If true, all log lines are counted without attempting to match the source to the extracted map. Mutually exclusive with value.

Only valid for type: counter.

@@ -2993,7 +2993,7 @@ bool -

If true all log line bytes will be counted. Can only be set with +

If true all log line bytes are counted. Can only be set with matchAll: true and action: add.

Only valid for type: counter.

@@ -3007,8 +3007,8 @@ string

Filters down source data and only changes the metric if the targeted -value exactly matches the provided string. If not present, all -data will match.

+value matches the provided string exactly. If not present, all +data matches.

@@ -3463,7 +3463,7 @@ object.

-

Name from extracted data or line labels. Requiried. +

Name from extracted data or line labels. Required. Labels provided here are automatically removed from output labels.

@@ -3622,7 +3622,7 @@ map[string]github.com/grafana/agent/pkg/operator/apis/monitoring/v1alpha1.Metric -

Metrics is an action stage that allows for defining and updating metrics +

Metrics is an action stage that supports defining and updating metrics based on data from the extracted map. Created metrics are not pushed to Loki or Prometheus and are instead exposed via the /metrics endpoint of the Grafana Agent pod. The Grafana Agent Operator should be configured @@ -3851,7 +3851,7 @@ github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1.Namesp -

Pipeline stages for this pod. Pipeline stages allow for transforming and +

Pipeline stages for this pod. Pipeline stages support transforming and filtering log lines.

@@ -3951,7 +3951,7 @@ github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1.Namesp -

Pipeline stages for this pod. Pipeline stages allow for transforming and +

Pipeline stages for this pod. Pipeline stages support transforming and filtering log lines.

@@ -4484,7 +4484,7 @@ string -

Go template string to use. Required. In additional to normal template +

Go template string to use. Required. In addition to normal template functions, ToLower, ToUpper, Replace, Trim, TrimLeft, TrimRight, TrimPrefix, and TrimSpace are also available.

@@ -4516,7 +4516,7 @@ string -

Name from labels to whose value should be set as tenant ID. Mutually exclusive with +

Name from labels whose value should be set as tenant ID. Mutually exclusive with source and value.

@@ -4626,5 +4626,5 @@ Can be skip or fudge. Defaults to fudge.


Generated with gen-crd-api-reference-docs -on git commit 87429255. +on git commit e19c9c42.

diff --git a/pkg/operator/apis/monitoring/v1alpha1/types_integrations.go b/pkg/operator/apis/monitoring/v1alpha1/types_integrations.go index d5ad1cef1a5e..9a6035b41eeb 100644 --- a/pkg/operator/apis/monitoring/v1alpha1/types_integrations.go +++ b/pkg/operator/apis/monitoring/v1alpha1/types_integrations.go @@ -27,12 +27,12 @@ type IntegrationsSubsystemSpec struct { // +kubebuilder:resource:categories="agent-operator" // Integration runs a single Grafana Agent integration. Integrations that -// generate telemetry must be configured to send that telemetry somewhere; such +// generate telemetry must be configured to send that telemetry somewhere, such // as autoscrape for exporter-based integrations. // // Integrations have access to the LogsInstances and MetricsInstances in the // same GrafanaAgent resource set, referenced by the / of the -// *Instance resource. +// Instance resource. // // For example, if there is a default/production MetricsInstance, you can // configure a supported integration's autoscrape block with: @@ -57,13 +57,13 @@ type IntegrationSpec struct { // Name of the integration to run (e.g., "node_exporter", "mysqld_exporter"). Name string `json:"name"` - // Type informs Grafana Agent Operator how to manage the integration being + // Type informs Grafana Agent Operator about how to manage the integration being // configured. Type IntegrationType `json:"type"` // +kubebuilder:validation:Type=object - // The configuration for the named integration. Note that integrations are + // The configuration for the named integration. Note that Integrations are // deployed with the integrations-next feature flag, which has different // common settings: // @@ -71,16 +71,16 @@ type IntegrationSpec struct { Config apiextv1.JSON `json:"config"` // An extra list of Volumes to be associated with the Grafana Agent pods - // running this integration. Volume names will be mutated to be unique across + // running this integration. Volume names are mutated to be unique across // all Integrations. Note that the specified volumes should be able to // tolerate existing on multiple pods at once when type is daemonset. // - // Don't use volumes for loading secrets/configMaps from the same namespace - // as the Integration; use the secrets and configMaps fields instead. + // Don't use volumes for loading Secrets or ConfigMaps from the same namespace + // as the Integration; use the Secrets and ConfigMaps fields instead. Volumes []corev1.Volume `json:"volumes,omitempty"` // An extra list of VolumeMounts to be associated with the Grafana Agent pods - // running this integration. VolumeMount names will be mutated to be unique + // running this integration. VolumeMount names are mutated to be unique // across all used IntegrationSpecs. // // Mount paths should include the namespace/name of the Integration CR to @@ -89,7 +89,7 @@ type IntegrationSpec struct { // An extra list of keys from Secrets in the same namespace as the // Integration which will be mounted into the Grafana Agent pod running this - // integration. + // Integration. // // Secrets will be mounted at // /etc/grafana-agent/integrations/secrets///. @@ -97,9 +97,9 @@ type IntegrationSpec struct { // An extra list of keys from ConfigMaps in the same namespace as the // Integration which will be mounted into the Grafana Agent pod running this - // integration. + // Integration. // - // ConfigMaps will be mounted at + // ConfigMaps are mounted at // /etc/grafana-agent/integrations/configMaps///. ConfigMaps []corev1.ConfigMapKeySelector `json:"configMaps,omitempty"` } @@ -109,7 +109,7 @@ type IntegrationType struct { // +kubebuilder:validation:Optional // When true, the configured integration should be run on every Node in the - // cluster. This is required for integrations that generate Node-specific + // cluster. This is required for Integrations that generate Node-specific // metrics like node_exporter, otherwise it must be false to avoid generating // duplicate metrics. AllNodes bool `json:"allNodes"` @@ -118,7 +118,7 @@ type IntegrationType struct { // Whether this integration can only be defined once for a Grafana Agent // process, such as statsd_exporter. It is invalid for a GrafanaAgent to - // discover multiple unique Integrations with the same integration name + // discover multiple unique Integrations with the same Integration name // (i.e., a single GrafanaAgent cannot deploy two statsd_exporters). Unique bool `json:"unique"` } diff --git a/pkg/operator/apis/monitoring/v1alpha1/types_logs.go b/pkg/operator/apis/monitoring/v1alpha1/types_logs.go index 7adcc6fc4b46..4c67fe2e3080 100644 --- a/pkg/operator/apis/monitoring/v1alpha1/types_logs.go +++ b/pkg/operator/apis/monitoring/v1alpha1/types_logs.go @@ -9,7 +9,7 @@ import ( // LogsSubsystemSpec defines global settings to apply across the logging // subsystem. type LogsSubsystemSpec struct { - // Global set of clients to use when a discovered LogsInstance does not + // A global set of clients to use when a discovered LogsInstance does not // have any clients defined. Clients []LogsClientSpec `json:"clients,omitempty"` // LogsExternalLabelName is the name of the external label used to @@ -141,7 +141,7 @@ type LogsInstanceSpec struct { // going to break Grafana Agent after the upgrade. AdditionalScrapeConfigs *v1.SecretKeySelector `json:"additionalScrapeConfigs,omitempty"` - // Configures how tailed targets will be watched. + // Configures how tailed targets are watched. TargetConfig *LogsTargetConfigSpec `json:"targetConfig,omitempty"` } @@ -185,7 +185,7 @@ type PodLogsSpec struct { // Selector to select which namespaces the Pod objects are discovered from. NamespaceSelector prom_v1.NamespaceSelector `json:"namespaceSelector,omitempty"` - // Pipeline stages for this pod. Pipeline stages allow for transforming and + // Pipeline stages for this pod. Pipeline stages support transforming and // filtering log lines. PipelineStages []*PipelineStageSpec `json:"pipelineStages,omitempty"` @@ -245,7 +245,7 @@ type PipelineStageSpec struct { // or drop entries when a log entry matches a configurable LogQL stream // selector and filter expressions. Match *MatchStageSpec `json:"match,omitempty"` - // Metrics is an action stage that allows for defining and updating metrics + // Metrics is an action stage that supports defining and updating metrics // based on data from the extracted map. Created metrics are not pushed to // Loki or Prometheus and are instead exposed via the /metrics endpoint of // the Grafana Agent pod. The Grafana Agent Operator should be configured @@ -296,16 +296,16 @@ type DropStageSpec struct { // Name from the extract data to parse. If empty, uses the log message. Source string `json:"source,omitempty"` - // RE2 regular exprssion. + // RE2 regular expression. // - // If source is provided, the regex will attempt + // If source is provided, the regex attempts // to match the source. // - // If no source is provided, then the regex will attempt + // If no source is provided, then the regex attempts // to attach the log line. // // If the provided regex matches the log line or a provided source, the - // line will be dropped. + // line is dropped. Expression string `json:"expression,omitempty"` // Value can only be specified when source is specified. If the value @@ -316,7 +316,7 @@ type DropStageSpec struct { Value string `json:"value,omitempty"` // OlderThan will be parsed as a Go duration. If the log line's timestamp - // is older than the current time minus the provided duration it will be + // is older than the current time minus the provided duration, it will be // dropped. OlderThan string `json:"olderThan,omitempty"` @@ -325,9 +325,9 @@ type DropStageSpec struct { // suffix (8kb). LongerThan string `json:"longerThan,omitempty"` - // Every time a log line is dropped the metric logentry_dropped_lines_total - // will be incremented. A "reason" label is added, and can be customized by - // providing a custom value here. Defaults to "drop_stage." + // Every time a log line is dropped, the metric logentry_dropped_lines_total + // is incremented. A "reason" label is added, and can be customized by + // providing a custom value here. Defaults to "drop_stage". DropCounterReason string `json:"dropCounterReason,omitempty"` } @@ -342,7 +342,7 @@ type JSONStageSpec struct { // key in the extracted data while the expression will be the value, // evaluated as a JMESPath from the source data. // - // Literal JMESPath exprssions can be done by wrapping a key in double + // Literal JMESPath expressions can be used by wrapping a key in double // quotes, which then must be wrapped again in single quotes in YAML // so they get passed to the JMESPath parser. Expressions map[string]string `json:"expressions,omitempty"` @@ -361,17 +361,17 @@ type MatchStageSpec struct { PipelineName string `json:"pipelineName,omitempty"` // Determines what action is taken when the selector matches the log line. - // Can be keep or drop. Defaults to keep. When set to drop, entries will be - // dropped and no later metrics will be recorded. + // Can be keep or drop. Defaults to keep. When set to drop, entries are + // dropped and no later metrics are recorded. // Stages must be empty when dropping metrics. Action string `json:"action,omitempty"` - // Every time a log line is dropped the metric logentry_dropped_lines_total - // will be incremented. A "reason" label is added, and can be customized by + // Every time a log line is dropped, the metric logentry_dropped_lines_total + // is incremented. A "reason" label is added, and can be customized by // providing a custom value here. Defaults to "match_stage." DropCounterReason string `json:"dropCounterReason,omitempty"` - // Nested set of pipeline stages to execute when action: keep and the log + // Nested set of pipeline stages to execute when action is keep and the log // line matches selector. // // An example value for stages may be: @@ -409,26 +409,26 @@ type MetricsStageSpec struct { // Label values on metrics are dynamic which can cause exported metrics // to go stale. To prevent unbounded cardinality, any metrics not updated - // within MaxIdleDuration will be removed. + // within MaxIdleDuration are removed. // // Must be greater or equal to 1s. Defaults to 5m. MaxIdleDuration string `json:"maxIdleDuration,omitempty"` - // If true all log lines will be counted without attempting to match the + // If true, all log lines are counted without attempting to match the // source to the extracted map. Mutually exclusive with value. // // Only valid for type: counter. MatchAll *bool `json:"matchAll,omitempty"` - // If true all log line bytes will be counted. Can only be set with + // If true all log line bytes are counted. Can only be set with // matchAll: true and action: add. // // Only valid for type: counter. CountEntryBytes *bool `json:"countEntryBytes,omitempty"` // Filters down source data and only changes the metric if the targeted - // value exactly matches the provided string. If not present, all - // data will match. + // value matches the provided string exactly. If not present, all + // data matches. Value string `json:"value,omitempty"` // The action to take against the metric. Required. @@ -473,7 +473,7 @@ type OutputStageSpec struct { // labels into the log line by packing the log line and labels inside of a JSON // object. type PackStageSpec struct { - // Name from extracted data or line labels. Requiried. + // Name from extracted data or line labels. Required. // Labels provided here are automatically removed from output labels. Labels []string `json:"labels"` @@ -517,7 +517,7 @@ type TemplateStageSpec struct { // the log message. Source string `json:"source"` - // Go template string to use. Required. In additional to normal template + // Go template string to use. Required. In addition to normal template // functions, ToLower, ToUpper, Replace, Trim, TrimLeft, TrimRight, // TrimPrefix, and TrimSpace are also available. Template string `json:"template"` diff --git a/production/operator/crds/monitoring.grafana.com_grafanaagents.yaml b/production/operator/crds/monitoring.grafana.com_grafanaagents.yaml index 7a72e5052ffe..36981387f99a 100644 --- a/production/operator/crds/monitoring.grafana.com_grafanaagents.yaml +++ b/production/operator/crds/monitoring.grafana.com_grafanaagents.yaml @@ -3675,8 +3675,8 @@ spec: settings unique to logging-specific pods that are deployed. properties: clients: - description: Global set of clients to use when a discovered LogsInstance - does not have any clients defined. + description: A global set of clients to use when a discovered + LogsInstance does not have any clients defined. items: description: LogsClientSpec defines the client integration for logs, indicating which Loki server to send logs to. diff --git a/production/operator/crds/monitoring.grafana.com_integrations.yaml b/production/operator/crds/monitoring.grafana.com_integrations.yaml index 6cb40d851740..3f24ffc59122 100644 --- a/production/operator/crds/monitoring.grafana.com_integrations.yaml +++ b/production/operator/crds/monitoring.grafana.com_integrations.yaml @@ -21,10 +21,10 @@ spec: schema: openAPIV3Schema: description: "Integration runs a single Grafana Agent integration. Integrations - that generate telemetry must be configured to send that telemetry somewhere; + that generate telemetry must be configured to send that telemetry somewhere, such as autoscrape for exporter-based integrations. \n Integrations have access to the LogsInstances and MetricsInstances in the same GrafanaAgent - resource set, referenced by the / of the *Instance resource. + resource set, referenced by the / of the Instance resource. \n For example, if there is a default/production MetricsInstance, you can configure a supported integration's autoscrape block with: \n autoscrape: enable: true metrics_instance: default/production \n There is currently @@ -48,14 +48,14 @@ spec: properties: config: description: "The configuration for the named integration. Note that - integrations are deployed with the integrations-next feature flag, + Integrations are deployed with the integrations-next feature flag, which has different common settings: \n https://grafana.com/docs/agent/latest/configuration/integrations/integrations-next/" type: object x-kubernetes-preserve-unknown-fields: true configMaps: description: "An extra list of keys from ConfigMaps in the same namespace as the Integration which will be mounted into the Grafana Agent - pod running this integration. \n ConfigMaps will be mounted at /etc/grafana-agent/integrations/configMaps///." + pod running this Integration. \n ConfigMaps are mounted at /etc/grafana-agent/integrations/configMaps///." items: description: Selects a key from a ConfigMap. properties: @@ -81,7 +81,7 @@ spec: secrets: description: "An extra list of keys from Secrets in the same namespace as the Integration which will be mounted into the Grafana Agent - pod running this integration. \n Secrets will be mounted at /etc/grafana-agent/integrations/secrets///." + pod running this Integration. \n Secrets will be mounted at /etc/grafana-agent/integrations/secrets///." items: description: SecretKeySelector selects a key of a Secret. properties: @@ -101,12 +101,12 @@ spec: type: object type: array type: - description: Type informs Grafana Agent Operator how to manage the - integration being configured. + description: Type informs Grafana Agent Operator about how to manage + the integration being configured. properties: allNodes: description: When true, the configured integration should be run - on every Node in the cluster. This is required for integrations + on every Node in the cluster. This is required for Integrations that generate Node-specific metrics like node_exporter, otherwise it must be false to avoid generating duplicate metrics. type: boolean @@ -114,16 +114,16 @@ spec: description: Whether this integration can only be defined once for a Grafana Agent process, such as statsd_exporter. It is invalid for a GrafanaAgent to discover multiple unique Integrations - with the same integration name (i.e., a single GrafanaAgent + with the same Integration name (i.e., a single GrafanaAgent cannot deploy two statsd_exporters). type: boolean type: object volumeMounts: description: "An extra list of VolumeMounts to be associated with the Grafana Agent pods running this integration. VolumeMount names - will be mutated to be unique across all used IntegrationSpecs. \n - Mount paths should include the namespace/name of the Integration - CR to avoid potentially colliding with other resources." + are mutated to be unique across all used IntegrationSpecs. \n Mount + paths should include the namespace/name of the Integration CR to + avoid potentially colliding with other resources." items: description: VolumeMount describes a mounting of a Volume within a container. @@ -163,12 +163,12 @@ spec: type: array volumes: description: "An extra list of Volumes to be associated with the Grafana - Agent pods running this integration. Volume names will be mutated - to be unique across all Integrations. Note that the specified volumes + Agent pods running this integration. Volume names are mutated to + be unique across all Integrations. Note that the specified volumes should be able to tolerate existing on multiple pods at once when - type is daemonset. \n Don't use volumes for loading secrets/configMaps - from the same namespace as the Integration; use the secrets and - configMaps fields instead." + type is daemonset. \n Don't use volumes for loading Secrets or ConfigMaps + from the same namespace as the Integration; use the Secrets and + ConfigMaps fields instead." items: description: Volume represents a named volume in a pod that may be accessed by any container in the pod. diff --git a/production/operator/crds/monitoring.grafana.com_logsinstances.yaml b/production/operator/crds/monitoring.grafana.com_logsinstances.yaml index 0546c2a53816..fe6b4c5d6b55 100644 --- a/production/operator/crds/monitoring.grafana.com_logsinstances.yaml +++ b/production/operator/crds/monitoring.grafana.com_logsinstances.yaml @@ -392,7 +392,7 @@ spec: type: object type: object targetConfig: - description: Configures how tailed targets will be watched. + description: Configures how tailed targets are watched. properties: syncPeriod: description: Period to resync directories being watched and files diff --git a/production/operator/crds/monitoring.grafana.com_podlogs.yaml b/production/operator/crds/monitoring.grafana.com_podlogs.yaml index 63a8c7c98ea0..b063e8b54542 100644 --- a/production/operator/crds/monitoring.grafana.com_podlogs.yaml +++ b/production/operator/crds/monitoring.grafana.com_podlogs.yaml @@ -56,7 +56,7 @@ spec: type: array type: object pipelineStages: - description: Pipeline stages for this pod. Pipeline stages allow for + description: Pipeline stages for this pod. Pipeline stages support transforming and filtering log lines. items: description: "PipelineStageSpec defines an individual pipeline stage. @@ -78,17 +78,17 @@ spec: logs. properties: dropCounterReason: - description: Every time a log line is dropped the metric - logentry_dropped_lines_total will be incremented. A "reason" + description: Every time a log line is dropped, the metric + logentry_dropped_lines_total is incremented. A "reason" label is added, and can be customized by providing a custom - value here. Defaults to "drop_stage." + value here. Defaults to "drop_stage". type: string expression: - description: "RE2 regular exprssion. \n If source is provided, - the regex will attempt to match the source. \n If no source - is provided, then the regex will attempt to attach the - log line. \n If the provided regex matches the log line - or a provided source, the line will be dropped." + description: "RE2 regular expression. \n If source is provided, + the regex attempts to match the source. \n If no source + is provided, then the regex attempts to attach the log + line. \n If the provided regex matches the log line or + a provided source, the line is dropped." type: string longerThan: description: LongerThan will drop a log line if it its content @@ -98,7 +98,7 @@ spec: olderThan: description: OlderThan will be parsed as a Go duration. If the log line's timestamp is older than the current - time minus the provided duration it will be dropped. + time minus the provided duration, it will be dropped. type: string source: description: Name from the extract data to parse. If empty, @@ -122,10 +122,10 @@ spec: description: "Set of the key/value pairs of JMESPath expressions. The key will be the key in the extracted data while the expression will be the value, evaluated as a JMESPath - from the source data. \n Literal JMESPath exprssions can - be done by wrapping a key in double quotes, which then - must be wrapped again in single quotes in YAML so they - get passed to the JMESPath parser." + from the source data. \n Literal JMESPath expressions + can be used by wrapping a key in double quotes, which + then must be wrapped again in single quotes in YAML so + they get passed to the JMESPath parser." type: object source: description: Name from the extracted data to parse as JSON. @@ -164,13 +164,13 @@ spec: action: description: Determines what action is taken when the selector matches the log line. Can be keep or drop. Defaults to - keep. When set to drop, entries will be dropped and no - later metrics will be recorded. Stages must be empty when - dropping metrics. + keep. When set to drop, entries are dropped and no later + metrics are recorded. Stages must be empty when dropping + metrics. type: string dropCounterReason: - description: Every time a log line is dropped the metric - logentry_dropped_lines_total will be incremented. A "reason" + description: Every time a log line is dropped, the metric + logentry_dropped_lines_total is incremented. A "reason" label is added, and can be customized by providing a custom value here. Defaults to "match_stage." type: string @@ -186,7 +186,7 @@ spec: type: string stages: description: "Nested set of pipeline stages to execute when - action: keep and the log line matches selector. \n An + action is keep and the log line matches selector. \n An example value for stages may be: \n stages: | - json: {} - labelAllow: [foo, bar] \n Note that stages is a string because SIG API Machinery does not support recursive types, @@ -223,7 +223,7 @@ spec: type: string type: array countEntryBytes: - description: "If true all log line bytes will be counted. + description: "If true all log line bytes are counted. Can only be set with matchAll: true and action: add. \n Only valid for type: counter." type: boolean @@ -231,7 +231,7 @@ spec: description: Sets the description for the created metric. type: string matchAll: - description: "If true all log lines will be counted without + description: "If true, all log lines are counted without attempting to match the source to the extracted map. Mutually exclusive with value. \n Only valid for type: counter." @@ -240,8 +240,8 @@ spec: description: "Label values on metrics are dynamic which can cause exported metrics to go stale. To prevent unbounded cardinality, any metrics not updated within MaxIdleDuration - will be removed. \n Must be greater or equal to 1s. - Defaults to 5m." + are removed. \n Must be greater or equal to 1s. Defaults + to 5m." type: string prefix: description: Sets the custom prefix name for the metric. @@ -257,14 +257,14 @@ spec: type: string value: description: Filters down source data and only changes - the metric if the targeted value exactly matches the - provided string. If not present, all data will match. + the metric if the targeted value matches the provided + string exactly. If not present, all data matches. type: string required: - action - type type: object - description: Metrics is an action stage that allows for defining + description: Metrics is an action stage that supports defining and updating metrics based on data from the extracted map. Created metrics are not pushed to Loki or Prometheus and are instead exposed via the /metrics endpoint of the Grafana Agent @@ -317,7 +317,7 @@ spec: containers to avoid out of order errors. type: boolean labels: - description: Name from extracted data or line labels. Requiried. + description: Name from extracted data or line labels. Required. Labels provided here are automatically removed from output labels. items: @@ -371,7 +371,7 @@ spec: If empty, defaults to using the log message. type: string template: - description: Go template string to use. Required. In additional + description: Go template string to use. Required. In addition to normal template functions, ToLower, ToUpper, Replace, Trim, TrimLeft, TrimRight, TrimPrefix, and TrimSpace are also available. @@ -387,7 +387,7 @@ spec: will be used. properties: label: - description: Name from labels to whose value should be set + description: Name from labels whose value should be set as tenant ID. Mutually exclusive with source and value. type: string source: