From e7e3983d3c5fe7305bcf367e516639e08cb06d8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Barroso?= Date: Mon, 11 Mar 2024 15:31:08 +0100 Subject: [PATCH] chore: update specs (#1428) OpenCDC page will be published via this PR https://github.com/ConduitIO/conduit-site/pull/49 --- pkg/plugin/processor/builtin/impl/unwrap/debezium.go | 5 +++-- pkg/plugin/processor/builtin/impl/unwrap/kafka_connect.go | 6 +++--- .../builtin/impl/unwrap/kafka_connect_examples_test.go | 2 +- pkg/plugin/processor/builtin/impl/unwrap/opencdc.go | 6 +++--- .../builtin/impl/unwrap/opencdc_examples_test.go | 4 ++-- .../internal/exampleutil/specs/unwrap.debezium.json | 4 ++-- .../internal/exampleutil/specs/unwrap.kafkaconnect.json | 6 +++--- .../internal/exampleutil/specs/unwrap.opencdc.json | 8 ++++---- 8 files changed, 21 insertions(+), 20 deletions(-) diff --git a/pkg/plugin/processor/builtin/impl/unwrap/debezium.go b/pkg/plugin/processor/builtin/impl/unwrap/debezium.go index 810949f9d..46f97ddad 100644 --- a/pkg/plugin/processor/builtin/impl/unwrap/debezium.go +++ b/pkg/plugin/processor/builtin/impl/unwrap/debezium.go @@ -64,14 +64,15 @@ func NewDebeziumProcessor(logger log.CtxLogger) sdk.Processor { func (d *debeziumProcessor) Specification() (sdk.Specification, error) { return sdk.Specification{ Name: "unwrap.debezium", - Summary: "Unwraps a Debezium record from the input OpenCDC record.", + Summary: "Unwraps a Debezium record from the input [OpenCDC record](https://conduit.io/docs/features/opencdc-record).", Description: `In this processor, the wrapped (Debezium) record replaces the wrapping record (being processed) completely, except for the position. The Debezium record's metadata and the wrapping record's metadata is merged, with the Debezium metadata having precedence. This is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. -In such cases, the Debezium record is set as the OpenCDC record's payload, and needs to be unwrapped for further usage.`, +In such cases, the Debezium record is set as the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload,` + + `and needs to be unwrapped for further usage.`, Version: "v0.1.0", Author: "Meroxa, Inc.", Parameters: debeziumConfig{}.Parameters(), diff --git a/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect.go b/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect.go index d32bf5f1f..51a0c3ef3 100644 --- a/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect.go +++ b/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect.go @@ -46,13 +46,13 @@ func NewKafkaConnectProcessor(log.CtxLogger) sdk.Processor { func (u *kafkaConnectProcessor) Specification() (sdk.Specification, error) { return sdk.Specification{ Name: "unwrap.kafkaconnect", - Summary: "Unwraps a Kafka Connect record from an OpenCDC record.", - Description: `This processor unwraps a Kafka Connect record from the input OpenCDC record. + Summary: "Unwraps a Kafka Connect record from an [OpenCDC record](https://conduit.io/docs/features/opencdc-record).", + Description: `This processor unwraps a Kafka Connect record from the input [OpenCDC record](https://conduit.io/docs/features/opencdc-record). The input record's payload is replaced with the Kafka Connect record. This is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. -In such cases, the Debezium record is set as the OpenCDC record's payload, and needs to be unwrapped for further usage.`, +In such cases, the Debezium record is set as the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload, and needs to be unwrapped for further usage.`, Version: "v0.1.0", Author: "Meroxa, Inc.", Parameters: kafkaConnectConfig{}.Parameters(), diff --git a/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect_examples_test.go b/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect_examples_test.go index d359ea3ab..f6819abd6 100644 --- a/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect_examples_test.go +++ b/pkg/plugin/processor/builtin/impl/unwrap/kafka_connect_examples_test.go @@ -30,7 +30,7 @@ func ExampleKafkaConnectProcesor() { Description: `This example shows how to unwrap a Kafka Connect record. The Kafka Connect record is serialized as a JSON string in the ` + "`.Payload.After`" + ` field (raw data). -The Kafka Connect record's payload will replace the OpenCDC record's payload. +The Kafka Connect record's payload will replace the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload. We also see how the key is unwrapped too. In this case, the key comes in as structured data.`, Config: map[string]string{}, diff --git a/pkg/plugin/processor/builtin/impl/unwrap/opencdc.go b/pkg/plugin/processor/builtin/impl/unwrap/opencdc.go index 5d800b5df..8ba7602d3 100644 --- a/pkg/plugin/processor/builtin/impl/unwrap/opencdc.go +++ b/pkg/plugin/processor/builtin/impl/unwrap/opencdc.go @@ -48,12 +48,12 @@ func NewOpenCDCProcessor(logger log.CtxLogger) sdk.Processor { func (u *openCDCProcessor) Specification() (sdk.Specification, error) { return sdk.Specification{ Name: "unwrap.opencdc", - Summary: "Unwraps an OpenCDC record saved in one of the record's fields.", + Summary: "Unwraps an [OpenCDC record](https://conduit.io/docs/features/opencdc-record) saved in one of the record's fields.", Description: `The ` + "`unwrap.opencdc`" + ` processor is useful in situations where a record goes through intermediate -systems before being written to a final destination. In these cases, the original OpenCDC record is part of the payload +systems before being written to a final destination. In these cases, the original [OpenCDC record](https://conduit.io/docs/features/opencdc-record) is part of the payload read from the intermediate system and needs to be unwrapped before being written. -Note: if the wrapped OpenCDC record is not in a structured data field, then it's assumed that it's stored in JSON format.`, +Note: if the wrapped [OpenCDC record](https://conduit.io/docs/features/opencdc-record) is not in a structured data field, then it's assumed that it's stored in JSON format.`, Version: "v0.1.0", Author: "Meroxa, Inc.", Parameters: openCDCConfig{}.Parameters(), diff --git a/pkg/plugin/processor/builtin/impl/unwrap/opencdc_examples_test.go b/pkg/plugin/processor/builtin/impl/unwrap/opencdc_examples_test.go index a0f9b6e78..2cebbfb4b 100644 --- a/pkg/plugin/processor/builtin/impl/unwrap/opencdc_examples_test.go +++ b/pkg/plugin/processor/builtin/impl/unwrap/opencdc_examples_test.go @@ -26,8 +26,8 @@ func ExampleOpenCDCProcessor() { p := NewOpenCDCProcessor(log.Nop()) exampleutil.RunExample(p, exampleutil.Example{ - Summary: "Unwrap an OpenCDC record", - Description: "In this example we use the `unwrap.opencdc` processor to unwrap the OpenCDC record found in the " + + Summary: "Unwrap an [OpenCDC record](https://conduit.io/docs/features/opencdc-record)", + Description: "In this example we use the `unwrap.opencdc` processor to unwrap the [OpenCDC record](https://conduit.io/docs/features/opencdc-record) found in the " + "record's `.Payload.After` field.", Config: map[string]string{}, Have: opencdc.Record{ diff --git a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.debezium.json b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.debezium.json index e564f103f..5bfc00b7b 100644 --- a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.debezium.json +++ b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.debezium.json @@ -1,8 +1,8 @@ { "specification": { "name": "unwrap.debezium", - "summary": "Unwraps a Debezium record from the input OpenCDC record.", - "description": "In this processor, the wrapped (Debezium) record replaces the wrapping record (being processed) \ncompletely, except for the position.\n\nThe Debezium record's metadata and the wrapping record's metadata is merged, with the Debezium metadata having precedence.\n\nThis is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. \nIn such cases, the Debezium record is set as the OpenCDC record's payload, and needs to be unwrapped for further usage.", + "summary": "Unwraps a Debezium record from the input [OpenCDC record](https://conduit.io/docs/features/opencdc-record).", + "description": "In this processor, the wrapped (Debezium) record replaces the wrapping record (being processed) \ncompletely, except for the position.\n\nThe Debezium record's metadata and the wrapping record's metadata is merged, with the Debezium metadata having precedence.\n\nThis is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. \nIn such cases, the Debezium record is set as the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload,and needs to be unwrapped for further usage.", "version": "v0.1.0", "author": "Meroxa, Inc.", "parameters": { diff --git a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.kafkaconnect.json b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.kafkaconnect.json index 38c84d273..913c66716 100644 --- a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.kafkaconnect.json +++ b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.kafkaconnect.json @@ -1,8 +1,8 @@ { "specification": { "name": "unwrap.kafkaconnect", - "summary": "Unwraps a Kafka Connect record from an OpenCDC record.", - "description": "This processor unwraps a Kafka Connect record from the input OpenCDC record.\n\nThe input record's payload is replaced with the Kafka Connect record.\n\nThis is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. \nIn such cases, the Debezium record is set as the OpenCDC record's payload, and needs to be unwrapped for further usage.", + "summary": "Unwraps a Kafka Connect record from an [OpenCDC record](https://conduit.io/docs/features/opencdc-record).", + "description": "This processor unwraps a Kafka Connect record from the input [OpenCDC record](https://conduit.io/docs/features/opencdc-record).\n\nThe input record's payload is replaced with the Kafka Connect record.\n\nThis is useful in cases where Conduit acts as an intermediary between a Debezium source and a Debezium destination. \nIn such cases, the Debezium record is set as the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload, and needs to be unwrapped for further usage.", "version": "v0.1.0", "author": "Meroxa, Inc.", "parameters": { @@ -22,7 +22,7 @@ "examples": [ { "summary": "Unwrap a Kafka Connect record", - "description": "This example shows how to unwrap a Kafka Connect record.\n\nThe Kafka Connect record is serialized as a JSON string in the `.Payload.After` field (raw data).\nThe Kafka Connect record's payload will replace the OpenCDC record's payload.\n\nWe also see how the key is unwrapped too. In this case, the key comes in as structured data.", + "description": "This example shows how to unwrap a Kafka Connect record.\n\nThe Kafka Connect record is serialized as a JSON string in the `.Payload.After` field (raw data).\nThe Kafka Connect record's payload will replace the [OpenCDC record](https://conduit.io/docs/features/opencdc-record)'s payload.\n\nWe also see how the key is unwrapped too. In this case, the key comes in as structured data.", "config": { "field": ".Payload.After" }, diff --git a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.opencdc.json b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.opencdc.json index 4a1667b29..8aa00de6e 100644 --- a/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.opencdc.json +++ b/pkg/plugin/processor/builtin/internal/exampleutil/specs/unwrap.opencdc.json @@ -1,8 +1,8 @@ { "specification": { "name": "unwrap.opencdc", - "summary": "Unwraps an OpenCDC record saved in one of the record's fields.", - "description": "The `unwrap.opencdc` processor is useful in situations where a record goes through intermediate\nsystems before being written to a final destination. In these cases, the original OpenCDC record is part of the payload\nread from the intermediate system and needs to be unwrapped before being written.\n\nNote: if the wrapped OpenCDC record is not in a structured data field, then it's assumed that it's stored in JSON format.", + "summary": "Unwraps an [OpenCDC record](https://conduit.io/docs/features/opencdc-record) saved in one of the record's fields.", + "description": "The `unwrap.opencdc` processor is useful in situations where a record goes through intermediate\nsystems before being written to a final destination. In these cases, the original [OpenCDC record](https://conduit.io/docs/features/opencdc-record) is part of the payload\nread from the intermediate system and needs to be unwrapped before being written.\n\nNote: if the wrapped [OpenCDC record](https://conduit.io/docs/features/opencdc-record) is not in a structured data field, then it's assumed that it's stored in JSON format.", "version": "v0.1.0", "author": "Meroxa, Inc.", "parameters": { @@ -16,8 +16,8 @@ }, "examples": [ { - "summary": "Unwrap an OpenCDC record", - "description": "In this example we use the `unwrap.opencdc` processor to unwrap the OpenCDC record found in the record's `.Payload.After` field.", + "summary": "Unwrap an [OpenCDC record](https://conduit.io/docs/features/opencdc-record)", + "description": "In this example we use the `unwrap.opencdc` processor to unwrap the [OpenCDC record](https://conduit.io/docs/features/opencdc-record) found in the record's `.Payload.After` field.", "config": { "field": ".Payload.After" },