diff --git a/lib/vector-common/src/internal_event/metric_name.rs b/lib/vector-common/src/internal_event/metric_name.rs index 6212d245cef40..46e49b0c7d6ba 100644 --- a/lib/vector-common/src/internal_event/metric_name.rs +++ b/lib/vector-common/src/internal_event/metric_name.rs @@ -1,134 +1,562 @@ use strum::{AsRefStr, Display, EnumIter}; +use vector_config::configurable_component; -/// Canonical list of all per-component internal metric names emitted by Vector. +use super::metric_tags::{ + COMPONENT_RECEIVED_EVENTS_TAGS, COMPONENT_RECEIVED_EVENTS_TOTAL_TAGS, COMPONENT_TAGS, + COMPONENT_TAGS_ERROR_TYPE_STAGE, COMPONENT_TAGS_GRPC_ALL, COMPONENT_TAGS_GRPC_METHOD_SERVICE, + COMPONENT_TAGS_HTTP_ALL, COMPONENT_TAGS_HTTP_ERROR_KIND, COMPONENT_TAGS_HTTP_METHOD, + COMPONENT_TAGS_HTTP_METHOD_PATH, COMPONENT_TAGS_HTTP_STATUS, COMPONENT_TAGS_OUTPUT, + INTERNAL_METRICS_TAGS, INTERNAL_METRICS_TAGS_FILE, INTERNAL_METRICS_TAGS_REASON, + S3_OBJECT_PROCESSING_TAGS, +}; + +/// Canonical list of all per-component internal counter metric names emitted by Vector. +#[configurable_component] #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Display, AsRefStr, EnumIter)] +#[serde(rename_all = "snake_case")] #[strum(serialize_all = "snake_case")] pub enum CounterName { + /// The number of events accepted by this component either from tagged + /// origins like file and uri, or cumulatively from other origins. + #[configurable(unit = "event", tags(..COMPONENT_RECEIVED_EVENTS_TOTAL_TAGS))] ComponentReceivedEventsTotal, + + /// The number of event bytes accepted by this component either from + /// tagged origins like file and uri, or cumulatively from other origins. + #[configurable(unit = "byte", tags(..COMPONENT_RECEIVED_EVENTS_TAGS))] ComponentReceivedEventBytesTotal, + + /// The number of raw bytes accepted by this component from source origins. + #[configurable(unit = "byte", tags(..COMPONENT_RECEIVED_EVENTS_TAGS))] ComponentReceivedBytesTotal, + + /// The total number of events emitted by this component. + #[configurable(unit = "event", tags(..COMPONENT_TAGS_OUTPUT))] ComponentSentEventsTotal, + + /// The total number of event bytes emitted by this component. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS_OUTPUT))] ComponentSentEventBytesTotal, + + /// The number of raw bytes sent by this component to destination sinks. + #[configurable(unit = "byte", tags { + ..COMPONENT_TAGS, + "endpoint": {"description": "The endpoint to which the bytes were sent. For HTTP, this will be the host and path only, excluding the query string.", "required": false}, + "file": {"description": "The absolute path of the destination file.", "required": false}, + "protocol": {"description": "The protocol used to send the bytes.", "required": true}, + "region": {"description": "The AWS region name to which the bytes were sent. In some configurations, this may be a literal hostname.", "required": false} + })] ComponentSentBytesTotal, + + /// The number of events dropped by this component. + #[configurable(unit = "event", tags { + ..COMPONENT_TAGS, + "intentional": {"description": "True if the events were discarded intentionally, like a `filter` transform, or false if due to an error.", "required": true} + })] ComponentDiscardedEventsTotal, + + /// The total number of errors encountered by this component. + #[configurable(unit = "error", tags(..COMPONENT_TAGS_ERROR_TYPE_STAGE))] ComponentErrorsTotal, + + /// The total number of events for which this source responded with a timeout error. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] ComponentTimedOutEventsTotal, + + /// The total number of requests for which this source responded with a timeout error. + #[configurable(unit = "request", tags(..COMPONENT_TAGS))] ComponentTimedOutRequestsTotal, + + /// The number of events received by this buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferReceivedEventsTotal, + + /// The number of bytes received by this buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferReceivedBytesTotal, + + /// The number of events sent by this buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferSentEventsTotal, + + /// The number of bytes sent by this buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferSentBytesTotal, + + /// The number of events dropped by this buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferDiscardedEventsTotal, + + /// The number of bytes dropped by this buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferDiscardedBytesTotal, + + /// The total number of buffer errors encountered. + #[configurable(unit = "error", tags(..COMPONENT_TAGS))] BufferErrorsTotal, + // Internal events from src/internal_events/ + /// The number of events recorded by the aggregate transform. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] AggregateEventsRecordedTotal, + + /// The number of failed metric updates, `incremental` adds, encountered by the aggregate transform. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] AggregateFailedUpdates, + + /// The number of flushes done by the aggregate transform. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] AggregateFlushesTotal, + + /// The number of times the Vector API has been started. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] ApiStartedTotal, + + /// The total number of files checkpointed. + #[configurable(unit = "file", tags(..INTERNAL_METRICS_TAGS))] CheckpointsTotal, + + /// The total number of errors identifying files via checksum. + #[configurable(unit = "error", tags(..INTERNAL_METRICS_TAGS_FILE))] ChecksumErrorsTotal, + + /// The total number of metrics collections completed for this component. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] CollectCompletedTotal, + + /// The total number of times a command has been executed. + #[configurable(unit = "execution", tags(..COMPONENT_TAGS))] CommandExecutedTotal, + + /// The total number of times a connection has been established. + #[configurable(unit = "connection", tags(..INTERNAL_METRICS_TAGS))] ConnectionEstablishedTotal, + + /// The total number of errors sending data via the connection. + #[configurable(unit = "error", tags(..INTERNAL_METRICS_TAGS))] ConnectionSendErrorsTotal, + + /// The total number of times the connection has been shut down. + #[configurable(unit = "connection", tags(..INTERNAL_METRICS_TAGS))] ConnectionShutdownTotal, + + /// The total number of container events processed. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] ContainerProcessedEventsTotal, + + /// The total number of times Vector stopped watching for container logs. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] ContainersUnwatchedTotal, + + /// The total number of times Vector started watching for container logs. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] ContainersWatchedTotal, + + /// The total number of byte order marks (BOM) removed from incoming data. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] DecoderBomRemovalsTotal, + + /// The total number of warnings when replacing malformed characters during decoding. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] DecoderMalformedReplacementWarningsTotal, + + /// The total number of bytes loaded into Doris. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] DorisBytesLoadedTotal, + + /// The total number of rows filtered by Doris during stream load. + #[configurable(unit = "row", tags(..COMPONENT_TAGS))] DorisRowsFilteredTotal, + + /// The total number of rows successfully loaded into Doris. + #[configurable(unit = "row", tags(..COMPONENT_TAGS))] DorisRowsLoadedTotal, + + /// The total number of warnings when replacing unmappable characters during encoding. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] EncoderUnmappableReplacementWarningsTotal, + + /// The total number of events discarded by this component. + #[configurable(unit = "event", tags(..INTERNAL_METRICS_TAGS_REASON))] EventsDiscardedTotal, + + /// The total number of files Vector has found to watch. + #[configurable(unit = "file", tags(..INTERNAL_METRICS_TAGS_FILE))] FilesAddedTotal, + + /// The total number of files deleted. + #[configurable(unit = "file", tags(..INTERNAL_METRICS_TAGS_FILE))] FilesDeletedTotal, + + /// The total number of times Vector has resumed watching a file. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS_FILE))] FilesResumedTotal, + + /// The total number of times Vector has stopped watching a file. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS_FILE))] FilesUnwatchedTotal, + + /// The total number of gRPC messages received. + #[configurable(unit = "message", tags(..COMPONENT_TAGS_GRPC_METHOD_SERVICE))] GrpcServerMessagesReceivedTotal, + + /// The total number of gRPC messages sent. + #[configurable(unit = "message", tags(..COMPONENT_TAGS_GRPC_ALL))] GrpcServerMessagesSentTotal, + + /// The total number of HTTP client errors encountered. + #[configurable(unit = "error", tags(..COMPONENT_TAGS_HTTP_ERROR_KIND))] HttpClientErrorsTotal, + + /// The total number of sent HTTP requests, tagged with the request method. + #[configurable(unit = "request", tags(..COMPONENT_TAGS_HTTP_METHOD))] HttpClientRequestsSentTotal, + + /// The total number of HTTP requests, tagged with the response code. + #[configurable(unit = "response", tags(..COMPONENT_TAGS_HTTP_STATUS))] HttpClientResponsesTotal, + + /// The total number of HTTP requests received. + #[configurable(unit = "request", tags(..COMPONENT_TAGS_HTTP_METHOD_PATH))] HttpServerRequestsReceivedTotal, + + /// The total number of HTTP responses sent. + #[configurable(unit = "response", tags(..COMPONENT_TAGS_HTTP_ALL))] HttpServerResponsesSentTotal, + + /// Total number of message bytes (including framing) received from Kafka brokers. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] KafkaConsumedMessagesBytesTotal, + + /// Total number of messages consumed, not including ignored messages (due to offset, etc), from Kafka brokers. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] KafkaConsumedMessagesTotal, + + /// Total number of message bytes (including framing, such as per-Message framing and MessageSet/batch framing) transmitted to Kafka brokers. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] KafkaProducedMessagesBytesTotal, + + /// Total number of messages transmitted (produced) to Kafka brokers. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] KafkaProducedMessagesTotal, + + /// Total number of bytes transmitted to Kafka brokers. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] KafkaRequestsBytesTotal, + + /// Total number of requests sent to Kafka brokers. + #[configurable(unit = "request", tags(..COMPONENT_TAGS))] KafkaRequestsTotal, + + /// Total number of bytes received from Kafka brokers. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] KafkaResponsesBytesTotal, + + /// Total number of responses received from Kafka brokers. + #[configurable(unit = "response", tags(..COMPONENT_TAGS))] KafkaResponsesTotal, + + /// The total number of failed efforts to refresh AWS EC2 metadata. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] MetadataRefreshFailedTotal, + + /// The total number of AWS EC2 metadata refreshes. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] MetadataRefreshSuccessfulTotal, + + /// The total number of errors encountered while parsing. + #[configurable(unit = "error", tags(..COMPONENT_TAGS))] ParseErrorsTotal, + + /// The total number of times the Vector instance has quit. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] QuitTotal, + + /// The total number of times the Vector instance has been reloaded. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] ReloadedTotal, + + /// The total number of events whose timestamps were rewritten to maintain ordering. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] RewrittenTimestampEventsTotal, + + /// The total number of successful deferrals of SQS messages. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] SqsMessageDeferSucceededTotal, + + /// The total number of successful deletions of SQS messages. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] SqsMessageDeleteSucceededTotal, + + /// The total number of SQS messages successfully processed. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] SqsMessageProcessingSucceededTotal, + + /// The total number of times successfully receiving SQS messages. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] SqsMessageReceiveSucceededTotal, + + /// The total number of received SQS messages. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] SqsMessageReceivedMessagesTotal, + + /// The number of stale events that Vector has flushed. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] StaleEventsFlushedTotal, + + /// The total number of times the Vector instance has been started. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] StartedTotal, + + /// The total number of times the Vector instance has been stopped. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] StoppedTotal, + + /// The total number of events whose tag keys are no longer tracked because `max_tracked_keys` was reached. These events pass through the transform unchecked. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] TagCardinalityUntrackedEventsTotal, + + /// The total number of events discarded because the tag has been rejected after + /// hitting the configured `value_limit`. When `internal_metrics.include_extended_tags` + /// is enabled in the `tag_cardinality_limit` transform, this metric includes + /// `metric_name` and `tag_key` labels. By default, this metric has no labels to + /// keep cardinality low. + #[configurable(unit = "event", tags { + ..COMPONENT_TAGS, + "metric_name": {"description": "The name of the metric whose tag value limit was exceeded. Only present when `internal_metrics.include_extended_tags` is enabled.", "required": false}, + "tag_key": {"description": "The key of the tag whose value limit was exceeded. Only present when `internal_metrics.include_extended_tags` is enabled.", "required": false} + })] TagValueLimitExceededTotal, + + /// The total number of times new values for a key have been rejected because the + /// value limit has been reached. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] ValueLimitReachedTotal, + + /// The total number of bytes sent over WebSocket connections. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] WebsocketBytesSentTotal, + + /// The total number of messages sent over WebSocket connections. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] WebsocketMessagesSentTotal, + + /// The total number of times the Windows service has been installed. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] WindowsServiceInstallTotal, + + /// The total number of times the Windows service has been restarted. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] WindowsServiceRestartTotal, + + /// The total number of times the Windows service has been started. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] WindowsServiceStartTotal, + + /// The total number of times the Windows service has been stopped. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] WindowsServiceStopTotal, + + /// The total number of times the Windows service has been uninstalled. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS))] WindowsServiceUninstallTotal, + + /// The total number of failures to annotate Kubernetes events with namespace metadata. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] K8sEventNamespaceAnnotationFailuresTotal, + + /// The total number of failures to annotate Kubernetes events with node metadata. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] K8sEventNodeAnnotationFailuresTotal, + + /// The total number of edge cases encountered while picking format of the Kubernetes log message. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] K8sFormatPickerEdgeCasesTotal, + + /// The total number of failures to parse a message as a JSON object. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] K8sDockerFormatParseFailuresTotal, + + /// The total number of times an S3 record in an SQS message was ignored (for an event that was not `ObjectCreated`). + #[configurable(unit = "event", tags { + ..COMPONENT_TAGS, + "ignore_type": { + "description": "The reason for ignoring the S3 record", + "required": true, + "enum": {"invalid_event_kind": "The kind of invalid event."} + } + })] SqsS3EventRecordIgnoredTotal, + + /// The total number of bytes allocated by this component. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] ComponentAllocatedBytesTotal, + + /// The total number of bytes deallocated by this component. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] ComponentDeallocatedBytesTotal, + + /// The total number of failed insertions into the in-memory enrichment table. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableFailedInsertions, + + /// The total number of failed reads from the in-memory enrichment table. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableFailedReads, + + /// The total number of flushes of the in-memory enrichment table. + #[configurable(unit = "flush", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableFlushesTotal, + + /// The total number of successful insertions into the in-memory enrichment table. + #[configurable(unit = "occurrence", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableInsertionsTotal, + + /// The total number of successful reads from the in-memory enrichment table. + #[configurable(unit = "read", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableReadsTotal, + + /// The total number of entries evicted from the in-memory enrichment table due to TTL expiration. + #[configurable(unit = "eviction", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableTtlExpirations, + + /// The total number of nanoseconds of CPU time consumed by this component. + #[configurable(unit = "nanosecond", tags(..COMPONENT_TAGS))] ComponentCpuUsageNsTotal, + + /// The total number of errors reading datagram. + #[configurable(unit = "error", tags { + ..COMPONENT_TAGS, + "mode": {"description": "The connection mode used by the component.", "required": true, "enum": {"udp": "User Datagram Protocol"}} + })] + ConnectionReadErrorsTotal, + + /// The total number of metrics emitted from the internal metrics registry. This metric is deprecated in favor of `internal_metrics_cardinality`. + #[configurable(unit = "unit", tags())] + InternalMetricsCardinalityTotal, + + /// Number of configuration reload attempts that were rejected. + #[configurable(unit = "occurrence", tags(..INTERNAL_METRICS_TAGS_REASON))] + ConfigReloadRejected, + + /// The total number of errors converting bytes to a UTF-8 string in UDP mode. + #[configurable(unit = "error", tags { + ..COMPONENT_TAGS, + "mode": {"description": "The connection mode used by the component.", "required": true, "enum": {"udp": "User Datagram Protocol"}} + })] + Utf8ConvertErrorsTotal, } +/// Canonical list of all per-component internal histogram metric names emitted by Vector. +#[configurable_component] #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Display, AsRefStr, EnumIter)] +#[serde(rename_all = "snake_case")] #[strum(serialize_all = "snake_case")] pub enum HistogramName { + /// A histogram of the number of events passed in each internal batch in Vector's internal topology. + /// + /// Note that this is separate than sink-level batching. It is mostly useful for low level debugging + /// performance issues in Vector due to small internal batches. + #[configurable(unit = "event", tags(..COMPONENT_RECEIVED_EVENTS_TAGS))] ComponentReceivedEventsCount, + + /// The size in bytes of each event received by the source. + #[configurable(unit = "byte", tags(..COMPONENT_RECEIVED_EVENTS_TAGS))] ComponentReceivedBytes, + + /// The duration spent sending a payload to this buffer. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] BufferSendDurationSeconds, + + /// The elapsed time, in fractional seconds, that an event spends in a single transform. + /// + /// This includes both the time spent queued in the transform's input buffer and the time spent + /// executing the transform itself. + #[configurable(unit = "second", tags(..INTERNAL_METRICS_TAGS))] ComponentLatencySeconds, + + /// The difference between the timestamp recorded in each event and the time when it was ingested, expressed as fractional seconds. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] SourceLagTimeSeconds, + + /// The time elapsed blocking on the downstream channel to accept a single chunk from a batch of events received at the source. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] SourceSendLatencySeconds, + + /// The time elapsed blocking on the downstream channel to accept an entire batch of events received at the source. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] SourceSendBatchLatencySeconds, + + /// The average round-trip time (RTT) for the current window. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyAveragedRtt, + + /// A boolean sample (1.0 if back pressure was observed during the current window, 0.0 otherwise). + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyBackPressure, + + /// The number of outbound requests currently awaiting a response. + #[configurable(unit = "request", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyInFlight, + + /// The concurrency limit that the adaptive concurrency feature has decided on for this current window. + #[configurable(unit = "unit", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyLimit, + + /// The observed round-trip time (RTT) for requests. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyObservedRtt, + + /// The mean round-trip time (RTT) from past windows, used as the baseline for adaptive concurrency decisions. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyPastRttMean, + + /// A boolean sample (1.0 if the concurrency limit was reached during the most recent limit update, 0.0 otherwise). + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS))] AdaptiveConcurrencyReachedLimit, + + /// The time taken to process an S3 object that succeeded, in seconds. + #[configurable(unit = "second", tags(..S3_OBJECT_PROCESSING_TAGS))] S3ObjectProcessingSucceededDurationSeconds, + + /// The time taken to process an S3 object that failed, in seconds. + #[configurable(unit = "second", tags(..S3_OBJECT_PROCESSING_TAGS))] S3ObjectProcessingFailedDurationSeconds, + + /// The duration spent collecting metrics for this component. + #[configurable(unit = "second", tags(..INTERNAL_METRICS_TAGS))] CollectDurationSeconds, + + /// The command execution duration in seconds. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] CommandExecutionDurationSeconds, + + /// The duration spent handling a gRPC request. + #[configurable(unit = "second", tags(..COMPONENT_TAGS_GRPC_ALL))] GrpcServerHandlerDurationSeconds, + + /// The duration spent handling an HTTP request. + #[configurable(unit = "second", tags(..COMPONENT_TAGS_HTTP_ALL))] HttpServerHandlerDurationSeconds, + + /// The round-trip time (RTT) of HTTP requests. + #[configurable(unit = "second", tags(..COMPONENT_TAGS))] HttpClientRttSeconds, + + /// The round-trip time (RTT) of HTTP requests, tagged with the response code. + #[configurable(unit = "second", tags(..COMPONENT_TAGS_HTTP_STATUS))] HttpClientResponseRttSeconds, + + /// The round-trip time (RTT) of HTTP requests that resulted in an error. + #[configurable(unit = "second", tags(..COMPONENT_TAGS_HTTP_ERROR_KIND))] HttpClientErrorRttSeconds, + + /// The utilization level of the source buffer. The outputs of the source send data to this buffer. + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] SourceBufferUtilization, + + /// The utilization level of the buffer that feeds into a transform. + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] TransformBufferUtilization, } @@ -169,46 +597,204 @@ impl HistogramName { } } +/// Canonical list of all per-component internal gauge metric names emitted by Vector. +#[configurable_component] #[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Display, AsRefStr, EnumIter)] +#[serde(rename_all = "snake_case")] #[strum(serialize_all = "snake_case")] pub enum GaugeName { + /// The mean elapsed time, in fractional seconds, that an event spends in a single transform. + /// + /// This includes both the time spent queued in the transform's input buffer and the time spent + /// executing the transform itself. This value is smoothed over time using an exponentially + /// weighted moving average (EWMA). + #[configurable(unit = "second", tags(..INTERNAL_METRICS_TAGS))] ComponentLatencyMeanSeconds, - SourceBufferMaxSizeEvents, - SourceBufferMaxSizeBytes, + + /// The maximum number of events the source buffer can hold. The outputs of the source send data to this buffer. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`source_buffer_max_size_events`](#source_buffer_max_size_events)." + )] + #[configurable(unit = "event", tags(..COMPONENT_TAGS_OUTPUT))] SourceBufferMaxEventSize, + + /// The maximum number of bytes the source buffer can hold. The outputs of the source send data to this buffer. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`source_buffer_max_size_bytes`](#source_buffer_max_size_bytes)." + )] + #[configurable(unit = "byte", tags(..COMPONENT_TAGS_OUTPUT))] SourceBufferMaxByteSize, + + /// The maximum number of events the source buffer can hold. The outputs of the source send data to this buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS_OUTPUT))] + SourceBufferMaxSizeEvents, + + /// The maximum number of bytes the source buffer can hold. The outputs of the source send data to this buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS_OUTPUT))] + SourceBufferMaxSizeBytes, + + /// The current utilization level of the source buffer. The outputs of the source send data to this buffer. + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] SourceBufferUtilizationLevel, + + /// The mean utilization level of the source buffer. The outputs of the source send data to this buffer. The mean utilization is smoothed over time using an exponentially weighted moving average (EWMA). + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] SourceBufferUtilizationMean, - TransformBufferMaxSizeEvents, - TransformBufferMaxSizeBytes, + + /// The maximum number of events the buffer that feeds into a transform can hold. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`transform_buffer_max_size_events`](#transform_buffer_max_size_events)." + )] + #[configurable(unit = "event", tags(..COMPONENT_TAGS_OUTPUT))] TransformBufferMaxEventSize, + + /// The maximum number of bytes the buffer that feeds into a transform can hold. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`transform_buffer_max_size_bytes`](#transform_buffer_max_size_bytes)." + )] + #[configurable(unit = "byte", tags(..COMPONENT_TAGS_OUTPUT))] TransformBufferMaxByteSize, + + /// The maximum number of events the buffer that feeds into a transform can hold. + #[configurable(unit = "event", tags(..COMPONENT_TAGS_OUTPUT))] + TransformBufferMaxSizeEvents, + + /// The maximum number of bytes the buffer that feeds into a transform can hold. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS_OUTPUT))] + TransformBufferMaxSizeBytes, + + /// The current utilization level of the buffer that feeds into a transform. + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] TransformBufferUtilizationLevel, + + /// The mean utilization level of the buffer that feeds into a transform. This value is smoothed over time using an exponentially weighted moving average (EWMA). + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS_OUTPUT))] TransformBufferUtilizationMean, + + /// The maximum number of events in the buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferMaxSizeEvents, + + /// The maximum size in events that the buffer can store. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`buffer_max_size_events`](#buffer_max_size_events).", + unit = "event", + tags(..COMPONENT_TAGS) + )] BufferMaxEventSize, + + /// The maximum number of bytes in the buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferMaxSizeBytes, + + /// The maximum size in bytes that the buffer can store. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`buffer_max_size_bytes`](#buffer_max_size_bytes).", + unit = "byte", + tags(..COMPONENT_TAGS) + )] BufferMaxByteSize, + + /// The number of events currently in the buffer. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`buffer_size_events`](#buffer_size_events)." + )] + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferEvents, + + /// The number of events currently in the buffer. + #[configurable(unit = "event", tags(..COMPONENT_TAGS))] BufferSizeEvents, + + /// The number of bytes currently in the buffer. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferSizeBytes, + + /// The number of bytes currently in the buffer. + #[configurable( + deprecated = "This metric has been deprecated in favor of [`buffer_size_bytes`](#buffer_size_bytes)." + )] + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] BufferByteSize, + + /// A ratio from 0 to 1 of the load on a component. A value of 0 would indicate a completely idle component that is simply waiting for input. A value of 1 would indicate a that is never idle. This value is updated every 5 seconds. + #[configurable(unit = "fraction", tags(..COMPONENT_TAGS))] Utilization, + + /// The number of bytes currently allocated by this component. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] ComponentAllocatedBytes, + + /// The total number of open files. + #[configurable(unit = "file", tags(..COMPONENT_TAGS))] OpenFiles, + + /// The total number of seconds the Vector instance has been up. + #[configurable(unit = "second", tags(..INTERNAL_METRICS_TAGS))] UptimeSeconds, + + /// Has a fixed value of 1.0. Contains build information such as Rust and Vector versions. + #[configurable(unit = "unit", tags { + ..INTERNAL_METRICS_TAGS, + "debug": {"description": "Whether this is a debug build of Vector", "required": true}, + "version": {"description": "Vector version.", "required": true}, + "rust_version": {"description": "The Rust version from the package manifest.", "required": true}, + "arch": {"description": "The target architecture being compiled for. (e.g. x86_64)", "required": true}, + "revision": {"description": "Revision identifer, related to versioned releases.", "required": true} + })] BuildInfo, + + /// Current number of messages in producer queues. + #[configurable(unit = "message", tags(..COMPONENT_TAGS))] KafkaQueueMessages, + + /// Current total size of messages in producer queues. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] KafkaQueueMessagesBytes, + + /// The Kafka consumer lag. + #[configurable(unit = "message", tags { + ..COMPONENT_TAGS, + "topic_id": {"description": "The Kafka topic id.", "required": true}, + "partition_id": {"description": "The Kafka partition id.", "required": true} + })] KafkaConsumerLag, + + /// The total memory currently being used by the Lua runtime. + #[configurable(unit = "byte", tags(..INTERNAL_METRICS_TAGS))] LuaMemoryUsedBytes, + + /// The number of current open connections to Vector. + #[configurable(unit = "connection", tags(..INTERNAL_METRICS_TAGS))] OpenConnections, + + /// The number of currently active endpoints. + #[configurable(unit = "unit", tags(..COMPONENT_TAGS))] ActiveEndpoints, + + /// The number of outstanding Splunk HEC indexer acknowledgement acks. + #[configurable(unit = "response", tags(..COMPONENT_TAGS))] SplunkPendingAcks, + + /// Number of clients attached to a component. + #[configurable(unit = "unit", tags(..COMPONENT_TAGS))] ActiveClients, + + /// The number of objects currently stored in the in-memory enrichment table. + #[configurable(unit = "item", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableObjectsCount, + + /// The total size in bytes of all objects stored in the in-memory enrichment table. + #[configurable(unit = "byte", tags(..COMPONENT_TAGS))] MemoryEnrichmentTableByteSize, + + /// The number of tag keys currently being tracked by the tag cardinality limit transform. + #[configurable(unit = "key", tags(..COMPONENT_TAGS))] TagCardinalityTrackedKeys, + + /// The total number of metrics emitted from the internal metrics registry. + #[configurable(unit = "unit", tags())] + InternalMetricsCardinality, } impl GaugeName { @@ -252,6 +838,7 @@ impl GaugeName { Self::MemoryEnrichmentTableObjectsCount => "memory_enrichment_table_objects_count", Self::MemoryEnrichmentTableByteSize => "memory_enrichment_table_byte_size", Self::TagCardinalityTrackedKeys => "tag_cardinality_tracked_keys", + Self::InternalMetricsCardinality => "internal_metrics_cardinality", } } } @@ -366,6 +953,10 @@ impl CounterName { Self::MemoryEnrichmentTableReadsTotal => "memory_enrichment_table_reads_total", Self::MemoryEnrichmentTableTtlExpirations => "memory_enrichment_table_ttl_expirations", Self::ComponentCpuUsageNsTotal => "component_cpu_usage_ns_total", + Self::ConnectionReadErrorsTotal => "connection_read_errors_total", + Self::InternalMetricsCardinalityTotal => "internal_metrics_cardinality_total", + Self::ConfigReloadRejected => "config_reload_rejected", + Self::Utf8ConvertErrorsTotal => "utf8_convert_errors_total", } } } diff --git a/lib/vector-common/src/internal_event/metric_tags.rs b/lib/vector-common/src/internal_event/metric_tags.rs new file mode 100644 index 0000000000000..2cea4d1e7fdd5 --- /dev/null +++ b/lib/vector-common/src/internal_event/metric_tags.rs @@ -0,0 +1,228 @@ +use serde_json::{Value, json}; +use std::sync::LazyLock; + +/// Clones `base` (a `LazyLock`) and inserts all fields from `extra`. +/// +/// Used by the static tag-set initializers below. +#[must_use] +pub fn merge_lazy(base: &LazyLock, extra: Value) -> Value { + let mut result = (**base).clone(); + if let (Some(obj), Value::Object(extra_obj)) = (result.as_object_mut(), extra) { + obj.extend(extra_obj); + } + result +} + +// ─── Base tag groups ─────────────────────────────────────────────────────────── + +pub static INTERNAL_METRICS_TAGS: LazyLock = LazyLock::new(|| { + json!({ + "pid": {"description": "The process ID of the Vector instance.", "required": false, "examples": ["4232"]}, + "host": {"description": "The hostname of the system Vector is running on.", "required": false, "examples": ["my-host.local"]} + }) +}); + +pub static COMPONENT_TAGS: LazyLock = LazyLock::new(|| { + merge_lazy( + &INTERNAL_METRICS_TAGS, + json!({ + "component_kind": { + "description": "The Vector component kind.", + "required": true, + "enum": { + "sink": "Vector sink components", + "source": "Vector source components", + "transform": "Vector transform components" + } + }, + "component_id": {"description": "The Vector component ID.", "required": true, "examples": ["my_source", "my_sink"]}, + "component_type": {"description": "The Vector component type.", "required": true, "examples": ["file", "http", "honeycomb", "splunk_hec"]} + }), + ) +}); + +// ─── Extensions of COMPONENT_TAGS ───────────────────────────────────────────── + +pub static COMPONENT_TAGS_OUTPUT: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "output": {"description": "The specific output of the component.", "required": false} + }), + ) +}); + +pub static COMPONENT_TAGS_GRPC_METHOD_SERVICE: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "grpc_method": {"description": "The name of the method called on the gRPC service.", "required": true}, + "grpc_service": {"description": "The gRPC service name.", "required": true} + }), + ) +}); + +pub static COMPONENT_TAGS_GRPC_ALL: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS_GRPC_METHOD_SERVICE, + json!({ + "grpc_status": {"description": "The human-readable [gRPC status code](https://grpc.github.io/grpc/core/md_doc_statuscodes.html).", "required": true} + }), + ) +}); + +pub static COMPONENT_TAGS_HTTP_METHOD: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "method": {"description": "The HTTP method of the request.", "required": false} + }), + ) +}); + +pub static COMPONENT_TAGS_HTTP_STATUS: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "status": {"description": "The HTTP status code of the request.", "required": false} + }), + ) +}); + +pub static COMPONENT_TAGS_HTTP_METHOD_PATH: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS_HTTP_METHOD, + json!({ + "path": {"description": "The path that produced the error.", "required": true} + }), + ) +}); + +pub static COMPONENT_TAGS_HTTP_ALL: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS_HTTP_METHOD_PATH, + json!({ + "status": {"description": "The HTTP status code of the request.", "required": false} + }), + ) +}); + +pub static COMPONENT_TAGS_ERROR_TYPE_STAGE: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "error_type": { + "description": "The type of the error", + "required": true, + "enum": { + "acknowledgements_failed": "The acknowledgement operation failed.", + "delete_failed": "The file deletion failed.", + "encode_failed": "The encode operation failed.", + "field_missing": "The event field was missing.", + "glob_failed": "The glob pattern match operation failed.", + "http_error": "The HTTP request resulted in an error code.", + "invalid_metric": "The metric was invalid.", + "kafka_offset_update": "The consumer offset update failed.", + "kafka_read": "The message from Kafka was invalid.", + "mapping_failed": "The mapping failed.", + "match_failed": "The match operation failed.", + "out_of_order": "The event was out of order.", + "parse_failed": "The parsing operation failed.", + "read_failed": "The file read operation failed.", + "render_error": "The rendering operation failed.", + "stream_closed": "The downstream was closed, forwarding the event(s) failed.", + "type_conversion_failed": "The type conversion operating failed.", + "type_field_does_not_exist": "The type field does not exist.", + "type_ip_address_parse_error": "The IP address did not parse.", + "unlabeled_event": "The event was not labeled.", + "value_invalid": "The value was invalid.", + "watch_failed": "The file watch operation failed.", + "write_failed": "The file write operation failed." + } + }, + "stage": { + "description": "The stage within the component at which the error occurred.", + "required": true, + "enum": { + "receiving": "While receiving data.", + "processing": "While processing data within the component.", + "sending": "While sending data." + } + } + }), + ) +}); + +// ─── Extensions of INTERNAL_METRICS_TAGS ────────────────────────────────────── + +pub static INTERNAL_METRICS_TAGS_FILE: LazyLock = LazyLock::new(|| { + merge_lazy( + &INTERNAL_METRICS_TAGS, + json!({ + "file": {"description": "The file that produced the error.", "required": false} + }), + ) +}); + +pub static INTERNAL_METRICS_TAGS_REASON: LazyLock = LazyLock::new(|| { + merge_lazy( + &INTERNAL_METRICS_TAGS, + json!({ + "reason": { + "description": "The type of the error", + "required": true, + "enum": { + "out_of_order": "The event was out of order.", + "oversized": "The event was too large." + } + } + }), + ) +}); + +// ─── Metric-specific tag sets ───────────────────────────────────────────────── + +pub static COMPONENT_RECEIVED_EVENTS_TOTAL_TAGS: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "file": {"description": "The file from which the data originated.", "required": false}, + "uri": {"description": "The sanitized URI from which the data originated.", "required": false}, + "container_name": {"description": "The name of the container from which the data originated.", "required": false}, + "pod_name": {"description": "The name of the pod from which the data originated.", "required": false}, + "peer_addr": {"description": "The IP from which the data originated.", "required": false}, + "peer_path": {"description": "The pathname from which the data originated.", "required": false}, + "mode": { + "description": "The connection mode used by the component.", + "required": false, + "enum": { + "udp": "User Datagram Protocol", + "tcp": "Transmission Control Protocol", + "unix": "Unix domain socket" + } + } + }), + ) +}); + +/// Same tag set as `component_received_events_total` (inherited by byte-count metrics). +pub static COMPONENT_RECEIVED_EVENTS_TAGS: LazyLock = + LazyLock::new(|| COMPONENT_RECEIVED_EVENTS_TOTAL_TAGS.clone()); + +pub static COMPONENT_TAGS_HTTP_ERROR_KIND: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "error_kind": {"description": "The kind of HTTP error encountered (e.g. connection refused, connection reset).", "required": true} + }), + ) +}); + +pub static S3_OBJECT_PROCESSING_TAGS: LazyLock = LazyLock::new(|| { + merge_lazy( + &COMPONENT_TAGS, + json!({ + "bucket": {"description": "The name of the S3 bucket.", "required": true} + }), + ) +}); diff --git a/lib/vector-common/src/internal_event/mod.rs b/lib/vector-common/src/internal_event/mod.rs index e776e89553172..822299ccf19e2 100644 --- a/lib/vector-common/src/internal_event/mod.rs +++ b/lib/vector-common/src/internal_event/mod.rs @@ -6,6 +6,7 @@ pub mod component_events_timed_out; mod events_received; mod events_sent; pub mod metric_name; +pub mod metric_tags; mod optional_tag; mod prelude; pub mod service; diff --git a/lib/vector-config-common/src/constants.rs b/lib/vector-config-common/src/constants.rs index 80284e7c4a505..8fd6ee8b1367f 100644 --- a/lib/vector-config-common/src/constants.rs +++ b/lib/vector-config-common/src/constants.rs @@ -26,7 +26,183 @@ pub const DOCS_META_OPTIONAL: &str = "docs::optional"; pub const DOCS_META_COMMON: &str = "docs::common"; pub const DOCS_META_REQUIRED: &str = "docs::required"; pub const DOCS_META_SYNTAX_OVERRIDE: &str = "docs::syntax_override"; +pub const DOCS_META_TAGS: &str = "docs::tags"; pub const DOCS_META_TEMPLATEABLE: &str = "docs::templateable"; +/// Canonical Datadog metric unit for a metric variant (from https://docs.datadoghq.com/metrics/units/). +pub const DOCS_META_UNIT: &str = "docs::unit"; + +/// All valid canonical Datadog metric units +pub const VALID_METRIC_UNITS: &[&str] = &[ + // bytes / bits + "bit", + "byte", + "kibibyte", + "mebibyte", + "gibibyte", + "tebibyte", + "pebibyte", + "exbibyte", + // time + "nanosecond", + "microsecond", + "millisecond", + "second", + "minute", + "hour", + "day", + "week", + // percentage + "percent_nano", + "percent", + "apdex", + "fraction", + // network + "connection", + "request", + "packet", + "segment", + "response", + "message", + "payload", + "timeout", + "datagram", + "route", + "session", + "hop", + // system + "process", + "thread", + "host", + "node", + "fault", + "service", + "instance", + "cpu", + // disk + "file", + "inode", + "sector", + "block", + // general + "buffer", + "error", + "read", + "write", + "occurrence", + "event", + "time", + "unit", + "operation", + "item", + "task", + "worker", + "resource", + "email", + "sample", + "stage", + "monitor", + "location", + "check", + "attempt", + "device", + "update", + "method", + "job", + "container", + "execution", + "throttle", + "invocation", + "user", + "success", + "build", + "prediction", + "exception", + // database + "table", + "index", + "lock", + "transaction", + "query", + "row", + "key", + "command", + "offset", + "record", + "object", + "cursor", + "assertion", + "scan", + "document", + "shard", + "flush", + "merge", + "refresh", + "fetch", + "column", + "commit", + "wait", + "ticket", + "question", + // cache + "hit", + "miss", + "eviction", + "get", + "set", + // money + "dollar", + "cent", + "microdollar", + "euro", + "pound", + "pence", + "yen", + // memory pages + "page", + "split", + // frequency + "hertz", + "kilohertz", + "megahertz", + "gigahertz", + // logging + "entry", + // temperature + "decidegree celsius", + "degree celsius", + "degree fahrenheit", + // cpu (fractional) + "nanocore", + "microcore", + "millicore", + "core", + "kilocore", + "megacore", + "gigacore", + "teracore", + "petacore", + "exacore", + // power + "nanowatt", + "microwatt", + "milliwatt", + "deciwatt", + "watt", + "kilowatt", + "megawatt", + "gigawatt", + "terrawatt", + // electricity + "milliampere", + "ampere", + "millivolt", + "volt", + // tracing + "span", + // workflow + "run", + "step", +]; pub const DOCS_META_TYPE_OVERRIDE: &str = "docs::type_override"; pub const DOCS_META_TYPE_UNIT: &str = "docs::type_unit"; pub const LOGICAL_NAME: &str = "logical_name"; diff --git a/lib/vector-config-macros/src/ast/mod.rs b/lib/vector-config-macros/src/ast/mod.rs index 581671791be5f..62aa46d8731bc 100644 --- a/lib/vector-config-macros/src/ast/mod.rs +++ b/lib/vector-config-macros/src/ast/mod.rs @@ -13,6 +13,119 @@ use syn::Expr; pub use variant::Variant; use vector_config_common::constants; +/// A `FromMeta` wrapper for the `tags(...)` / `tags { ... }` attribute shorthand. +/// +/// Overrides `from_meta` directly so that darling never attempts to parse the tokens inside the +/// list as `NestedMeta` items (which would fail for spread syntax like `..CONSTANT`). The raw +/// token stream is captured and later converted to a fully self-contained `serde_json::Value` +/// expression by [`TagsTokens::into_value_tokens`], using only paths rooted at `::vector_config`. +/// +/// Accepted forms on a variant: +/// ```text +/// #[configurable(tags())] +/// #[configurable(tags(..COMPONENT_TAGS))] +/// #[configurable(tags { ..COMPONENT_TAGS, "key": { "description": "…", "required": true } })] +/// ``` +#[derive(Clone, Debug)] +pub struct TagsTokens(pub proc_macro2::TokenStream); + +impl FromMeta for TagsTokens { + fn from_meta(item: &syn::Meta) -> darling::Result { + match item { + syn::Meta::List(list) => Ok(TagsTokens(list.tokens.clone())), + _ => Err(darling::Error::unsupported_format( + "expected `tags(...)` or `tags { ... }` list form", + ) + .with_span(item)), + } + } +} + +impl TagsTokens { + /// Returns the captured tag body tokens as a `serde_json::Value` expression. + /// + /// The three forms produce: + /// - `tags()` → `::vector_config::json!({})` + /// - `tags(..BASE)` → `(*BASE).clone()` + /// - `tags { ..BASE, "k": v }` → `::vector_config::merge_tags((*BASE).clone(), ::vector_config::json!({ "k": v }))` + pub fn to_value_tokens(&self) -> proc_macro2::TokenStream { + match syn::parse2::(self.0.clone()) { + Ok(body) => body.into_value_tokens(), + Err(e) => e.to_compile_error(), + } + } +} + +/// Parsed representation of the body inside `tags(...)` / `tags { ... }`. +struct TagsBody { + /// The base tag-set to spread, taken from `..EXPR` at the start of the body. + base: Option, + /// Any additional JSON-object entries that follow the optional spread. + extra: proc_macro2::TokenStream, +} + +impl syn::parse::Parse for TagsBody { + fn parse(input: syn::parse::ParseStream<'_>) -> syn::Result { + if input.is_empty() { + return Ok(TagsBody { + base: None, + extra: proc_macro2::TokenStream::new(), + }); + } + + if input.peek(syn::Token![..]) { + let _: syn::Token![..] = input.parse()?; + let base: syn::Expr = input.parse()?; + // Consume an optional trailing comma that separates the base from extra entries. + if input.peek(syn::Token![,]) { + let _: syn::Token![,] = input.parse()?; + } + let extra: proc_macro2::TokenStream = input.parse()?; + Ok(TagsBody { + base: Some(base), + extra, + }) + } else { + // No spread prefix — treat all tokens as JSON object entries. + let extra: proc_macro2::TokenStream = input.parse()?; + Ok(TagsBody { base: None, extra }) + } + } +} + +impl TagsBody { + fn into_value_tokens(self) -> proc_macro2::TokenStream { + let extra_empty = self.extra.is_empty(); + match (self.base, extra_empty) { + // tags() + (None, true) => quote::quote! { + ::vector_config::json!({}) + }, + // tags { "k": v } + (None, false) => { + let extra = self.extra; + quote::quote! { + ::vector_config::json!({ #extra }) + } + } + // tags(..BASE) + (Some(base), true) => quote::quote! { + (*#base).clone() + }, + // tags { ..BASE, "k": v } + (Some(base), false) => { + let extra = self.extra; + quote::quote! { + ::vector_config::merge_tags( + (*#base).clone(), + ::vector_config::json!({ #extra }), + ) + } + } + } + } +} + const INVALID_VALUE_EXPR: &str = "got function call-style literal value but could not parse as expression"; @@ -231,6 +344,32 @@ impl FromMeta for Metadata { }), } } + // Accept path expressions so callers can reference constants: + // `#[configurable(metadata(docs::tags = INTERNAL_METRICS_TAGS))]` + Expr::Path(path) => Some(LazyCustomAttribute::KeyValue { + key: path_to_string(&nv.path), + value: path.to_token_stream(), + }), + // Accept macro invocations such as `json!({...})` or similar. + Expr::Macro(mac) => Some(LazyCustomAttribute::KeyValue { + key: path_to_string(&nv.path), + value: mac.to_token_stream(), + }), + // Accept reference/deref expressions such as `&*SOME_LAZY_LOCK` + // so callers can coerce `LazyLock` to `&T: Serialize`. + Expr::Reference(r) => Some(LazyCustomAttribute::KeyValue { + key: path_to_string(&nv.path), + value: r.to_token_stream(), + }), + Expr::Unary(u) => Some(LazyCustomAttribute::KeyValue { + key: path_to_string(&nv.path), + value: u.to_token_stream(), + }), + // Accept function calls such as `merge_lazy(&BASE, json!({...}))`. + Expr::Call(c) => Some(LazyCustomAttribute::KeyValue { + key: path_to_string(&nv.path), + value: c.to_token_stream(), + }), expr => { errors .push(darling::Error::unexpected_expr_type(expr).with_span(nmeta)); diff --git a/lib/vector-config-macros/src/ast/variant.rs b/lib/vector-config-macros/src/ast/variant.rs index f579ade744ea8..e98baabb89efd 100644 --- a/lib/vector-config-macros/src/ast/variant.rs +++ b/lib/vector-config-macros/src/ast/variant.rs @@ -1,10 +1,12 @@ -use darling::{FromAttributes, error::Accumulator, util::Flag}; +use darling::{FromAttributes, error::Accumulator, util::Override}; use proc_macro2::{Ident, TokenStream}; use quote::ToTokens; use serde_derive_internals::ast as serde_ast; +use vector_config_common::constants; +use vector_config_common::constants::VALID_METRIC_UNITS; use super::{ - Field, LazyCustomAttribute, Metadata, Style, Tagging, + Field, LazyCustomAttribute, Metadata, Style, Tagging, TagsTokens, util::{DarlingResultIterator, has_flag_attribute, try_extract_doc_title_description}, }; @@ -149,7 +151,20 @@ impl<'a> Variant<'a> { /// standard `#[deprecated]` attribute, neither automatically applying it nor deriving the /// deprecation status of a variant when it is present. pub fn deprecated(&self) -> bool { - self.attrs.deprecated.is_present() + self.attrs.deprecated.is_some() + } + + /// The deprecation message, if one has been set. + /// + /// Set via `#[configurable(deprecated = "message")]`. + pub fn deprecated_message(&self) -> Option<&String> { + self.attrs + .deprecated + .as_ref() + .and_then(|message| match message { + Override::Inherit => None, + Override::Explicit(message) => Some(message), + }) } /// Whether or not this variant is visible during either serialization or deserialization. @@ -166,12 +181,29 @@ impl<'a> Variant<'a> { /// Attributes can take the shape of flags (`#[configurable(metadata(im_a_teapot))]`) or /// key/value pairs (`#[configurable(metadata(status = "beta"))]`) to allow rich, semantic /// metadata to be attached directly to variants. + /// + /// The `tags` shorthand (`#[configurable(tags(...))]`) is also included here + /// as a `docs::tags` key/value custom attribute. The `unit` shorthand + /// (`#[configurable(unit = "byte")]`) is included as `docs::unit`. pub fn metadata(&self) -> impl Iterator { + let tags_attr = self + .attrs + .tags + .as_ref() + .map(|t| LazyCustomAttribute::kv(constants::DOCS_META_TAGS, t.to_value_tokens())); + + let unit_attr = self.attrs.unit.as_deref().map(|u| { + let u = u.to_string(); + LazyCustomAttribute::kv(constants::DOCS_META_UNIT, quote::quote!(#u)) + }); + self.attrs .metadata .clone() .into_iter() .flat_map(|metadata| metadata.attributes()) + .chain(tags_attr) + .chain(unit_attr) } } @@ -186,7 +218,16 @@ impl ToTokens for Variant<'_> { struct Attributes { title: Option, description: Option, - deprecated: Flag, + deprecated: Option>, + /// Shorthand for `#[configurable(metadata(docs::tags = ...))]`. + /// + /// Accepts `tags(...)` or `tags { ... }` list forms; the spread body is + /// parsed by the proc macro and expanded inline to a `serde_json::Value` expression. + tags: Option, + /// Canonical Datadog metric unit. Must be one of the values in [`VALID_METRIC_UNITS`]. + /// + /// Example: `#[configurable(unit = "event")]` + unit: Option, #[darling(skip)] visible: bool, #[darling(multiple)] @@ -209,6 +250,16 @@ impl Attributes { self.title = self.title.or(doc_title); self.description = self.description.or(doc_description); + // Validate the unit against the canonical Datadog unit list. + if let Some(ref unit) = self.unit + && !VALID_METRIC_UNITS.contains(&unit.as_str()) + { + let valid = VALID_METRIC_UNITS.join(", "); + return Err(darling::Error::custom(format!( + "unknown metric unit `{unit}`; valid units are: {valid}" + ))); + } + Ok(self) } } diff --git a/lib/vector-config-macros/src/configurable.rs b/lib/vector-config-macros/src/configurable.rs index 43d5c9483bbcd..73b8666ae80e8 100644 --- a/lib/vector-config-macros/src/configurable.rs +++ b/lib/vector-config-macros/src/configurable.rs @@ -490,6 +490,8 @@ fn generate_variant_metadata( let maybe_title = get_metadata_title(meta_ident, variant.title()); let maybe_description = get_metadata_description(meta_ident, variant.description()); let maybe_deprecated = get_metadata_deprecated(meta_ident, variant.deprecated()); + let maybe_deprecated_message = + get_metadata_deprecated_message(meta_ident, variant.deprecated_message()); // We have to mark variants as transparent, so that if we're dealing with an untagged enum, we // don't panic if their description is intentionally left out. @@ -520,6 +522,7 @@ fn generate_variant_metadata( #maybe_title #maybe_description #maybe_deprecated + #maybe_deprecated_message #maybe_transparent #maybe_custom_attributes #variant_logical_name diff --git a/lib/vector-config/src/lib.rs b/lib/vector-config/src/lib.rs index 4aa2e2a93b52c..45ba11cf6fe0d 100644 --- a/lib/vector-config/src/lib.rs +++ b/lib/vector-config/src/lib.rs @@ -110,6 +110,25 @@ pub mod indexmap { } pub use serde_json; +// Explicit re-export of the `json!` macro so generated code can reference it as +// `::vector_config::json!(...)` without requiring a direct `serde_json` dependency at the +// callsite. +pub use serde_json::json; + +/// Merges all fields from `extra` into `base` (both must be JSON objects). +/// +/// Used exclusively by code generated from `#[configurable(tags { ..BASE, ... })]` so that the +/// merge logic is fully self-contained within `vector_config` and does not require `merge_lazy` +/// or any other helper from the callsite crate. +#[doc(hidden)] +pub fn merge_tags(mut base: serde_json::Value, extra: serde_json::Value) -> serde_json::Value { + if let serde_json::Value::Object(ref mut m) = base + && let serde_json::Value::Object(e) = extra + { + m.extend(e); + } + base +} pub mod component; mod configurable; diff --git a/src/generate_schema.rs b/src/generate_schema.rs index 72204e3945d91..623a6f187948e 100644 --- a/src/generate_schema.rs +++ b/src/generate_schema.rs @@ -3,6 +3,8 @@ use std::{fs, path::PathBuf}; use clap::Parser; +use serde_json::{Value, json}; +use vector_common::internal_event::{CounterName, GaugeName, HistogramName}; use vector_lib::configurable::schema::generate_root_schema; use crate::config::ConfigBuilder; @@ -16,11 +18,29 @@ pub struct Opts { pub(crate) output_path: Option, } +fn metric_enum_schema() -> Value { + generate_root_schema::() + .map(|s| serde_json::to_value(s).unwrap_or(Value::Null)) + .unwrap_or(Value::Null) +} + /// Execute the `generate-schema` command. #[allow(clippy::print_stdout, clippy::print_stderr)] pub fn cmd(opts: &Opts) -> exitcode::ExitCode { match generate_root_schema::() { - Ok(schema) => { + Ok(config_schema) => { + // Convert to Value so we can inject the metric enum schemas. + let mut schema = serde_json::to_value(config_schema) + .expect("rendering root schema to JSON should not fail"); + + // Inject metric name enum schemas so vdev can generate + // internal_metrics.cue output descriptions from them. + schema["_metric_schemas"] = json!({ + "counters": metric_enum_schema::(), + "histograms": metric_enum_schema::(), + "gauges": metric_enum_schema::(), + }); + let json = serde_json::to_string_pretty(&schema) .expect("rendering root schema to JSON should not fail"); diff --git a/vdev/src/commands/build/component_docs/runner.rs b/vdev/src/commands/build/component_docs/runner.rs index 7b9eb3dbbfbac..f2a0125141179 100644 --- a/vdev/src/commands/build/component_docs/runner.rs +++ b/vdev/src/commands/build/component_docs/runner.rs @@ -71,6 +71,153 @@ pub fn run(schema_path: &Path) -> Result<()> { // is now rendered as a top-level field with `group: "api"`. render_and_import_generated_top_level_config_schema(&mut context, &root_schema)?; + // 4. Generate internal_metric_descriptions.cue from the metric name enums + // injected into the schema by `vector generate-schema`. + if let Some(metric_schemas) = root_schema.get("_metric_schemas") { + generate_internal_metric_descriptions(&mut context, metric_schemas)?; + } + + Ok(()) +} + +/// Collects all metric variants from `metric_schemas` into an alphabetically-sorted JSON map. +fn collect_metric_entries(metric_schemas: &Value) -> std::collections::BTreeMap { + let mut metrics = std::collections::BTreeMap::new(); + for (metric_type, schema) in [ + ("counter", metric_schemas.get("counters")), + ("histogram", metric_schemas.get("histograms")), + ("gauge", metric_schemas.get("gauges")), + ] { + let Some(schema) = schema else { continue }; + for variant in schema + .get("oneOf") + .and_then(Value::as_array) + .into_iter() + .flatten() + { + let Some(name) = variant.get("const").and_then(Value::as_str) else { + continue; + }; + let title = variant.get("title").and_then(Value::as_str); + let body = variant.get("description").and_then(Value::as_str); + let desc_owned; + let desc = match (title, body) { + (Some(t), Some(b)) => { + desc_owned = format!("{t}\n\n{b}"); + desc_owned.as_str() + } + (Some(t), None) => t, + (None, Some(b)) => b, + (None, None) => continue, + }; + let tags = if let Some(v @ Value::Object(_)) = + variant.get("_metadata").and_then(|m| m.get("docs::tags")) + { + v.clone() + } else { + warn!( + "metric variant '{}' has no docs::tags metadata — \ + add #[configurable(metadata(docs::tags = ...))] to the enum variant", + name + ); + continue; + }; + let unit = variant + .get("_metadata") + .and_then(|m| m.get("docs::unit")) + .and_then(Value::as_str) + .map(str::to_owned); + let deprecated = variant + .get("deprecated") + .and_then(Value::as_bool) + .unwrap_or(false); + let mut entry = json!({ + "description": desc, + "type": metric_type, + "default_namespace": "vector", + "tags": tags, + }); + if let Some(u) = unit { + entry["unit"] = json!(u); + } + if deprecated { + entry["deprecated"] = json!(true); + if let Some(msg) = variant + .get("_metadata") + .and_then(|m| m.get("deprecated_message")) + .and_then(Value::as_str) + { + entry["deprecated_message"] = json!(msg); + } + } + metrics.insert(name.to_owned(), entry); + } + } + metrics +} + +fn generate_internal_metric_descriptions( + context: &mut SchemaContext, + metric_schemas: &Value, +) -> Result<()> { + let out_path = + PathBuf::from("website/cue/reference/generated/internal_metric_descriptions.cue"); + + let metrics_value: serde_json::Map = + collect_metric_entries(metric_schemas).into_iter().collect(); + + let data = json!({ + "components": { + "sources": { + "internal_metrics": { + "output": { + "metrics": Value::Object(metrics_value) + } + } + } + } + }); + + let json_str = serde_json::to_string_pretty(&data)?; + let json_file = write_to_temp_file("internal-metric-descriptions-", ".json", &json_str)?; + + if let Some(parent) = out_path.parent() { + fs::create_dir_all(parent)?; + } + + let status = Command::new(&context.cue_binary_path) + .args([ + "import", + "-f", + "-o", + out_path.to_str().unwrap(), + "-p", + "metadata", + json_file.to_str().unwrap(), + ]) + .status()?; + + if !status.success() { + bail!( + "Failed to import internal metric descriptions as valid CUE \ + (cue exit status {status}). JSON written to {json_path}.", + json_path = json_file.display() + ); + } + + // Prepend the auto-generated header so editors know not to edit the file directly. + let generated = fs::read_to_string(&out_path)?; + let header = "// Auto-generated by `vdev build component-docs`.\n\ + // Do not edit manually — update the doc comment (or #[configurable(deprecated)]\n\ + // attribute) on the relevant CounterName / HistogramName / GaugeName variant in\n\ + // lib/vector-common/src/internal_event/metric_name.rs instead,\n\ + // then re-run `make generate-component-docs`.\n"; + fs::write(&out_path, format!("{header}{generated}"))?; + + info!( + "[✓] Wrote internal metric descriptions to '{}'.", + out_path.display() + ); Ok(()) } diff --git a/website/cue/reference/components.cue b/website/cue/reference/components.cue index 4e6bb70a01963..b2f603021ba0d 100644 --- a/website/cue/reference/components.cue +++ b/website/cue/reference/components.cue @@ -474,6 +474,8 @@ components: { name?: Name type?: #MetricType default_namespace?: string + // Canonical Datadog metric unit (https://docs.datadoghq.com/metrics/units/). + unit?: string } #OutputData: { diff --git a/website/cue/reference/generated/internal_metric_descriptions.cue b/website/cue/reference/generated/internal_metric_descriptions.cue new file mode 100644 index 0000000000000..ff7c485bda4dc --- /dev/null +++ b/website/cue/reference/generated/internal_metric_descriptions.cue @@ -0,0 +1,6186 @@ +// Auto-generated by `vdev build component-docs`. +// Do not edit manually — update the doc comment (or #[configurable(deprecated)] +// attribute) on the relevant CounterName / HistogramName / GaugeName variant in +// lib/vector-common/src/internal_event/metric_name.rs instead, +// then re-run `make generate-component-docs`. +package metadata + +components: sources: internal_metrics: output: metrics: { + active_clients: { + description: "Number of clients attached to a component." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "unit" + } + active_endpoints: { + description: "The number of currently active endpoints." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "unit" + } + adaptive_concurrency_averaged_rtt: { + description: "The average round-trip time (RTT) for the current window." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + adaptive_concurrency_back_pressure: { + description: "A boolean sample (1.0 if back pressure was observed during the current window, 0.0 otherwise)." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "fraction" + } + adaptive_concurrency_in_flight: { + description: "The number of outbound requests currently awaiting a response." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "request" + } + adaptive_concurrency_limit: { + description: "The concurrency limit that the adaptive concurrency feature has decided on for this current window." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "unit" + } + adaptive_concurrency_observed_rtt: { + description: "The observed round-trip time (RTT) for requests." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + adaptive_concurrency_past_rtt_mean: { + description: "The mean round-trip time (RTT) from past windows, used as the baseline for adaptive concurrency decisions." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + adaptive_concurrency_reached_limit: { + description: "A boolean sample (1.0 if the concurrency limit was reached during the most recent limit update, 0.0 otherwise)." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "fraction" + } + aggregate_events_recorded_total: { + description: "The number of events recorded by the aggregate transform." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + aggregate_failed_updates: { + description: "The number of failed metric updates, `incremental` adds, encountered by the aggregate transform." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + aggregate_flushes_total: { + description: "The number of flushes done by the aggregate transform." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + api_started_total: { + description: "The number of times the Vector API has been started." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + buffer_byte_size: { + description: "The number of bytes currently in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`buffer_size_bytes`](#buffer_size_bytes)." + } + buffer_discarded_bytes_total: { + description: "The number of bytes dropped by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + buffer_discarded_events_total: { + description: "The number of events dropped by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + buffer_errors_total: { + description: "The total number of buffer errors encountered." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "error" + } + buffer_events: { + description: "The number of events currently in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`buffer_size_events`](#buffer_size_events)." + } + buffer_max_byte_size: { + description: "The maximum size in bytes that the buffer can store." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`buffer_max_size_bytes`](#buffer_max_size_bytes)." + } + buffer_max_event_size: { + description: "The maximum size in events that the buffer can store." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`buffer_max_size_events`](#buffer_max_size_events)." + } + buffer_max_size_bytes: { + description: "The maximum number of bytes in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + buffer_max_size_events: { + description: "The maximum number of events in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + buffer_received_bytes_total: { + description: "The number of bytes received by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + buffer_received_events_total: { + description: "The number of events received by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + buffer_send_duration_seconds: { + description: "The duration spent sending a payload to this buffer." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + buffer_sent_bytes_total: { + description: "The number of bytes sent by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + buffer_sent_events_total: { + description: "The number of events sent by this buffer." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + buffer_size_bytes: { + description: "The number of bytes currently in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + buffer_size_events: { + description: "The number of events currently in the buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + build_info: { + description: "Has a fixed value of 1.0. Contains build information such as Rust and Vector versions." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + debug: { + description: "Whether this is a debug build of Vector" + required: true + } + version: { + description: "Vector version." + required: true + } + rust_version: { + description: "The Rust version from the package manifest." + required: true + } + arch: { + description: "The target architecture being compiled for. (e.g. x86_64)" + required: true + } + revision: { + description: "Revision identifer, related to versioned releases." + required: true + } + } + unit: "unit" + } + checkpoints_total: { + description: "The total number of files checkpointed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "file" + } + checksum_errors_total: { + description: "The total number of errors identifying files via checksum." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + file: { + description: "The file that produced the error." + required: false + } + } + unit: "error" + } + collect_completed_total: { + description: "The total number of metrics collections completed for this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + collect_duration_seconds: { + description: "The duration spent collecting metrics for this component." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "second" + } + command_executed_total: { + description: "The total number of times a command has been executed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "execution" + } + command_execution_duration_seconds: { + description: "The command execution duration in seconds." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + component_allocated_bytes: { + description: "The number of bytes currently allocated by this component." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + component_allocated_bytes_total: { + description: "The total number of bytes allocated by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + component_deallocated_bytes_total: { + description: "The total number of bytes deallocated by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + component_discarded_events_total: { + description: "The number of events dropped by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + intentional: { + description: "True if the events were discarded intentionally, like a `filter` transform, or false if due to an error." + required: true + } + } + unit: "event" + } + component_errors_total: { + description: "The total number of errors encountered by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + error_type: { + description: "The type of the error" + required: true + enum: { + acknowledgements_failed: "The acknowledgement operation failed." + delete_failed: "The file deletion failed." + encode_failed: "The encode operation failed." + field_missing: "The event field was missing." + glob_failed: "The glob pattern match operation failed." + http_error: "The HTTP request resulted in an error code." + invalid_metric: "The metric was invalid." + kafka_offset_update: "The consumer offset update failed." + kafka_read: "The message from Kafka was invalid." + mapping_failed: "The mapping failed." + match_failed: "The match operation failed." + out_of_order: "The event was out of order." + parse_failed: "The parsing operation failed." + read_failed: "The file read operation failed." + render_error: "The rendering operation failed." + stream_closed: "The downstream was closed, forwarding the event(s) failed." + type_conversion_failed: "The type conversion operating failed." + type_field_does_not_exist: "The type field does not exist." + type_ip_address_parse_error: "The IP address did not parse." + unlabeled_event: "The event was not labeled." + value_invalid: "The value was invalid." + watch_failed: "The file watch operation failed." + write_failed: "The file write operation failed." + } + } + stage: { + description: "The stage within the component at which the error occurred." + required: true + enum: { + receiving: "While receiving data." + processing: "While processing data within the component." + sending: "While sending data." + } + } + } + unit: "error" + } + component_latency_mean_seconds: { + description: """ + The mean elapsed time, in fractional seconds, that an event spends in a single transform. + + This includes both the time spent queued in the transform's input buffer and the time spent + executing the transform itself. This value is smoothed over time using an exponentially + weighted moving average (EWMA). + """ + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "second" + } + component_latency_seconds: { + description: """ + The elapsed time, in fractional seconds, that an event spends in a single transform. + + This includes both the time spent queued in the transform's input buffer and the time spent + executing the transform itself. + """ + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "second" + } + component_received_bytes: { + description: "The size in bytes of each event received by the source." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + file: { + description: "The file from which the data originated." + required: false + } + uri: { + description: "The sanitized URI from which the data originated." + required: false + } + container_name: { + description: "The name of the container from which the data originated." + required: false + } + pod_name: { + description: "The name of the pod from which the data originated." + required: false + } + peer_addr: { + description: "The IP from which the data originated." + required: false + } + peer_path: { + description: "The pathname from which the data originated." + required: false + } + mode: { + description: "The connection mode used by the component." + required: false + enum: { + udp: "User Datagram Protocol" + tcp: "Transmission Control Protocol" + unix: "Unix domain socket" + } + } + } + unit: "byte" + } + component_received_bytes_total: { + description: "The number of raw bytes accepted by this component from source origins." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + file: { + description: "The file from which the data originated." + required: false + } + uri: { + description: "The sanitized URI from which the data originated." + required: false + } + container_name: { + description: "The name of the container from which the data originated." + required: false + } + pod_name: { + description: "The name of the pod from which the data originated." + required: false + } + peer_addr: { + description: "The IP from which the data originated." + required: false + } + peer_path: { + description: "The pathname from which the data originated." + required: false + } + mode: { + description: "The connection mode used by the component." + required: false + enum: { + udp: "User Datagram Protocol" + tcp: "Transmission Control Protocol" + unix: "Unix domain socket" + } + } + } + unit: "byte" + } + component_received_event_bytes_total: { + description: """ + The number of event bytes accepted by this component either from + tagged origins like file and uri, or cumulatively from other origins. + """ + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + file: { + description: "The file from which the data originated." + required: false + } + uri: { + description: "The sanitized URI from which the data originated." + required: false + } + container_name: { + description: "The name of the container from which the data originated." + required: false + } + pod_name: { + description: "The name of the pod from which the data originated." + required: false + } + peer_addr: { + description: "The IP from which the data originated." + required: false + } + peer_path: { + description: "The pathname from which the data originated." + required: false + } + mode: { + description: "The connection mode used by the component." + required: false + enum: { + udp: "User Datagram Protocol" + tcp: "Transmission Control Protocol" + unix: "Unix domain socket" + } + } + } + unit: "byte" + } + component_received_events_count: { + description: """ + A histogram of the number of events passed in each internal batch in Vector's internal topology. + + Note that this is separate than sink-level batching. It is mostly useful for low level debugging + performance issues in Vector due to small internal batches. + """ + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + file: { + description: "The file from which the data originated." + required: false + } + uri: { + description: "The sanitized URI from which the data originated." + required: false + } + container_name: { + description: "The name of the container from which the data originated." + required: false + } + pod_name: { + description: "The name of the pod from which the data originated." + required: false + } + peer_addr: { + description: "The IP from which the data originated." + required: false + } + peer_path: { + description: "The pathname from which the data originated." + required: false + } + mode: { + description: "The connection mode used by the component." + required: false + enum: { + udp: "User Datagram Protocol" + tcp: "Transmission Control Protocol" + unix: "Unix domain socket" + } + } + } + unit: "event" + } + component_received_events_total: { + description: """ + The number of events accepted by this component either from tagged + origins like file and uri, or cumulatively from other origins. + """ + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + file: { + description: "The file from which the data originated." + required: false + } + uri: { + description: "The sanitized URI from which the data originated." + required: false + } + container_name: { + description: "The name of the container from which the data originated." + required: false + } + pod_name: { + description: "The name of the pod from which the data originated." + required: false + } + peer_addr: { + description: "The IP from which the data originated." + required: false + } + peer_path: { + description: "The pathname from which the data originated." + required: false + } + mode: { + description: "The connection mode used by the component." + required: false + enum: { + udp: "User Datagram Protocol" + tcp: "Transmission Control Protocol" + unix: "Unix domain socket" + } + } + } + unit: "event" + } + component_sent_bytes_total: { + description: "The number of raw bytes sent by this component to destination sinks." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + endpoint: { + description: "The endpoint to which the bytes were sent. For HTTP, this will be the host and path only, excluding the query string." + required: false + } + file: { + description: "The absolute path of the destination file." + required: false + } + protocol: { + description: "The protocol used to send the bytes." + required: true + } + region: { + description: "The AWS region name to which the bytes were sent. In some configurations, this may be a literal hostname." + required: false + } + } + unit: "byte" + } + component_sent_event_bytes_total: { + description: "The total number of event bytes emitted by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "byte" + } + component_sent_events_total: { + description: "The total number of events emitted by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "event" + } + component_timed_out_events_total: { + description: "The total number of events for which this source responded with a timeout error." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + component_timed_out_requests_total: { + description: "The total number of requests for which this source responded with a timeout error." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "request" + } + config_reload_rejected: { + description: "Number of configuration reload attempts that were rejected." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + reason: { + description: "The type of the error" + required: true + enum: { + out_of_order: "The event was out of order." + oversized: "The event was too large." + } + } + } + unit: "occurrence" + } + connection_established_total: { + description: "The total number of times a connection has been established." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "connection" + } + connection_read_errors_total: { + description: "The total number of errors reading datagram." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + mode: { + description: "The connection mode used by the component." + required: true + enum: udp: "User Datagram Protocol" + } + } + unit: "error" + } + connection_send_errors_total: { + description: "The total number of errors sending data via the connection." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "error" + } + connection_shutdown_total: { + description: "The total number of times the connection has been shut down." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "connection" + } + container_processed_events_total: { + description: "The total number of container events processed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + containers_unwatched_total: { + description: "The total number of times Vector stopped watching for container logs." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + containers_watched_total: { + description: "The total number of times Vector started watching for container logs." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + decoder_bom_removals_total: { + description: "The total number of byte order marks (BOM) removed from incoming data." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + decoder_malformed_replacement_warnings_total: { + description: "The total number of warnings when replacing malformed characters during decoding." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + doris_bytes_loaded_total: { + description: "The total number of bytes loaded into Doris." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + doris_rows_filtered_total: { + description: "The total number of rows filtered by Doris during stream load." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "row" + } + doris_rows_loaded_total: { + description: "The total number of rows successfully loaded into Doris." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "row" + } + encoder_unmappable_replacement_warnings_total: { + description: "The total number of warnings when replacing unmappable characters during encoding." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + events_discarded_total: { + description: "The total number of events discarded by this component." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + reason: { + description: "The type of the error" + required: true + enum: { + out_of_order: "The event was out of order." + oversized: "The event was too large." + } + } + } + unit: "event" + } + files_added_total: { + description: "The total number of files Vector has found to watch." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + file: { + description: "The file that produced the error." + required: false + } + } + unit: "file" + } + files_deleted_total: { + description: "The total number of files deleted." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + file: { + description: "The file that produced the error." + required: false + } + } + unit: "file" + } + files_resumed_total: { + description: "The total number of times Vector has resumed watching a file." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + file: { + description: "The file that produced the error." + required: false + } + } + unit: "occurrence" + } + files_unwatched_total: { + description: "The total number of times Vector has stopped watching a file." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + file: { + description: "The file that produced the error." + required: false + } + } + unit: "occurrence" + } + grpc_server_handler_duration_seconds: { + description: "The duration spent handling a gRPC request." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + grpc_method: { + description: "The name of the method called on the gRPC service." + required: true + } + grpc_service: { + description: "The gRPC service name." + required: true + } + grpc_status: { + description: "The human-readable [gRPC status code](https://grpc.github.io/grpc/core/md_doc_statuscodes.html)." + required: true + } + } + unit: "second" + } + grpc_server_messages_received_total: { + description: "The total number of gRPC messages received." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + grpc_method: { + description: "The name of the method called on the gRPC service." + required: true + } + grpc_service: { + description: "The gRPC service name." + required: true + } + } + unit: "message" + } + grpc_server_messages_sent_total: { + description: "The total number of gRPC messages sent." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + grpc_method: { + description: "The name of the method called on the gRPC service." + required: true + } + grpc_service: { + description: "The gRPC service name." + required: true + } + grpc_status: { + description: "The human-readable [gRPC status code](https://grpc.github.io/grpc/core/md_doc_statuscodes.html)." + required: true + } + } + unit: "message" + } + http_client_error_rtt_seconds: { + description: "The round-trip time (RTT) of HTTP requests that resulted in an error." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + error_kind: { + description: "The kind of HTTP error encountered (e.g. connection refused, connection reset)." + required: true + } + } + unit: "second" + } + http_client_errors_total: { + description: "The total number of HTTP client errors encountered." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + error_kind: { + description: "The kind of HTTP error encountered (e.g. connection refused, connection reset)." + required: true + } + } + unit: "error" + } + http_client_requests_sent_total: { + description: "The total number of sent HTTP requests, tagged with the request method." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + method: { + description: "The HTTP method of the request." + required: false + } + } + unit: "request" + } + http_client_response_rtt_seconds: { + description: "The round-trip time (RTT) of HTTP requests, tagged with the response code." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + status: { + description: "The HTTP status code of the request." + required: false + } + } + unit: "second" + } + http_client_responses_total: { + description: "The total number of HTTP requests, tagged with the response code." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + status: { + description: "The HTTP status code of the request." + required: false + } + } + unit: "response" + } + http_client_rtt_seconds: { + description: "The round-trip time (RTT) of HTTP requests." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + http_server_handler_duration_seconds: { + description: "The duration spent handling an HTTP request." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + method: { + description: "The HTTP method of the request." + required: false + } + path: { + description: "The path that produced the error." + required: true + } + status: { + description: "The HTTP status code of the request." + required: false + } + } + unit: "second" + } + http_server_requests_received_total: { + description: "The total number of HTTP requests received." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + method: { + description: "The HTTP method of the request." + required: false + } + path: { + description: "The path that produced the error." + required: true + } + } + unit: "request" + } + http_server_responses_sent_total: { + description: "The total number of HTTP responses sent." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + method: { + description: "The HTTP method of the request." + required: false + } + path: { + description: "The path that produced the error." + required: true + } + status: { + description: "The HTTP status code of the request." + required: false + } + } + unit: "response" + } + internal_metrics_cardinality: { + description: "The total number of metrics emitted from the internal metrics registry." + type: "gauge" + default_namespace: "vector" + tags: {} + unit: "unit" + } + internal_metrics_cardinality_total: { + description: "The total number of metrics emitted from the internal metrics registry. This metric is deprecated in favor of `internal_metrics_cardinality`." + type: "counter" + default_namespace: "vector" + tags: {} + unit: "unit" + } + k8s_docker_format_parse_failures_total: { + description: "The total number of failures to parse a message as a JSON object." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + k8s_event_namespace_annotation_failures_total: { + description: "The total number of failures to annotate Kubernetes events with namespace metadata." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + k8s_event_node_annotation_failures_total: { + description: "The total number of failures to annotate Kubernetes events with node metadata." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + k8s_format_picker_edge_cases_total: { + description: "The total number of edge cases encountered while picking format of the Kubernetes log message." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + kafka_consumed_messages_bytes_total: { + description: "Total number of message bytes (including framing) received from Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + kafka_consumed_messages_total: { + description: "Total number of messages consumed, not including ignored messages (due to offset, etc), from Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + kafka_consumer_lag: { + description: "The Kafka consumer lag." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + topic_id: { + description: "The Kafka topic id." + required: true + } + partition_id: { + description: "The Kafka partition id." + required: true + } + } + unit: "message" + } + kafka_produced_messages_bytes_total: { + description: "Total number of message bytes (including framing, such as per-Message framing and MessageSet/batch framing) transmitted to Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + kafka_produced_messages_total: { + description: "Total number of messages transmitted (produced) to Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + kafka_queue_messages: { + description: "Current number of messages in producer queues." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + kafka_queue_messages_bytes: { + description: "Current total size of messages in producer queues." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + kafka_requests_bytes_total: { + description: "Total number of bytes transmitted to Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + kafka_requests_total: { + description: "Total number of requests sent to Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "request" + } + kafka_responses_bytes_total: { + description: "Total number of bytes received from Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + kafka_responses_total: { + description: "Total number of responses received from Kafka brokers." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "response" + } + lua_memory_used_bytes: { + description: "The total memory currently being used by the Lua runtime." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "byte" + } + memory_enrichment_table_byte_size: { + description: "The total size in bytes of all objects stored in the in-memory enrichment table." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + memory_enrichment_table_failed_insertions: { + description: "The total number of failed insertions into the in-memory enrichment table." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + memory_enrichment_table_failed_reads: { + description: "The total number of failed reads from the in-memory enrichment table." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + memory_enrichment_table_flushes_total: { + description: "The total number of flushes of the in-memory enrichment table." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "flush" + } + memory_enrichment_table_insertions_total: { + description: "The total number of successful insertions into the in-memory enrichment table." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + memory_enrichment_table_objects_count: { + description: "The number of objects currently stored in the in-memory enrichment table." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "item" + } + memory_enrichment_table_reads_total: { + description: "The total number of successful reads from the in-memory enrichment table." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "read" + } + memory_enrichment_table_ttl_expirations: { + description: "The total number of entries evicted from the in-memory enrichment table due to TTL expiration." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "eviction" + } + metadata_refresh_failed_total: { + description: "The total number of failed efforts to refresh AWS EC2 metadata." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + metadata_refresh_successful_total: { + description: "The total number of AWS EC2 metadata refreshes." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + open_connections: { + description: "The number of current open connections to Vector." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "connection" + } + open_files: { + description: "The total number of open files." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "file" + } + parse_errors_total: { + description: "The total number of errors encountered while parsing." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "error" + } + quit_total: { + description: "The total number of times the Vector instance has quit." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + reloaded_total: { + description: "The total number of times the Vector instance has been reloaded." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + rewritten_timestamp_events_total: { + description: "The total number of events whose timestamps were rewritten to maintain ordering." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + s3_object_processing_failed_duration_seconds: { + description: "The time taken to process an S3 object that failed, in seconds." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + bucket: { + description: "The name of the S3 bucket." + required: true + } + } + unit: "second" + } + s3_object_processing_succeeded_duration_seconds: { + description: "The time taken to process an S3 object that succeeded, in seconds." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + bucket: { + description: "The name of the S3 bucket." + required: true + } + } + unit: "second" + } + source_buffer_max_byte_size: { + description: "The maximum number of bytes the source buffer can hold. The outputs of the source send data to this buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "byte" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`source_buffer_max_size_bytes`](#source_buffer_max_size_bytes)." + } + source_buffer_max_event_size: { + description: "The maximum number of events the source buffer can hold. The outputs of the source send data to this buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "event" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`source_buffer_max_size_events`](#source_buffer_max_size_events)." + } + source_buffer_max_size_bytes: { + description: "The maximum number of bytes the source buffer can hold. The outputs of the source send data to this buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "byte" + } + source_buffer_max_size_events: { + description: "The maximum number of events the source buffer can hold. The outputs of the source send data to this buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "event" + } + source_buffer_utilization: { + description: "The utilization level of the source buffer. The outputs of the source send data to this buffer." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + source_buffer_utilization_level: { + description: "The current utilization level of the source buffer. The outputs of the source send data to this buffer." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + source_buffer_utilization_mean: { + description: "The mean utilization level of the source buffer. The outputs of the source send data to this buffer. The mean utilization is smoothed over time using an exponentially weighted moving average (EWMA)." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + source_lag_time_seconds: { + description: "The difference between the timestamp recorded in each event and the time when it was ingested, expressed as fractional seconds." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + source_send_batch_latency_seconds: { + description: "The time elapsed blocking on the downstream channel to accept an entire batch of events received at the source." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + source_send_latency_seconds: { + description: "The time elapsed blocking on the downstream channel to accept a single chunk from a batch of events received at the source." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "second" + } + splunk_pending_acks: { + description: "The number of outstanding Splunk HEC indexer acknowledgement acks." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "response" + } + sqs_message_defer_succeeded_total: { + description: "The total number of successful deferrals of SQS messages." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + sqs_message_delete_succeeded_total: { + description: "The total number of successful deletions of SQS messages." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + sqs_message_processing_succeeded_total: { + description: "The total number of SQS messages successfully processed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + sqs_message_receive_succeeded_total: { + description: "The total number of times successfully receiving SQS messages." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + sqs_message_received_messages_total: { + description: "The total number of received SQS messages." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + sqs_s3_event_record_ignored_total: { + description: "The total number of times an S3 record in an SQS message was ignored (for an event that was not `ObjectCreated`)." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + ignore_type: { + description: "The reason for ignoring the S3 record" + required: true + enum: invalid_event_kind: "The kind of invalid event." + } + } + unit: "event" + } + stale_events_flushed_total: { + description: "The number of stale events that Vector has flushed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + started_total: { + description: "The total number of times the Vector instance has been started." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + stopped_total: { + description: "The total number of times the Vector instance has been stopped." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + tag_cardinality_tracked_keys: { + description: "The number of tag keys currently being tracked by the tag cardinality limit transform." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "key" + } + tag_cardinality_untracked_events_total: { + description: "The total number of events whose tag keys are no longer tracked because `max_tracked_keys` was reached. These events pass through the transform unchecked." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "event" + } + tag_value_limit_exceeded_total: { + description: """ + The total number of events discarded because the tag has been rejected after + hitting the configured `value_limit`. When `internal_metrics.include_extended_tags` + is enabled in the `tag_cardinality_limit` transform, this metric includes + `metric_name` and `tag_key` labels. By default, this metric has no labels to + keep cardinality low. + """ + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + metric_name: { + description: "The name of the metric whose tag value limit was exceeded. Only present when `internal_metrics.include_extended_tags` is enabled." + required: false + } + tag_key: { + description: "The key of the tag whose value limit was exceeded. Only present when `internal_metrics.include_extended_tags` is enabled." + required: false + } + } + unit: "event" + } + transform_buffer_max_byte_size: { + description: "The maximum number of bytes the buffer that feeds into a transform can hold." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "byte" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`transform_buffer_max_size_bytes`](#transform_buffer_max_size_bytes)." + } + transform_buffer_max_event_size: { + description: "The maximum number of events the buffer that feeds into a transform can hold." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "event" + deprecated: true + deprecated_message: "This metric has been deprecated in favor of [`transform_buffer_max_size_events`](#transform_buffer_max_size_events)." + } + transform_buffer_max_size_bytes: { + description: "The maximum number of bytes the buffer that feeds into a transform can hold." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "byte" + } + transform_buffer_max_size_events: { + description: "The maximum number of events the buffer that feeds into a transform can hold." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "event" + } + transform_buffer_utilization: { + description: "The utilization level of the buffer that feeds into a transform." + type: "histogram" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + transform_buffer_utilization_level: { + description: "The current utilization level of the buffer that feeds into a transform." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + transform_buffer_utilization_mean: { + description: "The mean utilization level of the buffer that feeds into a transform. This value is smoothed over time using an exponentially weighted moving average (EWMA)." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + output: { + description: "The specific output of the component." + required: false + } + } + unit: "fraction" + } + uptime_seconds: { + description: "The total number of seconds the Vector instance has been up." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "second" + } + utf8_convert_errors_total: { + description: "The total number of errors converting bytes to a UTF-8 string in UDP mode." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + mode: { + description: "The connection mode used by the component." + required: true + enum: udp: "User Datagram Protocol" + } + } + unit: "error" + } + utilization: { + description: "A ratio from 0 to 1 of the load on a component. A value of 0 would indicate a completely idle component that is simply waiting for input. A value of 1 would indicate a that is never idle. This value is updated every 5 seconds." + type: "gauge" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "fraction" + } + value_limit_reached_total: { + description: """ + The total number of times new values for a key have been rejected because the + value limit has been reached. + """ + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "occurrence" + } + websocket_bytes_sent_total: { + description: "The total number of bytes sent over WebSocket connections." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "byte" + } + websocket_messages_sent_total: { + description: "The total number of messages sent over WebSocket connections." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + component_kind: { + description: "The Vector component kind." + required: true + enum: { + sink: "Vector sink components" + source: "Vector source components" + transform: "Vector transform components" + } + } + component_id: { + description: "The Vector component ID." + required: true + examples: ["my_source", "my_sink"] + } + component_type: { + description: "The Vector component type." + required: true + examples: ["file", "http", "honeycomb", "splunk_hec"] + } + } + unit: "message" + } + windows_service_install_total: { + description: "The total number of times the Windows service has been installed." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + windows_service_restart_total: { + description: "The total number of times the Windows service has been restarted." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + windows_service_start_total: { + description: "The total number of times the Windows service has been started." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + windows_service_stop_total: { + description: "The total number of times the Windows service has been stopped." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } + windows_service_uninstall_total: { + description: "The total number of times the Windows service has been uninstalled." + type: "counter" + default_namespace: "vector" + tags: { + pid: { + description: "The process ID of the Vector instance." + required: false + examples: [ + "4232", + ] + } + host: { + description: "The hostname of the system Vector is running on." + required: false + examples: ["my-host.local"] + } + } + unit: "occurrence" + } +}