mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-07-26 06:06:15 +02:00
Add numHWThreads/numAccelerators filter
This commit is contained in:
2
frontend
2
frontend
Submodule frontend updated: 80650220a3...c04f69f8fb
@@ -1352,7 +1352,11 @@ input JobFilter {
|
|||||||
cluster: StringInput
|
cluster: StringInput
|
||||||
partition: StringInput
|
partition: StringInput
|
||||||
duration: IntRange
|
duration: IntRange
|
||||||
|
|
||||||
numNodes: IntRange
|
numNodes: IntRange
|
||||||
|
numAccelerators: IntRange
|
||||||
|
numHWThreads: IntRange
|
||||||
|
|
||||||
startTime: TimeRange
|
startTime: TimeRange
|
||||||
state: [JobState!]
|
state: [JobState!]
|
||||||
flopsAnyAvg: FloatRange
|
flopsAnyAvg: FloatRange
|
||||||
@@ -7071,6 +7075,22 @@ func (ec *executionContext) unmarshalInputJobFilter(ctx context.Context, obj int
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return it, err
|
return it, err
|
||||||
}
|
}
|
||||||
|
case "numAccelerators":
|
||||||
|
var err error
|
||||||
|
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("numAccelerators"))
|
||||||
|
it.NumAccelerators, err = ec.unmarshalOIntRange2ᚖgithubᚗcomᚋClusterCockpitᚋccᚑbackendᚋgraphᚋmodelᚐIntRange(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
|
case "numHWThreads":
|
||||||
|
var err error
|
||||||
|
|
||||||
|
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("numHWThreads"))
|
||||||
|
it.NumHWThreads, err = ec.unmarshalOIntRange2ᚖgithubᚗcomᚋClusterCockpitᚋccᚑbackendᚋgraphᚋmodelᚐIntRange(ctx, v)
|
||||||
|
if err != nil {
|
||||||
|
return it, err
|
||||||
|
}
|
||||||
case "startTime":
|
case "startTime":
|
||||||
var err error
|
var err error
|
||||||
|
|
||||||
|
@@ -53,6 +53,8 @@ type JobFilter struct {
|
|||||||
Partition *StringInput `json:"partition"`
|
Partition *StringInput `json:"partition"`
|
||||||
Duration *IntRange `json:"duration"`
|
Duration *IntRange `json:"duration"`
|
||||||
NumNodes *IntRange `json:"numNodes"`
|
NumNodes *IntRange `json:"numNodes"`
|
||||||
|
NumAccelerators *IntRange `json:"numAccelerators"`
|
||||||
|
NumHWThreads *IntRange `json:"numHWThreads"`
|
||||||
StartTime *TimeRange `json:"startTime"`
|
StartTime *TimeRange `json:"startTime"`
|
||||||
State []schema.JobState `json:"state"`
|
State []schema.JobState `json:"state"`
|
||||||
FlopsAnyAvg *FloatRange `json:"flopsAnyAvg"`
|
FlopsAnyAvg *FloatRange `json:"flopsAnyAvg"`
|
||||||
|
@@ -156,6 +156,12 @@ func buildWhereClause(filter *model.JobFilter, query sq.SelectBuilder) sq.Select
|
|||||||
if filter.NumNodes != nil {
|
if filter.NumNodes != nil {
|
||||||
query = buildIntCondition("job.num_nodes", filter.NumNodes, query)
|
query = buildIntCondition("job.num_nodes", filter.NumNodes, query)
|
||||||
}
|
}
|
||||||
|
if filter.NumAccelerators != nil {
|
||||||
|
query = buildIntCondition("job.num_acc", filter.NumAccelerators, query)
|
||||||
|
}
|
||||||
|
if filter.NumHWThreads != nil {
|
||||||
|
query = buildIntCondition("job.num_hwthreads", filter.NumHWThreads, query)
|
||||||
|
}
|
||||||
if filter.FlopsAnyAvg != nil {
|
if filter.FlopsAnyAvg != nil {
|
||||||
query = buildFloatCondition("job.flops_any_avg", filter.FlopsAnyAvg, query)
|
query = buildFloatCondition("job.flops_any_avg", filter.FlopsAnyAvg, query)
|
||||||
}
|
}
|
||||||
|
@@ -174,7 +174,11 @@ input JobFilter {
|
|||||||
cluster: StringInput
|
cluster: StringInput
|
||||||
partition: StringInput
|
partition: StringInput
|
||||||
duration: IntRange
|
duration: IntRange
|
||||||
|
|
||||||
numNodes: IntRange
|
numNodes: IntRange
|
||||||
|
numAccelerators: IntRange
|
||||||
|
numHWThreads: IntRange
|
||||||
|
|
||||||
startTime: TimeRange
|
startTime: TimeRange
|
||||||
state: [JobState!]
|
state: [JobState!]
|
||||||
flopsAnyAvg: FloatRange
|
flopsAnyAvg: FloatRange
|
||||||
|
Reference in New Issue
Block a user