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

[Functionbeat] fix cloudwatch logs timestamp to use logRecord timestamp… #13291

Merged
merged 3 commits into from
Aug 27, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,7 @@ https://github.com/elastic/beats/compare/v7.0.0-alpha2...master[Check the HEAD d
*Functionbeat*

- Fix function name reference for Kinesis streams in CloudFormation templates {pull}11646[11646]
- Fix Cloudwatch logs timestamp to use timestamp of the log record instead of when the record was processed {pull}13291[13291]

==== Added

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ func CloudwatchLogs(request events.CloudwatchLogsData) []beat.Event {

for idx, logEvent := range request.LogEvents {
events[idx] = beat.Event{
Timestamp: time.Now(), // TODO: time.Unix(logEvent.Timestamp, 0),
Timestamp: time.Unix(0, logEvent.Timestamp*1000000),
Fields: common.MapStr{
"message": logEvent.Message,
"id": logEvent.ID,
Expand Down