mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-05 15:37:24 +00:00
Simplify Watch() signature in clients.
This commit is contained in:
@@ -37,7 +37,7 @@ type DaemonSetInterface interface {
|
||||
Update(ctrl *extensions.DaemonSet) (*extensions.DaemonSet, error)
|
||||
UpdateStatus(ctrl *extensions.DaemonSet) (*extensions.DaemonSet, error)
|
||||
Delete(name string) error
|
||||
Watch(label labels.Selector, field fields.Selector, opts unversioned.ListOptions) (watch.Interface, error)
|
||||
Watch(opts unversioned.ListOptions) (watch.Interface, error)
|
||||
}
|
||||
|
||||
// daemonSets implements DaemonsSetsNamespacer interface
|
||||
@@ -93,13 +93,11 @@ func (c *daemonSets) Delete(name string) error {
|
||||
}
|
||||
|
||||
// Watch returns a watch.Interface that watches the requested daemon sets.
|
||||
func (c *daemonSets) Watch(label labels.Selector, field fields.Selector, opts unversioned.ListOptions) (watch.Interface, error) {
|
||||
func (c *daemonSets) Watch(opts unversioned.ListOptions) (watch.Interface, error) {
|
||||
return c.r.Get().
|
||||
Prefix("watch").
|
||||
Namespace(c.ns).
|
||||
Resource("daemonsets").
|
||||
VersionedParams(&opts, api.Scheme).
|
||||
LabelsSelectorParam(label).
|
||||
FieldsSelectorParam(field).
|
||||
Watch()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user