Skip to content

Commit

Permalink
Merge pull request influxdata#1646 from influxdata/md-issue#1644
Browse files Browse the repository at this point in the history
Add `\n` following each JSON log line
  • Loading branch information
desa authored Oct 30, 2017
2 parents d97f29f + 436e2a6 commit 9611bbf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
Load service was added; the service can load tasks/handlers from a directory.
- [#1606](https://github.com/influxdata/kapacitor/pull/1606): Update Go version to 1.9.1
- [#1578](https://github.com/influxdata/kapacitor/pull/1578): Add support for exposing logs via the API.
- [#1605](https://github.com/influxdata/kapacitor/issues/1605): Add support for {{ .Duration }} on Alert Message property
- [#1605](https://github.com/influxdata/kapacitor/issues/1605): Add support for {{ .Duration }} on Alert Message property.
- [#1644](https://github.com/influxdata/kapacitor/issues/1644): Add support for [JSON lines](https://en.wikipedia.org/wiki/JSON_Streaming#Line_delimited_JSON) for steaming HTTP logs.

### Bugfixes

Expand Down
1 change: 1 addition & 0 deletions services/diagnostic/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,7 @@ func writeJSON(w Writer, now time.Time, level string, msg string, context, field
f.WriteJSONTo(w)
}
w.WriteByte('}')
w.WriteByte('\n')
}

func writeJSONTimestamp(w Writer, now time.Time) {
Expand Down

0 comments on commit 9611bbf

Please sign in to comment.