Skip to content

Commit

Permalink
pkg: Fix the code changed in kubeflow#486 (kubeflow#497)
Browse files Browse the repository at this point in the history
Signed-off-by: Ce Gao <[email protected]>
  • Loading branch information
gaocegege authored Mar 23, 2018
1 parent d944f75 commit eec56b5
Show file tree
Hide file tree
Showing 13 changed files with 8 additions and 26 deletions.
3 changes: 2 additions & 1 deletion pkg/apis/tensorflow/v1alpha1/zz_generated.deepcopy.go
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,9 @@ func (in *TFJob) DeepCopy() *TFJob {
func (in *TFJob) DeepCopyObject() runtime.Object {
if c := in.DeepCopy(); c != nil {
return c
} else {
return nil
}
return nil
}

// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
Expand Down
4 changes: 1 addition & 3 deletions pkg/apis/tensorflow/v1alpha1/zz_generated.defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/

// This file was auto generated by defaulter-gen. Do not edit it manually!
// This file was autogenerated by defaulter-gen. Do not edit it manually!

package v1alpha1

Expand All @@ -33,12 +33,10 @@ func RegisterDefaults(scheme *runtime.Scheme) error {
return nil
}

// SetObjectDefaults_TFJob creates SetDefaultsTFJob object for a given TFJob
func SetObjectDefaults_TFJob(in *TFJob) {
SetDefaults_TFJob(in)
}

// SetObjectDefaults_TFJobList creates SetDefaultsTFJob object for each TFJob from given list of TFJobs
func SetObjectDefaults_TFJobList(in *TFJobList) {
for i := range in.Items {
a := &in.Items[i]
Expand Down
4 changes: 1 addition & 3 deletions pkg/client/clientset/versioned/clientset.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import (
flowcontrol "k8s.io/client-go/util/flowcontrol"
)

// Interface represents the combination of three interfaces Discovery, Kubeflow and Kubeflowv1alpha1
type Interface interface {
Discovery() discovery.DiscoveryInterface
KubeflowV1alpha1() kubeflowv1alpha1.KubeflowV1alpha1Interface
Expand All @@ -41,9 +40,8 @@ func (c *Clientset) KubeflowV1alpha1() kubeflowv1alpha1.KubeflowV1alpha1Interfac
return c.kubeflowV1alpha1
}

// Kubeflow retrieves the default version of KubeflowClient.
// Deprecated: Kubeflow retrieves the default version of KubeflowClient.
// Please explicitly pick a version.
// [DEPRECATED]
func (c *Clientset) Kubeflow() kubeflowv1alpha1.KubeflowV1alpha1Interface {
return c.kubeflowV1alpha1
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/client/clientset/versioned/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@

// This package is generated by client-gen with custom arguments.

// Package versioned has the automatically generated clientset.
// This package has the automatically generated clientset.
package versioned
1 change: 0 additions & 1 deletion pkg/client/clientset/versioned/fake/clientset_generated.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ type Clientset struct {
discovery *fakediscovery.FakeDiscovery
}

//Discovery retrieves the DiscoveryClient
func (c *Clientset) Discovery() discovery.DiscoveryInterface {
return c.discovery
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/client/clientset/versioned/fake/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@

// This package is generated by client-gen with custom arguments.

// Package fake has the automatically generated fake clientset.
// This package has the automatically generated fake clientset.
package fake
2 changes: 1 addition & 1 deletion pkg/client/clientset/versioned/scheme/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@

// This package is generated by client-gen with custom arguments.

// Package scheme contains the scheme of the automatically generated clientset.
// This package contains the scheme of the automatically generated clientset.
package scheme
7 changes: 0 additions & 7 deletions pkg/client/clientset/versioned/scheme/register.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,10 @@ import (
serializer "k8s.io/apimachinery/pkg/runtime/serializer"
)

// Scheme is exported variables of runtime class
var Scheme = runtime.NewScheme()

// Codecs is exported variables of serializer class
var Codecs = serializer.NewCodecFactory(Scheme)

// ParameterCodec is exported variables of runtime class
var ParameterCodec = runtime.NewParameterCodec(Scheme)


// init method adds the group version to scheme
func init() {
v1.AddToGroupVersion(Scheme, schema.GroupVersion{Version: "v1"})
AddToScheme(Scheme)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@

// This package is generated by client-gen with custom arguments.

// Package v1alpha1 has the automatically generated typed clients.
// This package has the automatically generated typed clients.
package v1alpha1
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,10 @@ import (
testing "k8s.io/client-go/testing"
)

// FakeKubeflowV1alpha1 represents a fake structure for testing
type FakeKubeflowV1alpha1 struct {
*testing.Fake
}

// TFJobs returns a fake tf-job instance for testing
func (c *FakeKubeflowV1alpha1) TFJobs(namespace string) v1alpha1.TFJobInterface {
return &FakeTFJobs{c, namespace}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// Package v1alpha1
package v1alpha1

// TFJobExpansion represents interface for supporting TFJob expansion
type TFJobExpansion interface{}
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import (
rest "k8s.io/client-go/rest"
)

// KubeflowV1alpha1Interface represents interface for setting the REST client and TFJobsGetter
type KubeflowV1alpha1Interface interface {
RESTClient() rest.Interface
TFJobsGetter
Expand All @@ -31,7 +30,6 @@ type KubeflowV1alpha1Client struct {
restClient rest.Interface
}

// TFJobs returns current TFJobs for given namespace
func (c *KubeflowV1alpha1Client) TFJobs(namespace string) TFJobInterface {
return newTFJobs(c, namespace)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import (
time "time"
)

// NewInformerFunc a helping method for SharedInformerFactory interface
type NewInformerFunc func(versioned.Interface, time.Duration) cache.SharedIndexInformer

// SharedInformerFactory a small interface to allow for adding an informer without an import cycle
Expand Down

0 comments on commit eec56b5

Please sign in to comment.