Add EventSource to api to have both Component and Host information.

This commit is contained in:
Dawn Chen
2015-01-06 13:22:58 -08:00
parent 2b91c1417c
commit e3c019128e
15 changed files with 60 additions and 29 deletions

View File

@@ -463,17 +463,17 @@ func TestPrintEventsResultSorted(t *testing.T) {
obj := api.EventList{
Items: []api.Event{
{
Source: "kubelet",
Source: api.EventSource{Component: "kubelet"},
Message: "Item 1",
Timestamp: util.NewTime(time.Date(2014, time.January, 15, 0, 0, 0, 0, time.UTC)),
},
{
Source: "scheduler",
Source: api.EventSource{Component: "scheduler"},
Message: "Item 2",
Timestamp: util.NewTime(time.Date(1987, time.June, 17, 0, 0, 0, 0, time.UTC)),
},
{
Source: "kubelet",
Source: api.EventSource{Component: "kubelet"},
Message: "Item 3",
Timestamp: util.NewTime(time.Date(2002, time.December, 25, 0, 0, 0, 0, time.UTC)),
},