Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

Commit

Permalink
update config
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin Su <[email protected]>
  • Loading branch information
pingsutw committed Aug 31, 2023
1 parent 0a0e00d commit d5e4b59
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion go/tasks/plugins/k8s/kfoperators/common/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ var (
Timeout: config.Duration{Duration: 1 * time.Minute},
}

configSection = pluginsConfig.MustRegisterSubSection("common", &defaultConfig)
configSection = pluginsConfig.MustRegisterSubSection("kf-operator", &defaultConfig)
)

// Config is config for 'pytorch' plugin
Expand Down
2 changes: 1 addition & 1 deletion go/tasks/plugins/k8s/kfoperators/mpi/mpi.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ func (mpiOperatorResourceHandler) GetTaskPhase(_ context.Context, pluginContext
return pluginsCore.PhaseInfoUndefined, err
}
if app.Status.StartTime == nil && app.CreationTimestamp.Add(common.GetConfig().Timeout.Duration).Before(time.Now()) {
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the mpi coustum resource since creation time %v", app.CreationTimestamp)
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the mpi custom resource since creation time %v", app.CreationTimestamp)
}

Check warning on line 214 in go/tasks/plugins/k8s/kfoperators/mpi/mpi.go

View check run for this annotation

Codecov / codecov/patch

go/tasks/plugins/k8s/kfoperators/mpi/mpi.go#L213-L214

Added lines #L213 - L214 were not covered by tests
currentCondition, err := common.ExtractCurrentCondition(app.Status.Conditions)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion go/tasks/plugins/k8s/kfoperators/pytorch/pytorch.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ func (pytorchOperatorResourceHandler) GetTaskPhase(_ context.Context, pluginCont
}

if app.Status.StartTime == nil && app.CreationTimestamp.Add(common.GetConfig().Timeout.Duration).Before(time.Now()) {
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the pytorch coustum resource since creation time %v", app.CreationTimestamp)
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the pytorch custom resource since creation time %v", app.CreationTimestamp)
}

Check warning on line 236 in go/tasks/plugins/k8s/kfoperators/pytorch/pytorch.go

View check run for this annotation

Codecov / codecov/patch

go/tasks/plugins/k8s/kfoperators/pytorch/pytorch.go#L235-L236

Added lines #L235 - L236 were not covered by tests
currentCondition, err := common.ExtractCurrentCondition(app.Status.Conditions)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion go/tasks/plugins/k8s/kfoperators/tensorflow/tensorflow.go
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ func (tensorflowOperatorResourceHandler) GetTaskPhase(_ context.Context, pluginC
}

if app.Status.StartTime == nil && app.CreationTimestamp.Add(common.GetConfig().Timeout.Duration).Before(time.Now()) {
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the tensorflow coustum resource since creation time %v", app.CreationTimestamp)
return pluginsCore.PhaseInfoUndefined, fmt.Errorf("kubeflow operator hasn't updated the tensorflow custom resource since creation time %v", app.CreationTimestamp)
}

Check warning on line 214 in go/tasks/plugins/k8s/kfoperators/tensorflow/tensorflow.go

View check run for this annotation

Codecov / codecov/patch

go/tasks/plugins/k8s/kfoperators/tensorflow/tensorflow.go#L213-L214

Added lines #L213 - L214 were not covered by tests

currentCondition, err := common.ExtractCurrentCondition(app.Status.Conditions)
Expand Down

0 comments on commit d5e4b59

Please sign in to comment.