Skip to content

Commit

Permalink
adding commit data to usage, changed type to bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
fearful-symmetry committed May 13, 2019
1 parent 80af3f1 commit bd22180
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 35 deletions.
42 changes: 21 additions & 21 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -4539,32 +4539,12 @@ Memory metrics.
*`docker.memory.commit`*::
+
--
type: long
Committed bytes
--
*`docker.memory.commit_peak`*::
+
--
type: long
Peak committed bytes
--
*`docker.memory.private_working_set`*::
+
--
type: long
private working set
private working sets
--
Expand Down Expand Up @@ -4629,6 +4609,26 @@ Usage memory stats.
*`docker.memory.usage.commit`*::
+
--
type: bytes
Committed bytes on Windows
--
*`docker.memory.usage.commit_peak`*::
+
--
type: long
Peak committed bytes on Windows
--
*`docker.memory.usage.max`*::
+
--
Expand Down
2 changes: 1 addition & 1 deletion metricbeat/module/docker/fields.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 9 additions & 11 deletions metricbeat/module/docker/memory/_meta/fields.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,10 @@
Memory metrics.
release: ga
fields:

- name: commit
type: long
description: >
Committed bytes
- name: commit_peak
type: long
description: >
Peak committed bytes
- name: private_working_set
type: long
description: >
private working set
private working sets
- name: fail.count
type: scaled_float
description: >
Expand Down Expand Up @@ -47,6 +37,14 @@
description: >
Usage memory stats.
fields:
- name: commit
type: bytes
description: >
Committed bytes on Windows
- name: commit_peak
type: long
description: >
Peak committed bytes on Windows
- name: max
type: long
format: bytes
Expand Down
6 changes: 4 additions & 2 deletions metricbeat/module/docker/memory/data.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,10 @@ func eventMapping(r mb.ReporterV2, memoryData *MemoryData) {
var fields common.MapStr
if memoryData.Commit+memoryData.CommitPeak+memoryData.PrivateWorkingSet > 0 {
fields = common.MapStr{
"commit": memoryData.Commit,
"commit_peak": memoryData.CommitPeak,
"usage": common.MapStr{
"commit": memoryData.Commit,
"commit_peak": memoryData.CommitPeak,
},
"private_working_set": memoryData.PrivateWorkingSet,
}
} else {
Expand Down

0 comments on commit bd22180

Please sign in to comment.