Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
KsaweryZietara committed Dec 18, 2024
1 parent 0349d0d commit 1ab64cf
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 1 addition & 0 deletions internal/process/provisioning/apply_kyma_step.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ func (a *ApplyKymaStep) Name() string {

func (a *ApplyKymaStep) Run(operation internal.Operation, logger *slog.Logger) (internal.Operation, time.Duration, error) {
template, err := steps.DecodeKymaTemplate(operation.KymaTemplate)
err = fmt.Errorf("technical error")
if err != nil {
return a.operationManager.OperationFailed(operation, "unable to create a kyma template", err, logger)
}
Expand Down
2 changes: 0 additions & 2 deletions internal/process/provisioning/create_runtime_resource_step.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,6 @@ func (s *CreateRuntimeResourceStep) Name() string {
}

func (s *CreateRuntimeResourceStep) Run(operation internal.Operation, log *slog.Logger) (internal.Operation, time.Duration, error) {
return s.operationManager.OperationFailed(operation, fmt.Sprintf("while updating Runtime resource object"), nil, log)

if time.Since(operation.UpdatedAt) > CreateRuntimeTimeout {
log.Info(fmt.Sprintf("operation has reached the time limit: updated operation time: %s", operation.UpdatedAt))
return s.operationManager.OperationFailed(operation, fmt.Sprintf("operation has reached the time limit: %s", CreateRuntimeTimeout), nil, log)
Expand Down

0 comments on commit 1ab64cf

Please sign in to comment.