GoogleCloudPlatform/kubernetes — pull request #3170 by saad-ali (2014-12-30 01:33:58+00:00)
Title: Modify "kubectl get events" to print FieldPath so BoundPod events for the same pod but different containers can be differentiated

Fixes #3164

Before change:
```
cluster/kubectl.sh get events | grep influx
TIME NAME KIND CONDITION REASON MESSAGE
Mon, 29 Dec 2014 21:56:59 +0000 influx-grafana BoundPod waiting pulled Successfully pulled image kubernetes/pause:latest
Mon, 29 Dec 2014 21:56:59 +0000 influx-grafana BoundPod waiting created Created with docker id 0536c9d30742adf4a6a956660ec99b2b71dcc68a478a35aa193fdea807951762
Mon, 29 Dec 2014 21:56:59 +0000 influx-grafana Pod Pending scheduled Successfully assigned influx-grafana to kubernetes-minion-1.c.saad-dev-vms.internal
Mon, 29 Dec 2014 21:57:00 +0000 influx-grafana BoundPod running started Started with docker id 0536c9d30742adf4a6a956660ec99b2b71dcc68a478a35aa193fdea807951762
Mon, 29 Dec 2014 21:58:06 +0000 influx-grafana BoundPod failed failed Failed to pull image kubernetes/heapster_influxdb
Mon, 29 Dec 2014 21:59:10 +0000 influx-grafana BoundPod failed failed Failed to pull image kubernetes/heapster_grafana
Mon, 29 Dec 2014 21:59:59 +0000 influx-grafana BoundPod waiting created Created with docker id 7a1f296a6b1602f18bd5911d73b40a2b356b7a871167539f2da941254a9cc7ae
Mon, 29 Dec 2014 21:59:59 +0000 influx-grafana BoundPod waiting pulled Successfully pulled image dockerfile/elasticsearch
Mon, 29 Dec 2014 21:59:59 +0000 influx-grafana BoundPod running started Started with docker id 7a1f296a6b1602f18bd5911d73b40a2b356b7a871167539f2da941254a9cc7ae
Mon, 29 Dec 2014 22:00:50 +0000 influx-grafana BoundPod running started Started with docker id 49a3b1b6918af2233db7049d70362af4db9a1a3ae2dea930d79ad921781dc690
Mon, 29 Dec 2014 22:00:50 +0000 influx-grafana BoundPod waiting created Created with docker id 49a3b1b6918af2233db7049d70362af4db9a1a3ae2dea930d79ad921781dc690
Mon, 29 Dec 2014 22:00:50 +0000 influx-grafana BoundPod waiting pulled Successfully pulled image kubernetes/heapster_influxdb
```
```influx-grafana``` ```started``` and ```failed```. Not clear what's happening.

After change:
```
cluster/kubectl.sh get events | grep influx
TIME NAME KIND SUBOBJECT CONDITION REASON MESSAGE
Tue, 30 Dec 2014 00:54:48 +0000 influx-grafana BoundPod implicitly required container net waiting pulled Successfully pulled image kubernetes/pause:latest
Tue, 30 Dec 2014 00:54:49 +0000 influx-grafana BoundPod implicitly required container net waiting created Created with docker id d0cb37b498aaa6ce9408e243a6107e429335a31356d8d39823160fa8be19d98e
Tue, 30 Dec 2014 00:54:50 +0000 influx-grafana BoundPod implicitly required container net running started Started with docker id d0cb37b498aaa6ce9408e243a6107e429335a31356d8d39823160fa8be19d98e
Tue, 30 Dec 2014 00:54:50 +0000 influx-grafana Pod Pending scheduled Successfully assigned influx-grafana to kubernetes-minion-1.c.saad-dev-vms.internal
Tue, 30 Dec 2014 00:55:13 +0000 influx-grafana BoundPod spec.containers{influxdb} failed failed Failed to pull image kubernetes/heapster_influxdb
Tue, 30 Dec 2014 00:56:11 +0000 influx-grafana BoundPod spec.containers{grafana} failed failed Failed to pull image kubernetes/heapster_grafana
Tue, 30 Dec 2014 00:57:11 +0000 influx-grafana BoundPod spec.containers{elasticsearch} failed failed Failed to pull image dockerfile/elasticsearch
Tue, 30 Dec 2014 00:57:35 +0000 influx-grafana BoundPod spec.containers{influxdb} running started Started with docker id 32d74cdde587c699b387c4c185b53e61a66b8ba3ccd947bd165b32be4f734464
Tue, 30 Dec 2014 00:57:35 +0000 influx-grafana BoundPod spec.containers{influxdb} waiting pulled Successfully pulled image kubernetes/heapster_influxdb
```
```influx-grafana``` containers ```net``` and ```influxdb``` ```started``` but containers ```grafana``` and ```elasticsearch``` ```failed```. Easier to parse what's going on in the pod.

"kubectl get events" output is still pretty messy/hard to follow. I'll follow up with proposal(s) on how we can clean it up.