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

Cherry-pick #9856 to 6.x: Add docker event metricset #9962

Merged
merged 4 commits into from
Jan 22, 2019
Merged
Show file tree
Hide file tree
Changes from 3 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 @@ -159,6 +159,7 @@ https://github.com/elastic/beats/compare/v6.6.0...6.x[Check the HEAD diff]
- Remove experimental tag from ceph metricsets. {pull}9708[9708]
- Add `key` metricset to the Redis module. {issue}9582[9582] {pull}9657[9657]
- Add DeDot for kubernetes labels and annotations. {issue}9860[9860] {pull}9939[9939]
- Add docker `event` metricset. {pull}9856[9856]

*Packetbeat*

Expand Down
84 changes: 84 additions & 0 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2996,6 +2996,90 @@ type: scaled_float
Number of reads and writes per second


--

[float]
== event fields

Docker event



*`docker.event.status`*::
+
--
type: keyword

Event status


--

*`docker.event.id`*::
+
--
type: keyword

Event id when available


--

*`docker.event.from`*::
+
--
type: keyword

Event source


--

*`docker.event.type`*::
+
--
type: keyword

The type of object emitting the event


--

*`docker.event.action`*::
+
--
type: keyword

The type of event


--

[float]
== actor fields

Actor



*`docker.event.actor.id`*::
+
--
type: keyword

The ID of the object emitting the event


--

*`docker.event.actor.attributes`*::
+
--
type: object

Various key/value attributes of the object, depending on its type


--

[float]
Expand Down
5 changes: 5 additions & 0 deletions metricbeat/docs/modules/docker.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ metricbeat.modules:
- "container"
- "cpu"
- "diskio"
- "event"
- "healthcheck"
- "info"
#- "image"
Expand Down Expand Up @@ -71,6 +72,8 @@ The following metricsets are available:

* <<metricbeat-metricset-docker-diskio,diskio>>

* <<metricbeat-metricset-docker-event,event>>

* <<metricbeat-metricset-docker-healthcheck,healthcheck>>

* <<metricbeat-metricset-docker-image,image>>
Expand All @@ -87,6 +90,8 @@ include::docker/cpu.asciidoc[]

include::docker/diskio.asciidoc[]

include::docker/event.asciidoc[]

include::docker/healthcheck.asciidoc[]

include::docker/image.asciidoc[]
Expand Down
21 changes: 21 additions & 0 deletions metricbeat/docs/modules/docker/event.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
////
This file is generated! See scripts/docs_collector.py
////

[[metricbeat-metricset-docker-event]]
=== Docker event metricset

include::../../../module/docker/event/_meta/docs.asciidoc[]


==== Fields

For a description of each field in the metricset, see the
<<exported-fields-docker,exported fields>> section.

Here is an example document generated by this metricset:

[source,json]
----
include::../../../module/docker/event/_meta/data.json[]
----
3 changes: 2 additions & 1 deletion metricbeat/docs/modules_list.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ This file is generated! See scripts/docs_collector.py
|<<metricbeat-metricset-couchbase-cluster,cluster>> beta[]
|<<metricbeat-metricset-couchbase-node,node>> beta[]
|<<metricbeat-module-docker,Docker>> |image:./images/icon-yes.png[Prebuilt dashboards are available] |
.8+| .8+| |<<metricbeat-metricset-docker-container,container>>
.9+| .9+| |<<metricbeat-metricset-docker-container,container>>
|<<metricbeat-metricset-docker-cpu,cpu>>
|<<metricbeat-metricset-docker-diskio,diskio>>
|<<metricbeat-metricset-docker-event,event>>
|<<metricbeat-metricset-docker-healthcheck,healthcheck>>
|<<metricbeat-metricset-docker-image,image>>
|<<metricbeat-metricset-docker-info,info>>
Expand Down
1 change: 1 addition & 0 deletions metricbeat/include/list.go

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

1 change: 1 addition & 0 deletions metricbeat/metricbeat.reference.yml
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ metricbeat.modules:
- "container"
- "cpu"
- "diskio"
- "event"
- "healthcheck"
- "info"
#- "image"
Expand Down
1 change: 1 addition & 0 deletions metricbeat/module/docker/_meta/config.reference.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
- "container"
- "cpu"
- "diskio"
- "event"
- "healthcheck"
- "info"
#- "image"
Expand Down
1 change: 1 addition & 0 deletions metricbeat/module/docker/_meta/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# - container
# - cpu
# - diskio
# - event
# - healthcheck
# - info
# - memory
Expand Down
29 changes: 29 additions & 0 deletions metricbeat/module/docker/event/_meta/data.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"@timestamp": "2017-10-12T08:05:34.853Z",
"agent": {
"hostname": "host.example.com",
"name": "host.example.com"
},
"docker": {
"event": {
"action": "pull",
"actor": {
"attributes": {
"name": "busybox"
},
"id": "busybox:latest"
},
"from": "",
"id": "busybox:latest",
"status": "pull",
"type": "image"
}
},
"event": {
"dataset": "event",
"module": "docker"
},
"service": {
"type": "docker"
}
}
1 change: 1 addition & 0 deletions metricbeat/module/docker/event/_meta/docs.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This is the event metricset of the module docker.
40 changes: 40 additions & 0 deletions metricbeat/module/docker/event/_meta/fields.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
- name: event
type: group
description: >
Docker event
release: ga
fields:
- name: status
type: keyword
description: >
Event status
- name: id
type: keyword
description: >
Event id when available
- name: from
type: keyword
description: >
Event source
- name: type
type: keyword
description: >
The type of object emitting the event
- name: action
type: keyword
description: >
The type of event
- name: actor
type: group
description: >
Actor
fields:
- name: id
type: keyword
description: >
The ID of the object emitting the event
- name: attributes
type: object
object_type: keyword
description: >
Various key/value attributes of the object, depending on its type
Loading