Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

otel, loki: support dynamic headers() #334

Merged
merged 13 commits into from
Oct 21, 2024

Conversation

alltilla
Copy link
Member

No description provided.

Copy link
Contributor

github-actions bot commented Oct 11, 2024

This Pull Request introduces config grammar changes

axoflow/71be47e0d85d46e497584cf39d346164a7e0c89b -> alltilla/grpc-dynamic-headers

--- a/destination
+++ b/destination

 axosyslog-otlp(
+    frac-digits(<nonnegative-integer>)
     headers(
-        <string> => <string>
+        <string> => <template-content>
+        <string> => <template-reference>
     )
+    local-time-zone(<string>)
+    on-error(<string>)
+    send-time-zone(<string>)
+    template-escape(<yesno>)
+    time-zone(<string>)
+    ts-format(<string>)
 )

 bigquery(
     headers(
-        <string> => <string>
+        <string> => <template-content>
+        <string> => <template-reference>
     )
 )

 loki(
     headers(
-        <string> => <string>
+        <string> => <template-content>
+        <string> => <template-reference>
     )
 )

 opentelemetry(
+    frac-digits(<nonnegative-integer>)
     headers(
-        <string> => <string>
+        <string> => <template-content>
+        <string> => <template-reference>
     )
+    local-time-zone(<string>)
+    on-error(<string>)
+    send-time-zone(<string>)
+    template-escape(<yesno>)
+    time-zone(<string>)
+    ts-format(<string>)
 )

 syslog-ng-otlp(
+    frac-digits(<nonnegative-integer>)
     headers(
-        <string> => <string>
+        <string> => <template-content>
+        <string> => <template-reference>
     )
+    local-time-zone(<string>)
+    on-error(<string>)
+    send-time-zone(<string>)
+    template-escape(<yesno>)
+    time-zone(<string>)
+    ts-format(<string>)
 )

alltilla added a commit to alltilla/axosyslog that referenced this pull request Oct 11, 2024
Signed-off-by: Attila Szakacs <[email protected]>
alltilla added a commit to alltilla/axosyslog that referenced this pull request Oct 11, 2024
Signed-off-by: Attila Szakacs <[email protected]>
alltilla added a commit to alltilla/axosyslog that referenced this pull request Oct 11, 2024
Signed-off-by: Attila Szakacs <[email protected]>
alltilla added a commit to alltilla/axosyslog that referenced this pull request Oct 11, 2024
Signed-off-by: Attila Szakacs <[email protected]>
Out intention is to batch messages that correspond
to the same label set. If between two messages the
label set changes, but they arrive to the same
worker, we should flush the previous batch.

Signed-off-by: Attila Szakacs <[email protected]>
Will be useful for templated headers as well.

Signed-off-by: Attila Szakacs <[email protected]>
This will be needed for the dynamic headers.

Signed-off-by: Attila Szakacs <[email protected]>
It must be enabled in the derived class, and
prepare_context_dynamic() must be used if so.

This is not part of this commit, enabling it will be
done in subsequent commits.

Signed-off-by: Attila Szakacs <[email protected]>
Signed-off-by: Attila Szakacs <[email protected]>
Signed-off-by: Attila Szakacs <[email protected]>
@bazsi
Copy link
Member

bazsi commented Oct 16, 2024

I did not test this explicitly, but went through the commits and they all looked fine to me.

modules/grpc/loki/loki-dest.cpp Outdated Show resolved Hide resolved
@MrAnno MrAnno merged commit 5a31414 into axoflow:main Oct 21, 2024
22 checks passed
fekete-robert pushed a commit to axoflow/axosyslog-core-docs that referenced this pull request Nov 9, 2024
fekete-robert pushed a commit to axoflow/axosyslog-core-docs that referenced this pull request Nov 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants