Dynamic index - ElasticSearch #9147
Unanswered
ashish-gpt
asked this question in
Q&A
Replies: 1 comment 2 replies
-
The Opensearch output supports using record-accessor syntax in the index: https://docs.fluentbit.io/manual/pipeline/outputs/opensearch |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
data.json
{"transactionId":"4321","transactionType":"Cards","request":{"senderName":"Name1"}}
{"transactionId":"1234","transactionType":"Accounts","request":{"senderName":"Name2"}}
fluent-bit.yaml
service:
flush: 5
daemon: off
log_level: debug
Parsers_File: parsers.conf
pipeline:
inputs:
- name: tail
tag: my_cpu
path: /fluent-bit/logs/data.json
Read_from_Head: true
Parser: json
In the above example how to create opensearch index dynamically based on transactionType coming in the request.
For eg – If transactionType is Cards then index name should be fluent-test-Cards
Beta Was this translation helpful? Give feedback.
All reactions