Skip to content

add last update time in queueunit status #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
22 changes: 12 additions & 10 deletions pkg/apis/scheduling/v1alpha1/type.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ type Queue struct {

// QueueSpec defines the desired state of Queue
type QueueSpec struct {
QueuePolicy QueuePolicy `json:"queuePolicy,omitempty" protobuf:"bytes,1,opt,name=queuePolicy`
Priority *int32 `json:"priority,omitempty" protobuf:"varint,2,opt,name=priority"`
PriorityClassName string `json:"priorityClassName,omitempty" protobuf:"bytes,3,opt,name=priorityClassName"`
QueuePolicy QueuePolicy `json:"queuePolicy,omitempty" protobuf:"bytes,1,opt,name=queuePolicy`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these updates necessary?

Priority *int32 `json:"priority,omitempty" protobuf:"varint,2,opt,name=priority"`
PriorityClassName string `json:"priorityClassName,omitempty" protobuf:"bytes,3,opt,name=priorityClassName"`
}

// QueueStatus defines the observed state of Queue
Expand All @@ -48,8 +48,8 @@ type QueueStatus struct {
type QueuePolicy string

const (
QueuePolicyFIFO QueuePolicy = "FIFO"
QueuePolicyPriority QueuePolicy = "Priority"
QueuePolicyFIFO QueuePolicy = "FIFO"
QueuePolicyPriority QueuePolicy = "Priority"
)

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
Expand Down Expand Up @@ -83,18 +83,20 @@ type QueueUnitSpec struct {

// QueueUnitStatus defines the observed state of QueueUnit
type QueueUnitStatus struct {
Phase QueueUnitPhase `json:"phase" protobuf:"bytes,1,name=phase"`
Message string `json:"message,omitempty" protobuf:"bytes,2,opt,name=message"`
Phase QueueUnitPhase `json:"phase" protobuf:"bytes,1,name=phase"`
Message string `json:"message,omitempty" protobuf:"bytes,2,opt,name=message"`
LastUpdateTime *metav1.Time `json:"lastUpdateTime" protobuf:"bytes,3,name=lastUpdateTime"`
}

type QueueUnitPhase string

const (
Enqueued QueueUnitPhase = "Enqueued"
Dequeued QueueUnitPhase = "Dequeued"
SchedReady QueueUnitPhase = "SchedReady"
SchedSucceed QueueUnitPhase = "SchedSucceed"
SchedFailed QueueUnitPhase = "SchedFailed"
SchedReady QueueUnitPhase = "Running"
SchedSucceed QueueUnitPhase = "Succeed"
SchedFailed QueueUnitPhase = "Failed"
Backoff QueueUnitPhase = "TimeoutBackoff"
)

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
Expand Down
3 changes: 3 additions & 0 deletions pkg/crd/queueunit-v1alpha1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,7 @@ spec:
phase:
type: string
message:
type: string
lastUpdateTime:
format: date-time
type: string
5 changes: 5 additions & 0 deletions vendor/github.com/PuerkitoBio/purell/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions vendor/github.com/PuerkitoBio/purell/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions vendor/github.com/PuerkitoBio/purell/LICENSE

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

188 changes: 188 additions & 0 deletions vendor/github.com/PuerkitoBio/purell/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading