refactor: use metav1.ObjectMeta in other types

This commit is contained in:
Clayton Coleman
2017-01-16 22:38:19 -05:00
parent 5a5d31555b
commit 9a2a50cda7
822 changed files with 11914 additions and 9290 deletions

View File

@@ -19,6 +19,7 @@ package predicates
import (
"fmt"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/kubernetes/pkg/api/v1"
)
@@ -32,7 +33,7 @@ func ExampleFindLabelsInSet() {
// Utility functions will inspect their labels, filter them, and so on.
nsPods := []*v1.Pod{
{
ObjectMeta: v1.ObjectMeta{
ObjectMeta: metav1.ObjectMeta{
Name: "pod1",
Namespace: "ns1",
Labels: map[string]string{
@@ -43,14 +44,14 @@ func ExampleFindLabelsInSet() {
},
}, // first pod which will be used via the utilities
{
ObjectMeta: v1.ObjectMeta{
ObjectMeta: metav1.ObjectMeta{
Name: "pod2",
Namespace: "ns1",
},
},
{
ObjectMeta: v1.ObjectMeta{
ObjectMeta: metav1.ObjectMeta{
Name: "pod3ThatWeWontSee",
},
},