Skip to content

Commit

Permalink
chore: add a json parse step
Browse files Browse the repository at this point in the history
  • Loading branch information
sunng87 committed Nov 8, 2024
1 parent 8889702 commit fb7a89d
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
9 changes: 8 additions & 1 deletion docs/greptimecloud/integrations/vector.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,15 @@ tls = {}
type = "demo_logs"
format = "json"

[sinks.logs_out]
[transforms.logs_json]
type = "remap"
inputs = ["logs_in"]
source = '''
. = parse_json!(.message)
'''

[sinks.logs_out]
inputs = ["logs_json"]
type = "greptimedb_logs"
endpoint = "https://<host>"
compression = "gzip"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,15 @@ tls = {}
type = "demo_logs"
format = "json"

[sinks.logs_out]
[transforms.logs_json]
type = "remap"
inputs = ["logs_in"]
source = '''
. = parse_json!(.message)
'''

[sinks.logs_out]
inputs = ["logs_json"]
type = "greptimedb_logs"
endpoint = "https://<host>"
compression = "gzip"
Expand Down

0 comments on commit fb7a89d

Please sign in to comment.