Skip to content

Commit

Permalink
enabled tag interpolation for source value (#203)
Browse files Browse the repository at this point in the history
  • Loading branch information
hvaghani221 authored Dec 14, 2021
1 parent 8f657c4 commit 76c60c2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/fluent/plugin/out_splunk.rb
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,8 @@ def prepare_key_fields
v = instance_variable_get "@#{f}"
next unless v

if v == TAG_PLACEHOLDER
instance_variable_set "@#{f}", ->(tag, _) { tag }
if v.include? TAG_PLACEHOLDER
instance_variable_set "@#{f}", ->(tag, _) { v.gsub(TAG_PLACEHOLDER, tag) }
else
instance_variable_set "@#{f}", ->(_, _) { v }
end
Expand Down

0 comments on commit 76c60c2

Please sign in to comment.