mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-07-23 21:01:40 +02:00
new filterRanges query and Cluster.filterRanges field
This commit is contained in:
@@ -9,14 +9,10 @@ import (
|
||||
"time"
|
||||
)
|
||||
|
||||
type AddJobInput struct {
|
||||
JobID string `json:"jobId"`
|
||||
UserID string `json:"userId"`
|
||||
ProjectID string `json:"projectId"`
|
||||
ClusterID string `json:"clusterId"`
|
||||
StartTime time.Time `json:"startTime"`
|
||||
Duration int `json:"duration"`
|
||||
NumNodes int `json:"numNodes"`
|
||||
type FilterRanges struct {
|
||||
Duration *IntRangeOutput `json:"duration"`
|
||||
NumNodes *IntRangeOutput `json:"numNodes"`
|
||||
StartTime *TimeRangeOutput `json:"startTime"`
|
||||
}
|
||||
|
||||
type FloatRange struct {
|
||||
@@ -34,6 +30,11 @@ type IntRange struct {
|
||||
To int `json:"to"`
|
||||
}
|
||||
|
||||
type IntRangeOutput struct {
|
||||
From int `json:"from"`
|
||||
To int `json:"to"`
|
||||
}
|
||||
|
||||
type JobFilter struct {
|
||||
Tags []string `json:"tags"`
|
||||
JobID *StringInput `json:"jobId"`
|
||||
@@ -110,19 +111,6 @@ type PageRequest struct {
|
||||
Page *int `json:"page"`
|
||||
}
|
||||
|
||||
type StartJobInput struct {
|
||||
JobID string `json:"jobId"`
|
||||
UserID string `json:"userId"`
|
||||
ProjectID string `json:"projectId"`
|
||||
ClusterID string `json:"clusterId"`
|
||||
StartTime time.Time `json:"startTime"`
|
||||
NumNodes int `json:"numNodes"`
|
||||
}
|
||||
|
||||
type StopJobInput struct {
|
||||
StopTime time.Time `json:"stopTime"`
|
||||
}
|
||||
|
||||
type StringInput struct {
|
||||
Eq *string `json:"eq"`
|
||||
Contains *string `json:"contains"`
|
||||
@@ -135,6 +123,11 @@ type TimeRange struct {
|
||||
To time.Time `json:"to"`
|
||||
}
|
||||
|
||||
type TimeRangeOutput struct {
|
||||
From time.Time `json:"from"`
|
||||
To time.Time `json:"to"`
|
||||
}
|
||||
|
||||
type JobMetricScope string
|
||||
|
||||
const (
|
||||
|
Reference in New Issue
Block a user