Skip to content

Commit

Permalink
Fix #268 Add fields CreatedAt, UpdatedAt for ModelTraining. Deprecate…
Browse files Browse the repository at this point in the history
… fields in status
  • Loading branch information
vlad-tokarev committed Sep 12, 2020
1 parent d016513 commit 9e6a623
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/operator/api/v1alpha1/modeltraining_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ type ModelTrainingStatus struct {
Message *string `json:"message,omitempty"`
// List of training results
Artifacts []TrainingResult `json:"artifacts,omitempty"`
// Info about create and update
// DEPRECATED Info about create and update
//CreatedAt *metav1.Time `json:"createdAt,omitempty"`
//UpdatedAt *metav1.Time `json:"updatedAt,omitempty"`
Modifiable `json:",inline"`
Expand Down
9 changes: 8 additions & 1 deletion packages/operator/pkg/apis/training/model_training.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,20 @@

package training

import "github.com/odahu/odahu-flow/packages/operator/api/v1alpha1"
import (
"github.com/odahu/odahu-flow/packages/operator/api/v1alpha1"
"time"
)

type ModelTraining struct {
// Model training ID
ID string `json:"id"`
// Deletion mark
DeletionMark bool `json:"deletionMark,omitempty" swaggerignore:"true"`
// CreatedAt
CreatedAt time.Time
// UpdatedAt
UpdatedAt time.Time
// Model training specification
Spec v1alpha1.ModelTrainingSpec `json:"spec,omitempty"`
// Model training status
Expand Down

0 comments on commit 9e6a623

Please sign in to comment.