From d4dd55ccc6b3dc9d33accadf332d30cd9141194a Mon Sep 17 00:00:00 2001 From: chaitanya-sistla Date: Wed, 16 Oct 2024 23:11:19 -0500 Subject: [PATCH 1/4] adding openobserve as a sink connector --- Cargo.toml | 1 + .../components/sinks/base/openobserve.cue | 61 +++++++++++++++++++ .../components/sinks/openobserve.cue | 60 ++++++++++++++++++ 3 files changed, 122 insertions(+) create mode 100644 website/cue/reference/components/sinks/base/openobserve.cue create mode 100644 website/cue/reference/components/sinks/openobserve.cue diff --git a/Cargo.toml b/Cargo.toml index 4a8aa0b71e948..9037e8d0a4cbf 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -708,6 +708,7 @@ sinks-logs = [ "sinks-new_relic", "sinks-papertrail", "sinks-pulsar", + "sinks-openobserve", "sinks-redis", "sinks-sematext", "sinks-socket", diff --git a/website/cue/reference/components/sinks/base/openobserve.cue b/website/cue/reference/components/sinks/base/openobserve.cue new file mode 100644 index 0000000000000..8448649028c72 --- /dev/null +++ b/website/cue/reference/components/sinks/base/openobserve.cue @@ -0,0 +1,61 @@ +package metadata + +base: components: sinks: openobserve: configuration: { + type: "http" + inputs: ["source_or_transform_id"] + uri: { + description: "The OpenObserve endpoint to send data to." + required: true + type: string: examples: ["http://localhost:5080/api/default/default/_json"] + } + method: { + description: "The HTTP method to use for the request." + required: true + type: string: default: "post" + } + auth: { + description: "Authentication for OpenObserve." + required: true + type: object: options: { + strategy: { + description: "The authentication strategy." + required: true + type: string: default: "basic" + } + user: { + description: "The username for basic authentication." + required: true + type: string: examples: ["test@example.com"] + } + password: { + description: "The password for basic authentication." + required: true + type: string: examples: ["v9Ca7qHaMKELlDtU"] + } + } + } + compression: { + description: "The compression algorithm to use." + required: true + type: string: default: "gzip" + } + encoding: { + codec: { + description: "The encoding format to use for the request body." + required: true + type: string: default: "json" + } + timestamp_format: { + description: "The format for encoding timestamps." + required: true + type: string: default: "rfc3339" + } + } + healthcheck: { + enabled: { + description: "Enables or disables the health check." + required: true + type: bool: default: false + } + } +} diff --git a/website/cue/reference/components/sinks/openobserve.cue b/website/cue/reference/components/sinks/openobserve.cue new file mode 100644 index 0000000000000..ac8a74c816e9c --- /dev/null +++ b/website/cue/reference/components/sinks/openobserve.cue @@ -0,0 +1,60 @@ +package metadata + +components: sinks: openobserve: { + title: "OpenObserve" + + features: { + healthcheck: { + enabled: false + } + send: { + compression: { + enabled: true + default: "gzip" + } + encoding: { + enabled: true + codec: { + enabled: true + default: "json" + } + timestamp_format: { + enabled: true + default: "rfc3339" + } + } + } + } + + configuration: { + type: "http" + inputs: ["source_or_transform_id"] + uri: { + description: "The OpenObserve endpoint to send data to." + required: true + type: string: default: "http://localhost:5080/api/default/default/_json" + } + method: { + description: "The HTTP method to use." + required: true + type: string: default: "post" + } + auth: { + strategy: { + description: "The authentication strategy." + required: true + type: string: default: "basic" + } + user: { + description: "The username for basic authentication." + required: true + type: string: default: "test@example.com" + } + password: { + description: "The password for basic authentication." + required: true + type: string: default: "your_ingestion_password" + } + } + } +} From a48bb53a5ff62e282033b5d8e7c571bdc1365eae Mon Sep 17 00:00:00 2001 From: chaitanya-sistla Date: Wed, 16 Oct 2024 23:18:54 -0500 Subject: [PATCH 2/4] adding placeholder instead of fake password --- website/cue/reference/components/sinks/base/openobserve.cue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/cue/reference/components/sinks/base/openobserve.cue b/website/cue/reference/components/sinks/base/openobserve.cue index 8448649028c72..2c09346d1f7cd 100644 --- a/website/cue/reference/components/sinks/base/openobserve.cue +++ b/website/cue/reference/components/sinks/base/openobserve.cue @@ -30,7 +30,7 @@ base: components: sinks: openobserve: configuration: { password: { description: "The password for basic authentication." required: true - type: string: examples: ["v9Ca7qHaMKELlDtU"] + type: string: examples: ["your_ingestion_password"] } } } From c6030f16a9ef1fa14720fe7be2bbe746e4a99703 Mon Sep 17 00:00:00 2001 From: chaitanya-sistla Date: Wed, 16 Oct 2024 23:34:57 -0500 Subject: [PATCH 3/4] adding openobserve to allow.txt --- .github/actions/spelling/allow.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/actions/spelling/allow.txt b/.github/actions/spelling/allow.txt index 1a29bb5e02b4e..dbc3a80746c08 100644 --- a/.github/actions/spelling/allow.txt +++ b/.github/actions/spelling/allow.txt @@ -142,6 +142,7 @@ Nextbook Nextcloud OVH Odys +Openobserve Openpeak Oppo Ovi From e9bd1fed8e717580bad6d8c4787ea714463f4053 Mon Sep 17 00:00:00 2001 From: chaitanya-sistla Date: Fri, 18 Oct 2024 09:07:06 -0500 Subject: [PATCH 4/4] adding openobserve to allow.txt --- .github/actions/spelling/allow.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/spelling/allow.txt b/.github/actions/spelling/allow.txt index dbc3a80746c08..b8cf8e8268509 100644 --- a/.github/actions/spelling/allow.txt +++ b/.github/actions/spelling/allow.txt @@ -142,7 +142,7 @@ Nextbook Nextcloud OVH Odys -Openobserve +openobserve Openpeak Oppo Ovi