Switch to versioned ListOptions in client.
This commit is contained in:
@@ -20,7 +20,6 @@ import (
|
||||
"fmt"
|
||||
|
||||
"k8s.io/kubernetes/pkg/api"
|
||||
"k8s.io/kubernetes/pkg/api/unversioned"
|
||||
"k8s.io/kubernetes/pkg/watch"
|
||||
)
|
||||
|
||||
@@ -31,10 +30,10 @@ type NamespacesInterface interface {
|
||||
type NamespaceInterface interface {
|
||||
Create(item *api.Namespace) (*api.Namespace, error)
|
||||
Get(name string) (result *api.Namespace, err error)
|
||||
List(opts unversioned.ListOptions) (*api.NamespaceList, error)
|
||||
List(opts api.ListOptions) (*api.NamespaceList, error)
|
||||
Delete(name string) error
|
||||
Update(item *api.Namespace) (*api.Namespace, error)
|
||||
Watch(opts unversioned.ListOptions) (watch.Interface, error)
|
||||
Watch(opts api.ListOptions) (watch.Interface, error)
|
||||
Finalize(item *api.Namespace) (*api.Namespace, error)
|
||||
Status(item *api.Namespace) (*api.Namespace, error)
|
||||
}
|
||||
@@ -57,7 +56,7 @@ func (c *namespaces) Create(namespace *api.Namespace) (*api.Namespace, error) {
|
||||
}
|
||||
|
||||
// List lists all the namespaces in the cluster.
|
||||
func (c *namespaces) List(opts unversioned.ListOptions) (*api.NamespaceList, error) {
|
||||
func (c *namespaces) List(opts api.ListOptions) (*api.NamespaceList, error) {
|
||||
result := &api.NamespaceList{}
|
||||
err := c.r.Get().
|
||||
Resource("namespaces").
|
||||
@@ -112,7 +111,7 @@ func (c *namespaces) Delete(name string) error {
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested namespaces.
|
||||
func (c *namespaces) Watch(opts unversioned.ListOptions) (watch.Interface, error) {
|
||||
func (c *namespaces) Watch(opts api.ListOptions) (watch.Interface, error) {
|
||||
return c.r.Get().
|
||||
Prefix("watch").
|
||||
Resource("namespaces").
|
||||
|
||||
Reference in New Issue
Block a user