diff --git a/api/swagger-spec/v1.json b/api/swagger-spec/v1.json index fcc70ea0331..d05d3d9aaeb 100644 --- a/api/swagger-spec/v1.json +++ b/api/swagger-spec/v1.json @@ -56,7 +56,7 @@ ] }, { - "path": "/api/v1/namespaces/{namespace}/componentstatuses", + "path": "/api/v1/componentstatuses", "description": "API at /api/v1", "operations": [ { @@ -104,14 +104,6 @@ "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history.", "required": false, "allowMultiple": false - }, - { - "type": "string", - "paramType": "path", - "name": "namespace", - "description": "object name and auth scope, such as for teams and projects", - "required": true, - "allowMultiple": false } ], "responseMessages": [ @@ -131,7 +123,7 @@ ] }, { - "path": "/api/v1/namespaces/{namespace}/componentstatuses/{name}", + "path": "/api/v1/componentstatuses/{name}", "description": "API at /api/v1", "operations": [ { @@ -148,14 +140,6 @@ "required": false, "allowMultiple": false }, - { - "type": "string", - "paramType": "path", - "name": "namespace", - "description": "object name and auth scope, such as for teams and projects", - "required": true, - "allowMultiple": false - }, { "type": "string", "paramType": "path", @@ -181,73 +165,6 @@ } ] }, - { - "path": "/api/v1/componentstatuses", - "description": "API at /api/v1", - "operations": [ - { - "type": "v1.ComponentStatusList", - "method": "GET", - "summary": "list objects of kind ComponentStatus", - "nickname": "listComponentStatus", - "parameters": [ - { - "type": "string", - "paramType": "query", - "name": "pretty", - "description": "If 'true', then the output is pretty printed.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "labelSelector", - "description": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "fieldSelector", - "description": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "required": false, - "allowMultiple": false - }, - { - "type": "boolean", - "paramType": "query", - "name": "watch", - "description": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "required": false, - "allowMultiple": false - }, - { - "type": "string", - "paramType": "query", - "name": "resourceVersion", - "description": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history.", - "required": false, - "allowMultiple": false - } - ], - "responseMessages": [ - { - "code": 200, - "message": "OK", - "responseModel": "v1.ComponentStatusList" - } - ], - "produces": [ - "application/json" - ], - "consumes": [ - "*/*" - ] - } - ] - }, { "path": "/api/v1/namespaces/{namespace}/endpoints", "description": "API at /api/v1", diff --git a/pkg/api/install/install.go b/pkg/api/install/install.go index 49eeb3ca330..0bce74be126 100644 --- a/pkg/api/install/install.go +++ b/pkg/api/install/install.go @@ -77,6 +77,7 @@ func init() { "Minion", "Namespace", "PersistentVolume", + "ComponentStatus", ) // these kinds should be excluded from the list of resources diff --git a/pkg/kubectl/cmd/get_test.go b/pkg/kubectl/cmd/get_test.go index e5f07480da1..98864021b9e 100644 --- a/pkg/kubectl/cmd/get_test.go +++ b/pkg/kubectl/cmd/get_test.go @@ -90,21 +90,21 @@ func testComponentStatusData() *api.ComponentStatusList { Conditions: []api.ComponentCondition{ {Type: api.ComponentHealthy, Status: api.ConditionTrue, Message: "ok", Error: "nil"}, }, - ObjectMeta: api.ObjectMeta{Name: "servergood", Namespace: "test"}, + ObjectMeta: api.ObjectMeta{Name: "servergood"}, } bad := api.ComponentStatus{ Conditions: []api.ComponentCondition{ {Type: api.ComponentHealthy, Status: api.ConditionFalse, Message: "", Error: "bad status: 500"}, }, - ObjectMeta: api.ObjectMeta{Name: "serverbad", Namespace: "test"}, + ObjectMeta: api.ObjectMeta{Name: "serverbad"}, } unknown := api.ComponentStatus{ Conditions: []api.ComponentCondition{ {Type: api.ComponentHealthy, Status: api.ConditionUnknown, Message: "", Error: "fizzbuzz error"}, }, - ObjectMeta: api.ObjectMeta{Name: "serverunknown", Namespace: "test"}, + ObjectMeta: api.ObjectMeta{Name: "serverunknown"}, } return &api.ComponentStatusList{