Skip to content

Commit

Permalink
Fix renaming cloud metadata processor fields (#13808) (#18355)
Browse files Browse the repository at this point in the history
Clone the underlying metadata to allow renaming sub-fields under cloud
that are injected by the cloud metadata processor.

(cherry picked from commit 6785901)

Co-authored-by: Jameel Al-Aziz <[email protected]>
  • Loading branch information
jsoriano and jalaziz authored May 8, 2020
1 parent 039ceff commit 86ba3d1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ https://github.com/elastic/beats/compare/v6.8.0...6.8.1[Check the HEAD diff]

*Affecting all Beats*

- Fix `add_cloud_metadata` to better support modifying sub-fields with other processors. {pull}13808[13808]

*Auditbeat*

*Filebeat*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ func (p *addCloudMetadata) init() {

func (p *addCloudMetadata) getMeta() common.MapStr {
p.initOnce.Do(p.init)
return p.metadata
return p.metadata.Clone()
}

func (p *addCloudMetadata) Run(event *beat.Event) (*beat.Event, error) {
Expand Down

0 comments on commit 86ba3d1

Please sign in to comment.