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"
|
||||
)
|
||||
|
||||
@@ -32,11 +31,11 @@ type EndpointsNamespacer interface {
|
||||
// EndpointsInterface has methods to work with Endpoints resources
|
||||
type EndpointsInterface interface {
|
||||
Create(endpoints *api.Endpoints) (*api.Endpoints, error)
|
||||
List(opts unversioned.ListOptions) (*api.EndpointsList, error)
|
||||
List(opts api.ListOptions) (*api.EndpointsList, error)
|
||||
Get(name string) (*api.Endpoints, error)
|
||||
Delete(name string) error
|
||||
Update(endpoints *api.Endpoints) (*api.Endpoints, error)
|
||||
Watch(opts unversioned.ListOptions) (watch.Interface, error)
|
||||
Watch(opts api.ListOptions) (watch.Interface, error)
|
||||
}
|
||||
|
||||
// endpoints implements EndpointsInterface
|
||||
@@ -58,7 +57,7 @@ func (c *endpoints) Create(endpoints *api.Endpoints) (*api.Endpoints, error) {
|
||||
}
|
||||
|
||||
// List takes a selector, and returns the list of endpoints that match that selector
|
||||
func (c *endpoints) List(opts unversioned.ListOptions) (result *api.EndpointsList, err error) {
|
||||
func (c *endpoints) List(opts api.ListOptions) (result *api.EndpointsList, err error) {
|
||||
result = &api.EndpointsList{}
|
||||
err = c.r.Get().
|
||||
Namespace(c.ns).
|
||||
@@ -82,7 +81,7 @@ func (c *endpoints) Delete(name string) error {
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested endpoints for a service.
|
||||
func (c *endpoints) Watch(opts unversioned.ListOptions) (watch.Interface, error) {
|
||||
func (c *endpoints) Watch(opts api.ListOptions) (watch.Interface, error) {
|
||||
return c.r.Get().
|
||||
Prefix("watch").
|
||||
Namespace(c.ns).
|
||||
|
||||
Reference in New Issue
Block a user