mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2024-12-25 04:49:05 +01:00
Format cleanup
This commit is contained in:
parent
23e485afce
commit
96e4448505
@ -91,7 +91,7 @@
|
|||||||
minX: $minX, minY: $minY, maxX: $maxX, maxY: $maxY)
|
minX: $minX, minY: $minY, maxX: $maxX, maxY: $maxY)
|
||||||
}
|
}
|
||||||
`,
|
`,
|
||||||
variables: { filters, rows: 50, cols: 50, minX: 0.01, minY: 1., maxX: 1000., maxY },
|
variables: { filters, rows: 50, cols: 50, minX: 0.01, minY: 1., maxX: 1000., maxY }
|
||||||
})
|
})
|
||||||
|
|
||||||
onMount(() => filters.update())
|
onMount(() => filters.update())
|
||||||
|
@ -30,7 +30,9 @@
|
|||||||
);
|
);
|
||||||
|
|
||||||
const client = getContextClient();
|
const client = getContextClient();
|
||||||
const query = gql`
|
$: stats = queryStore({
|
||||||
|
client: client,
|
||||||
|
query: gql`
|
||||||
query($filters: [JobFilter!]!) {
|
query($filters: [JobFilter!]!) {
|
||||||
rows: jobsStatistics(filter: $filters, groupBy: ${type}) {
|
rows: jobsStatistics(filter: $filters, groupBy: ${type}) {
|
||||||
id
|
id
|
||||||
@ -39,12 +41,8 @@
|
|||||||
totalWalltime
|
totalWalltime
|
||||||
totalCoreHours
|
totalCoreHours
|
||||||
}
|
}
|
||||||
}`
|
}`,
|
||||||
|
variables: { filters }
|
||||||
$: stats = queryStore({
|
|
||||||
client,
|
|
||||||
query,
|
|
||||||
variables: { filters },
|
|
||||||
});
|
});
|
||||||
|
|
||||||
let filters;
|
let filters;
|
||||||
|
@ -13,8 +13,9 @@
|
|||||||
let plotWidths = [], colWidth1 = 0, colWidth2
|
let plotWidths = [], colWidth1 = 0, colWidth2
|
||||||
let from = new Date(Date.now() - 5 * 60 * 1000), to = new Date(Date.now())
|
let from = new Date(Date.now() - 5 * 60 * 1000), to = new Date(Date.now())
|
||||||
|
|
||||||
|
const client = getContextClient();
|
||||||
$: mainQuery = queryStore({
|
$: mainQuery = queryStore({
|
||||||
client: getContextClient(),
|
client: client,
|
||||||
query: gql`query($cluster: String!, $filter: [JobFilter!]!, $metrics: [String!], $from: Time!, $to: Time!) {
|
query: gql`query($cluster: String!, $filter: [JobFilter!]!, $metrics: [String!], $from: Time!, $to: Time!) {
|
||||||
nodeMetrics(cluster: $cluster, metrics: $metrics, from: $from, to: $to) {
|
nodeMetrics(cluster: $cluster, metrics: $metrics, from: $from, to: $to) {
|
||||||
host
|
host
|
||||||
|
@ -27,8 +27,9 @@
|
|||||||
let hostnameFilter = ''
|
let hostnameFilter = ''
|
||||||
let selectedMetric = ccconfig.system_view_selectedMetric
|
let selectedMetric = ccconfig.system_view_selectedMetric
|
||||||
|
|
||||||
|
const client = getContextClient();
|
||||||
$: nodesQuery = queryStore({
|
$: nodesQuery = queryStore({
|
||||||
client: getContextClient(),
|
client: client,
|
||||||
query: gql`query($cluster: String!, $metrics: [String!], $from: Time!, $to: Time!) {
|
query: gql`query($cluster: String!, $metrics: [String!], $from: Time!, $to: Time!) {
|
||||||
nodeMetrics(cluster: $cluster, metrics: $metrics, from: $from, to: $to) {
|
nodeMetrics(cluster: $cluster, metrics: $metrics, from: $from, to: $to) {
|
||||||
host
|
host
|
||||||
@ -51,7 +52,8 @@
|
|||||||
cluster: cluster,
|
cluster: cluster,
|
||||||
metrics: [selectedMetric],
|
metrics: [selectedMetric],
|
||||||
from: from.toISOString(),
|
from: from.toISOString(),
|
||||||
to: to.toISOString()}
|
to: to.toISOString()
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
let metricUnits = {}
|
let metricUnits = {}
|
||||||
|
@ -25,8 +25,9 @@
|
|||||||
let w1, w2, histogramHeight = 250
|
let w1, w2, histogramHeight = 250
|
||||||
let selectedCluster = filterPresets?.cluster ? filterPresets.cluster : null
|
let selectedCluster = filterPresets?.cluster ? filterPresets.cluster : null
|
||||||
|
|
||||||
|
const client = getContextClient();
|
||||||
$: stats = queryStore({
|
$: stats = queryStore({
|
||||||
client: getContextClient(),
|
client: client,
|
||||||
query: gql`
|
query: gql`
|
||||||
query($filters: [JobFilter!]!) {
|
query($filters: [JobFilter!]!) {
|
||||||
jobsStatistics(filter: $filters) {
|
jobsStatistics(filter: $filters) {
|
||||||
@ -37,7 +38,7 @@
|
|||||||
histDuration { count, value }
|
histDuration { count, value }
|
||||||
histNumNodes { count, value }
|
histNumNodes { count, value }
|
||||||
}}`,
|
}}`,
|
||||||
variables: { filters },
|
variables: { filters }
|
||||||
})
|
})
|
||||||
|
|
||||||
$: selectedCluster = filters[0]?.cluster ? filters[0].cluster.eq : null
|
$: selectedCluster = filters[0]?.cluster ? filters[0].cluster.eq : null
|
||||||
|
@ -59,16 +59,16 @@
|
|||||||
`;
|
`;
|
||||||
|
|
||||||
$: metricsQuery = queryStore({
|
$: metricsQuery = queryStore({
|
||||||
client,
|
client: client,
|
||||||
query,
|
query: query,
|
||||||
variables: { id, metrics, scopes },
|
variables: { id, metrics, scopes }
|
||||||
});
|
});
|
||||||
|
|
||||||
function refresh() {
|
function refresh() {
|
||||||
queryStore({
|
queryStore({
|
||||||
client,
|
client: client,
|
||||||
query,
|
query: query,
|
||||||
variables: { id, metrics, scopes },
|
variables: { id, metrics, scopes }
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user