diff --git a/internal/metricdata/cc-metric-store.go b/internal/metricdata/cc-metric-store.go index f3ee55f..2b92fbb 100644 --- a/internal/metricdata/cc-metric-store.go +++ b/internal/metricdata/cc-metric-store.go @@ -644,7 +644,7 @@ func (ccms *CCMetricStore) LoadNodeData( req.Queries = append(req.Queries, ApiQuery{ Hostname: node, Metric: ccms.toRemoteName(metric), - Resolution: 60, // Default for Node Queries + Resolution: 0, // Default for Node Queries: Will return metric $Timestep Resolution }) } } diff --git a/web/frontend/src/Job.root.svelte b/web/frontend/src/Job.root.svelte index 086f25c..aa5b9fd 100644 --- a/web/frontend/src/Job.root.svelte +++ b/web/frontend/src/Job.root.svelte @@ -117,20 +117,39 @@ } `; +const roofQuery = gql` + query ($dbid: ID!, $selectedMetrics: [String!]!, $selectedScopes: [MetricScope!]!, $selectedResolution: Int) { + jobMetrics(id: $dbid, metrics: $selectedMetrics, scopes: $selectedScopes, resolution: $selectedResolution) { + name + scope + metric { + series { + data + } + } + } + } + `; + $: jobMetrics = queryStore({ client: client, query: query, variables: { dbid, selectedMetrics, selectedScopes }, }); + // Roofline: Always load roofMetrics with configured timestep (Resolution: 0) + $: roofMetrics = queryStore({ + client: client, + query: roofQuery, + variables: { dbid, selectedMetrics: ["flops_any", "mem_bw"], selectedScopes: ["node"], selectedResolution: 0 }, + }); + // Handle Job Query on Init -> is not executed anymore getContext("on-init")(() => { let job = $initq.data.job; if (!job) return; const pendingMetrics = [ - "flops_any", - "mem_bw", ...(ccconfig[`job_view_selectedMetrics:${job.cluster}`] || $initq.data.globalMetrics.reduce((names, gm) => { if (gm.availability.find((av) => av.cluster === job.cluster)) { @@ -276,12 +295,12 @@
Initq Error: {$initq.error?.message}
-jobMetrics Error: {$jobMetrics.error?.message}
+roofMetrics (jobMetrics) Error: {$roofMetrics.error?.message}