This repository was archived by the owner on Sep 12, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 70
This repository was archived by the owner on Sep 12, 2023. It is now read-only.
Missing methods in reconciler.v1 #159
Copy link
Copy link
Open
Description
In #141, methods implemented as panic("implement me!") that are aimed to let developers overriding is removed as the pull request is merged. However, when creating a demo reconciler or even run the test file pkg/reconciler.v1/common/service_test.go, it raises error:
# github.com/kubeflow/common/pkg/reconciler.v1/common
pkg/reconciler.v1/common/reconciler.go:60:24: cannot use jobInter (type *KubeflowJobReconciler) as type JobInterface in assignment:
*KubeflowJobReconciler does not implement JobInterface (missing ExtractJobStatus method)
pkg/reconciler.v1/common/reconciler.go:66:24: cannot use jobInter (type *KubeflowJobReconciler) as type JobInterface in assignment:
*KubeflowJobReconciler does not implement JobInterface (missing ExtractJobStatus method)
pkg/reconciler.v1/common/reconciler.go:73:34: cannot use jobInter (type *KubeflowJobReconciler) as type JobInterface in assignment:
*KubeflowJobReconciler does not implement JobInterface (missing ExtractJobStatus method)
FAIL command-line-arguments [build failed]
FAILSimply comment out the DefaultKubeflowReconciler method in pkg/reconciler.v1/common/reconciler.go does not resolve the problem as new error appears:
# github.com/kubeflow/common/test_job/reconciler.v1/test_job
test_job/reconciler.v1/test_job/test_job_reconciler.go:54:24: cannot use jobInter (type *"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler) as type "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface in assignment:
*"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler does not implement "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface (missing ExtractJobStatus method)
test_job/reconciler.v1/test_job/test_job_reconciler.go:60:24: cannot use jobInter (type *"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler) as type "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface in assignment:
*"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler does not implement "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface (missing ExtractJobStatus method)
test_job/reconciler.v1/test_job/test_job_reconciler.go:67:34: cannot use jobInter (type *"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler) as type "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface in assignment:
*"github.com/kubeflow/common/pkg/reconciler.v1/common".KubeflowJobReconciler does not implement "github.com/kubeflow/common/pkg/reconciler.v1/common".JobInterface (missing ExtractJobStatus method)
FAIL command-line-arguments [build failed]
FAILWhile the error message shows the ExtractJobStatus method is missing, there are other methods still needs to be implemented.
There seems two solutions to this problem:
- comment out
DefaultKubeflowReconcilermethod inpkg/reconciler.v1/common/reconciler.goand let user to implement these methods in a lower reconciler level (JobReconciler) level instead of the top level - add these methods back in
pkg/reconciler.v1/commonwithpanic("implement me!")so developers only need to override these methods at the top level.
Metadata
Metadata
Assignees
Labels
No labels