From e6d55cf0996a676418bb9066a3d426e17bba4641 Mon Sep 17 00:00:00 2001 From: Pavlos Rontidis Date: Tue, 17 Jun 2025 10:28:37 -0400 Subject: [PATCH 1/4] external(docs): mention that encoding config can change what telemetry types are supported --- src/codecs/encoding/config.rs | 3 ++- website/cue/reference/components.cue | 7 ++++--- website/cue/reference/components/sinks/base/amqp.cue | 8 ++++++-- .../components/sinks/base/aws_cloudwatch_logs.cue | 8 ++++++-- .../components/sinks/base/aws_kinesis_firehose.cue | 8 ++++++-- .../components/sinks/base/aws_kinesis_streams.cue | 8 ++++++-- website/cue/reference/components/sinks/base/aws_s3.cue | 8 ++++++-- website/cue/reference/components/sinks/base/aws_sns.cue | 8 ++++++-- website/cue/reference/components/sinks/base/aws_sqs.cue | 8 ++++++-- .../cue/reference/components/sinks/base/azure_blob.cue | 8 ++++++-- website/cue/reference/components/sinks/base/console.cue | 8 ++++++-- website/cue/reference/components/sinks/base/file.cue | 8 ++++++-- .../components/sinks/base/gcp_chronicle_unstructured.cue | 8 ++++++-- .../reference/components/sinks/base/gcp_cloud_storage.cue | 8 ++++++-- .../cue/reference/components/sinks/base/gcp_pubsub.cue | 8 ++++++-- website/cue/reference/components/sinks/base/http.cue | 8 ++++++-- .../cue/reference/components/sinks/base/humio_logs.cue | 8 ++++++-- website/cue/reference/components/sinks/base/kafka.cue | 8 ++++++-- website/cue/reference/components/sinks/base/loki.cue | 8 ++++++-- website/cue/reference/components/sinks/base/mqtt.cue | 8 ++++++-- website/cue/reference/components/sinks/base/nats.cue | 8 ++++++-- .../cue/reference/components/sinks/base/opentelemetry.cue | 8 ++++++-- .../cue/reference/components/sinks/base/papertrail.cue | 8 ++++++-- website/cue/reference/components/sinks/base/pulsar.cue | 8 ++++++-- website/cue/reference/components/sinks/base/redis.cue | 8 ++++++-- website/cue/reference/components/sinks/base/socket.cue | 8 ++++++-- .../reference/components/sinks/base/splunk_hec_logs.cue | 8 ++++++-- website/cue/reference/components/sinks/base/webhdfs.cue | 8 ++++++-- website/cue/reference/components/sinks/base/websocket.cue | 8 ++++++-- .../reference/components/sinks/base/websocket_server.cue | 8 ++++++-- .../cue/reference/components/sinks/websocket_server.cue | 4 ++++ website/layouts/docs/component.html | 6 +++--- website/layouts/partials/data.html | 2 +- 33 files changed, 182 insertions(+), 64 deletions(-) diff --git a/src/codecs/encoding/config.rs b/src/codecs/encoding/config.rs index b11fe751a7462..c3d77a5abde2c 100644 --- a/src/codecs/encoding/config.rs +++ b/src/codecs/encoding/config.rs @@ -8,7 +8,8 @@ use vector_lib::configurable::configurable_component; /// Encoding configuration. #[configurable_component] #[derive(Clone, Debug)] -#[configurable(description = "Configures how events are encoded into raw bytes.")] +/// Configures how events are encoded into raw bytes. +/// The selected encoding also determines which input types (logs, metrics, traces) are supported. pub struct EncodingConfig { #[serde(flatten)] encoding: SerializerConfig, diff --git a/website/cue/reference/components.cue b/website/cue/reference/components.cue index a43b0f61f18e3..05a437fe86caa 100644 --- a/website/cue/reference/components.cue +++ b/website/cue/reference/components.cue @@ -439,9 +439,10 @@ components: { } #Input: { - logs: bool - metrics: #MetricInput | null - traces: bool + description?: string + logs: bool + metrics: #MetricInput | null + traces: bool } #LogOutput: [Name=string]: { diff --git a/website/cue/reference/components/sinks/base/amqp.cue b/website/cue/reference/components/sinks/base/amqp.cue index 016cfa8404b0b..0f8c24162cb97 100644 --- a/website/cue/reference/components/sinks/base/amqp.cue +++ b/website/cue/reference/components/sinks/base/amqp.cue @@ -44,8 +44,12 @@ base: components: sinks: amqp: configuration: { type: string: examples: ["amqp://user:password@127.0.0.1:5672/%2f?timeout=10"] } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_cloudwatch_logs.cue b/website/cue/reference/components/sinks/base/aws_cloudwatch_logs.cue index 7eda53f14b84c..a4ca1de78da7a 100644 --- a/website/cue/reference/components/sinks/base/aws_cloudwatch_logs.cue +++ b/website/cue/reference/components/sinks/base/aws_cloudwatch_logs.cue @@ -240,8 +240,12 @@ base: components: sinks: aws_cloudwatch_logs: configuration: { type: bool: default: true } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_kinesis_firehose.cue b/website/cue/reference/components/sinks/base/aws_kinesis_firehose.cue index 0f2d80d4e8390..301ba0b2a539c 100644 --- a/website/cue/reference/components/sinks/base/aws_kinesis_firehose.cue +++ b/website/cue/reference/components/sinks/base/aws_kinesis_firehose.cue @@ -219,8 +219,12 @@ base: components: sinks: aws_kinesis_firehose: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_kinesis_streams.cue b/website/cue/reference/components/sinks/base/aws_kinesis_streams.cue index 6028c01ba4241..09b182fd89994 100644 --- a/website/cue/reference/components/sinks/base/aws_kinesis_streams.cue +++ b/website/cue/reference/components/sinks/base/aws_kinesis_streams.cue @@ -219,8 +219,12 @@ base: components: sinks: aws_kinesis_streams: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_s3.cue b/website/cue/reference/components/sinks/base/aws_s3.cue index 5654d6ac48727..6345607788038 100644 --- a/website/cue/reference/components/sinks/base/aws_s3.cue +++ b/website/cue/reference/components/sinks/base/aws_s3.cue @@ -328,8 +328,12 @@ base: components: sinks: aws_s3: configuration: { type: string: examples: ["application/gzip"] } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_sns.cue b/website/cue/reference/components/sinks/base/aws_sns.cue index 8d183c33d9b04..107cfc7a8a7d8 100644 --- a/website/cue/reference/components/sinks/base/aws_sns.cue +++ b/website/cue/reference/components/sinks/base/aws_sns.cue @@ -150,8 +150,12 @@ base: components: sinks: aws_sns: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/aws_sqs.cue b/website/cue/reference/components/sinks/base/aws_sqs.cue index 0493d2ede171f..b8a0ee23ccc10 100644 --- a/website/cue/reference/components/sinks/base/aws_sqs.cue +++ b/website/cue/reference/components/sinks/base/aws_sqs.cue @@ -150,8 +150,12 @@ base: components: sinks: aws_sqs: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/azure_blob.cue b/website/cue/reference/components/sinks/base/azure_blob.cue index 0bd8b0f494979..5fd082eed789c 100644 --- a/website/cue/reference/components/sinks/base/azure_blob.cue +++ b/website/cue/reference/components/sinks/base/azure_blob.cue @@ -176,8 +176,12 @@ base: components: sinks: azure_blob: configuration: { type: string: examples: ["my-logs"] } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/console.cue b/website/cue/reference/components/sinks/base/console.cue index a140bedf2b276..acd35724c8d26 100644 --- a/website/cue/reference/components/sinks/base/console.cue +++ b/website/cue/reference/components/sinks/base/console.cue @@ -28,8 +28,12 @@ base: components: sinks: console: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/file.cue b/website/cue/reference/components/sinks/base/file.cue index 0cf8178fdae08..bcd793427b2f4 100644 --- a/website/cue/reference/components/sinks/base/file.cue +++ b/website/cue/reference/components/sinks/base/file.cue @@ -48,8 +48,12 @@ base: components: sinks: file: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/gcp_chronicle_unstructured.cue b/website/cue/reference/components/sinks/base/gcp_chronicle_unstructured.cue index 1b9edc8daea52..57a747fd21cb8 100644 --- a/website/cue/reference/components/sinks/base/gcp_chronicle_unstructured.cue +++ b/website/cue/reference/components/sinks/base/gcp_chronicle_unstructured.cue @@ -116,8 +116,12 @@ base: components: sinks: gcp_chronicle_unstructured: configuration: { type: string: examples: ["c8c65bfa-5f2c-42d4-9189-64bb7b939f2c"] } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/gcp_cloud_storage.cue b/website/cue/reference/components/sinks/base/gcp_cloud_storage.cue index 45e175ee58aee..0a0b423693bef 100644 --- a/website/cue/reference/components/sinks/base/gcp_cloud_storage.cue +++ b/website/cue/reference/components/sinks/base/gcp_cloud_storage.cue @@ -189,8 +189,12 @@ base: components: sinks: gcp_cloud_storage: configuration: { type: string: {} } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/gcp_pubsub.cue b/website/cue/reference/components/sinks/base/gcp_pubsub.cue index 17e23079783ae..5db694873ebce 100644 --- a/website/cue/reference/components/sinks/base/gcp_pubsub.cue +++ b/website/cue/reference/components/sinks/base/gcp_pubsub.cue @@ -95,8 +95,12 @@ base: components: sinks: gcp_pubsub: configuration: { type: string: {} } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/http.cue b/website/cue/reference/components/sinks/base/http.cue index 286cf7dd842fb..0632ba766fa5e 100644 --- a/website/cue/reference/components/sinks/base/http.cue +++ b/website/cue/reference/components/sinks/base/http.cue @@ -271,8 +271,12 @@ base: components: sinks: http: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/humio_logs.cue b/website/cue/reference/components/sinks/base/humio_logs.cue index 153dfa5324fdc..546a244d84959 100644 --- a/website/cue/reference/components/sinks/base/humio_logs.cue +++ b/website/cue/reference/components/sinks/base/humio_logs.cue @@ -94,8 +94,12 @@ base: components: sinks: humio_logs: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/kafka.cue b/website/cue/reference/components/sinks/base/kafka.cue index f4ec89ef30d8c..97fecdbb2d2d3 100644 --- a/website/cue/reference/components/sinks/base/kafka.cue +++ b/website/cue/reference/components/sinks/base/kafka.cue @@ -83,8 +83,12 @@ base: components: sinks: kafka: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/loki.cue b/website/cue/reference/components/sinks/base/loki.cue index 218aed6a861fb..4dc8d00fcf13f 100644 --- a/website/cue/reference/components/sinks/base/loki.cue +++ b/website/cue/reference/components/sinks/base/loki.cue @@ -273,8 +273,12 @@ base: components: sinks: loki: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/mqtt.cue b/website/cue/reference/components/sinks/base/mqtt.cue index 12bed930db3c8..c8f4ed9bd1fed 100644 --- a/website/cue/reference/components/sinks/base/mqtt.cue +++ b/website/cue/reference/components/sinks/base/mqtt.cue @@ -38,8 +38,12 @@ base: components: sinks: mqtt: configuration: { type: string: {} } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/nats.cue b/website/cue/reference/components/sinks/base/nats.cue index d663a69f666af..8cf579f6a2e3b 100644 --- a/website/cue/reference/components/sinks/base/nats.cue +++ b/website/cue/reference/components/sinks/base/nats.cue @@ -128,8 +128,12 @@ base: components: sinks: nats: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/opentelemetry.cue b/website/cue/reference/components/sinks/base/opentelemetry.cue index 0f9d2a62585c1..63570c903ab10 100644 --- a/website/cue/reference/components/sinks/base/opentelemetry.cue +++ b/website/cue/reference/components/sinks/base/opentelemetry.cue @@ -274,8 +274,12 @@ base: components: sinks: opentelemetry: configuration: protocol: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/papertrail.cue b/website/cue/reference/components/sinks/base/papertrail.cue index de4bb6b34ba28..b20c940cad1f5 100644 --- a/website/cue/reference/components/sinks/base/papertrail.cue +++ b/website/cue/reference/components/sinks/base/papertrail.cue @@ -28,8 +28,12 @@ base: components: sinks: papertrail: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/pulsar.cue b/website/cue/reference/components/sinks/base/pulsar.cue index b24d5bce94de6..b423fa09c6f73 100644 --- a/website/cue/reference/components/sinks/base/pulsar.cue +++ b/website/cue/reference/components/sinks/base/pulsar.cue @@ -162,8 +162,12 @@ base: components: sinks: pulsar: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/redis.cue b/website/cue/reference/components/sinks/base/redis.cue index e93567ba823fd..9c0b95a42c0a1 100644 --- a/website/cue/reference/components/sinks/base/redis.cue +++ b/website/cue/reference/components/sinks/base/redis.cue @@ -81,8 +81,12 @@ base: components: sinks: redis: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/socket.cue b/website/cue/reference/components/sinks/base/socket.cue index 76e1365789869..cb6aac0fd9fae 100644 --- a/website/cue/reference/components/sinks/base/socket.cue +++ b/website/cue/reference/components/sinks/base/socket.cue @@ -40,8 +40,12 @@ base: components: sinks: socket: configuration: { type: string: examples: ["92.12.333.224:5000", "https://somehost:5000"] } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/splunk_hec_logs.cue b/website/cue/reference/components/sinks/base/splunk_hec_logs.cue index 0c8187c067592..48d07e78b8024 100644 --- a/website/cue/reference/components/sinks/base/splunk_hec_logs.cue +++ b/website/cue/reference/components/sinks/base/splunk_hec_logs.cue @@ -144,8 +144,12 @@ base: components: sinks: splunk_hec_logs: configuration: { type: string: {} } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/webhdfs.cue b/website/cue/reference/components/sinks/base/webhdfs.cue index a011bc24262e5..ca14f7bd07878 100644 --- a/website/cue/reference/components/sinks/base/webhdfs.cue +++ b/website/cue/reference/components/sinks/base/webhdfs.cue @@ -94,8 +94,12 @@ base: components: sinks: webhdfs: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/websocket.cue b/website/cue/reference/components/sinks/base/websocket.cue index d6cadf59f1fbc..0694c649db191 100644 --- a/website/cue/reference/components/sinks/base/websocket.cue +++ b/website/cue/reference/components/sinks/base/websocket.cue @@ -205,8 +205,12 @@ base: components: sinks: websocket: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/base/websocket_server.cue b/website/cue/reference/components/sinks/base/websocket_server.cue index 94c4ce577834c..ada3da7debe2e 100644 --- a/website/cue/reference/components/sinks/base/websocket_server.cue +++ b/website/cue/reference/components/sinks/base/websocket_server.cue @@ -84,8 +84,12 @@ base: components: sinks: websocket_server: configuration: { } } encoding: { - description: "Configures how events are encoded into raw bytes." - required: true + description: """ + Encoding configuration. + Configures how events are encoded into raw bytes. + The selected encoding also determines which input types (logs, metrics, traces) are supported. + """ + required: true type: object: options: { avro: { description: "Apache Avro-specific encoder options." diff --git a/website/cue/reference/components/sinks/websocket_server.cue b/website/cue/reference/components/sinks/websocket_server.cue index 1a76c607aa7ed..31c9d4af42d1d 100644 --- a/website/cue/reference/components/sinks/websocket_server.cue +++ b/website/cue/reference/components/sinks/websocket_server.cue @@ -66,6 +66,10 @@ components: sinks: websocket_server: { } input: { + description: """ + The supported input types depend on the encoding configuration. + This sink accepts any input type supported by the specified encoder. + """ logs: true metrics: { counter: true diff --git a/website/layouts/docs/component.html b/website/layouts/docs/component.html index 93f3e34d66095..7b55180d47a3d 100644 --- a/website/layouts/docs/component.html +++ b/website/layouts/docs/component.html @@ -21,7 +21,7 @@ {{ partial "breadcrumb.html" . }} - +

{{ .Title | markdownify }}

@@ -86,10 +86,10 @@

{{ with .metrics }} From 4ada77d6192812e9ce07e39db003d99ed27fe218 Mon Sep 17 00:00:00 2001 From: Pavlos Rontidis Date: Tue, 17 Jun 2025 12:47:38 -0400 Subject: [PATCH 2/4] feat(website): add input telemetry types section --- website/layouts/docs/component.html | 8 ++- website/layouts/partials/data.html | 13 ++-- website/layouts/partials/telemetry_input.html | 59 +++++++++++++++++++ .../{telemetry.html => telemetry_output.html} | 2 +- 4 files changed, 76 insertions(+), 6 deletions(-) create mode 100644 website/layouts/partials/telemetry_input.html rename website/layouts/partials/{telemetry.html => telemetry_output.html} (97%) diff --git a/website/layouts/docs/component.html b/website/layouts/docs/component.html index 7b55180d47a3d..6c08b5e0e4e4c 100644 --- a/website/layouts/docs/component.html +++ b/website/layouts/docs/component.html @@ -66,7 +66,7 @@

{{ end }} + {{/* Source/transform/sink input */}} + {{ with .component_input_types }} + {{ template "telemetry_input" . }} + {{ end }} + {{/* Source/transform/sink output */}} {{ with .component_output_types }}
@@ -274,7 +279,7 @@
- {{ template "telemetry" . }} + {{ template "telemetry_output" . }}
{{ end }} @@ -284,7 +289,7 @@
- {{ template "telemetry" . }} + {{ template "telemetry_output" . }}
{{ end }} @@ -447,7 +452,7 @@
- {{ template "telemetry" . }} + {{ template "telemetry_output" . }}
{{ end }} @@ -460,7 +465,7 @@
- {{ template "telemetry" . }} + {{ template "telemetry_output" . }}
{{ end }} diff --git a/website/layouts/partials/telemetry_input.html b/website/layouts/partials/telemetry_input.html new file mode 100644 index 0000000000000..e4d952acc79fc --- /dev/null +++ b/website/layouts/partials/telemetry_input.html @@ -0,0 +1,59 @@ +{{ define "telemetry_input" }} +
+
+ {{ with .description }} + {{ . | markdownify }} + {{ else }} + The following section shows which telemetry data types are supported. + {{ end }} +
+ + {{ if .logs }} +
+ + {{ partial "heading.html" (dict "text" "Logs" "level" 3 "id" "input-logs" "href" "#input-logs") }} + + +
Log events are supported.
+
+ {{ end }} + + {{ with .metrics }} + {{ $has := slice }} + {{ range $k, $v := . }} + {{ if $v }} + {{ $has = $has | append $k }} + {{ end }} + {{ end }} + + {{ if gt (len $has) 0 }} +
+ + {{ partial "heading.html" (dict "text" "Metrics" "level" 3 "id" "input-metrics" "href" "#input-metrics") }} + + +
+
+ {{ range $has }} + + {{ . }} + + {{ end }} +
+
+
+ {{ end }} + {{ end }} + + {{ if .traces }} +
+ + {{ partial "heading.html" (dict "text" "Traces" "level" 3 "id" "input-traces" "href" "#input-traces") }} + + +
Trace events are supported.
+
+ {{ end }} + +
+{{ end }} diff --git a/website/layouts/partials/telemetry.html b/website/layouts/partials/telemetry_output.html similarity index 97% rename from website/layouts/partials/telemetry.html rename to website/layouts/partials/telemetry_output.html index 74940d29ecedd..bb5875786e1c7 100644 --- a/website/layouts/partials/telemetry.html +++ b/website/layouts/partials/telemetry_output.html @@ -1,4 +1,4 @@ -{{ define "telemetry" }} +{{ define "telemetry_output" }} {{ range $k, $v := . }}
From 50effff3bb2889bf08ae1a489b0d54a8feab30cc Mon Sep 17 00:00:00 2001 From: Pavlos Rontidis Date: Tue, 17 Jun 2025 14:02:32 -0400 Subject: [PATCH 3/4] remove weird char --- website/layouts/docs/component.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/layouts/docs/component.html b/website/layouts/docs/component.html index 6c08b5e0e4e4c..9c52d2f2fdf56 100644 --- a/website/layouts/docs/component.html +++ b/website/layouts/docs/component.html @@ -66,7 +66,7 @@

Date: Tue, 17 Jun 2025 14:10:39 -0400 Subject: [PATCH 4/4] visual improvements --- website/layouts/partials/telemetry_input.html | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/website/layouts/partials/telemetry_input.html b/website/layouts/partials/telemetry_input.html index e4d952acc79fc..3d675b09c844f 100644 --- a/website/layouts/partials/telemetry_input.html +++ b/website/layouts/partials/telemetry_input.html @@ -1,6 +1,6 @@ {{ define "telemetry_input" }} -
-
+
+
{{ with .description }} {{ . | markdownify }} {{ else }} @@ -9,11 +9,10 @@
{{ if .logs }} -
+
{{ partial "heading.html" (dict "text" "Logs" "level" 3 "id" "input-logs" "href" "#input-logs") }} -
Log events are supported.
{{ end }} @@ -25,14 +24,15 @@ {{ $has = $has | append $k }} {{ end }} {{ end }} - {{ if gt (len $has) 0 }} -
+
{{ partial "heading.html" (dict "text" "Metrics" "level" 3 "id" "input-metrics" "href" "#input-metrics") }} -
+
The following metrics are supported:
+ +
{{ range $has }} @@ -46,11 +46,10 @@ {{ end }} {{ if .traces }} -
+
{{ partial "heading.html" (dict "text" "Traces" "level" 3 "id" "input-traces" "href" "#input-traces") }} -
Trace events are supported.
{{ end }}