rename legacy to core

This commit is contained in:
Chao Xu
2016-02-03 13:21:05 -08:00
parent ad9fa30e7e
commit 1b047f8e67
114 changed files with 491 additions and 491 deletions

View File

@@ -89,15 +89,15 @@ type realRecyclerClient struct {
}
func (c *realRecyclerClient) CreatePod(pod *api.Pod) (*api.Pod, error) {
return c.client.Legacy().Pods(pod.Namespace).Create(pod)
return c.client.Core().Pods(pod.Namespace).Create(pod)
}
func (c *realRecyclerClient) GetPod(name, namespace string) (*api.Pod, error) {
return c.client.Legacy().Pods(namespace).Get(name)
return c.client.Core().Pods(namespace).Get(name)
}
func (c *realRecyclerClient) DeletePod(name, namespace string) error {
return c.client.Legacy().Pods(namespace).Delete(name, nil)
return c.client.Core().Pods(namespace).Delete(name, nil)
}
// WatchPod returns a ListWatch for watching a pod. The stopChannel is used
@@ -109,11 +109,11 @@ func (c *realRecyclerClient) WatchPod(name, namespace, resourceVersion string, s
podLW := &cache.ListWatch{
ListFunc: func(options api.ListOptions) (runtime.Object, error) {
options.FieldSelector = fieldSelector
return c.client.Legacy().Pods(namespace).List(options)
return c.client.Core().Pods(namespace).List(options)
},
WatchFunc: func(options api.ListOptions) (watch.Interface, error) {
options.FieldSelector = fieldSelector
return c.client.Legacy().Pods(namespace).Watch(options)
return c.client.Core().Pods(namespace).Watch(options)
},
}
queue := cache.NewFIFO(cache.MetaNamespaceKeyFunc)