feat: Allow configuration of additional headers#1771
Merged
Conversation
Contributor
Author
|
Had to make a tweak to the markdown/yaml generator that uses the configMeta.yaml file. The example I made has 2 colons and since we don't use colon+space to delimit like yaml does, I had to make a splitter function that just looks for the first delimiter and stops trying to split afterwards. |
mterhar
pushed a commit
that referenced
this pull request
Jan 14, 2026
## Which problem is this PR solving? I was playing with the tests to get to know the changes in #1771. The result is mostly the same, but I propose we maintain this version. ## Short description of the changes The multiple commits show my fiddling, but the major changes are: * a single table-driven test * the lock for synchronizing the captured headers is hidden by using an atomic type
robbkidd
reviewed
Feb 2, 2026
Member
robbkidd
left a comment
There was a problem hiding this comment.
I tried this branch out sending locally. I gave it one of the reserved headers and …
❯ go run ./cmd/refinery --config ./config.yaml --rules_config rules.yaml
cannot override reserved Honeycomb header "X-Honeycomb-Team" in Network.AdditionalHeaders
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x108 pc=0x102c43be0]
goroutine 1 [running]:
github.com/honeycombio/refinery/logger.GetLoggerImplementation({0x0?, 0x0?})
.../refinery/logger/logger.go:32 +0x20
main.main()
.../refinery/cmd/refinery/main.go:114 +0x464
exit status 2
The automated tests don't exercise main where the panic happens. This has me realize that this config validation is happening entirely outside of our existing config validation process … which is ideally where it ought to occur.
mterhar
pushed a commit
that referenced
this pull request
Feb 6, 2026
## Which problem is this PR solving? I was playing with the tests to get to know the changes in #1771. The result is mostly the same, but I propose we maintain this version. ## Short description of the changes The multiple commits show my fiddling, but the major changes are: * a single table-driven test * the lock for synchronizing the captured headers is hidden by using an atomic type
2d6117e to
8b2dfff
Compare
## Which problem is this PR solving? I was playing with the tests to get to know the changes in #1771. The result is mostly the same, but I propose we maintain this version. ## Short description of the changes The multiple commits show my fiddling, but the major changes are: * a single table-driven test * the lock for synchronizing the captured headers is hidden by using an atomic type
3f38a1c to
8ef48ab
Compare
Member
TylerHelmuth
approved these changes
Feb 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Which problem is this PR solving?
If running Refinery in an environment that requires mTLS, we need to be able to configure a header to let the proxy know where to pass the traffic along.
Short description of the changes
Adds a configuration that injects headers into each of the signals that comes out of Refinery that are destined for Honeycomb.