2024-07-25 17:10:00 +02:00
|
|
|
<!--
|
|
|
|
@component Main single job display component; displays plots for every metric as well as various information
|
|
|
|
|
|
|
|
Properties:
|
2024-08-01 18:59:24 +02:00
|
|
|
- `dbid Number`: The jobs DB ID
|
2024-07-25 17:10:00 +02:00
|
|
|
- `username String`: Empty string if auth. is disabled, otherwise the username as string
|
|
|
|
- `authlevel Number`: The current users authentication level
|
|
|
|
- `roles [Number]`: Enum containing available roles
|
|
|
|
-->
|
|
|
|
|
2022-06-22 11:20:57 +02:00
|
|
|
<script>
|
2024-07-22 15:41:33 +02:00
|
|
|
import {
|
|
|
|
queryStore,
|
|
|
|
gql,
|
|
|
|
getContextClient
|
|
|
|
} from "@urql/svelte";
|
2024-03-09 10:30:40 +01:00
|
|
|
import {
|
|
|
|
Row,
|
|
|
|
Col,
|
|
|
|
Card,
|
|
|
|
Spinner,
|
|
|
|
TabContent,
|
|
|
|
TabPane,
|
|
|
|
CardBody,
|
|
|
|
CardHeader,
|
|
|
|
CardTitle,
|
|
|
|
Button,
|
|
|
|
} from "@sveltestrap/sveltestrap";
|
|
|
|
import { getContext } from "svelte";
|
2024-07-26 12:34:18 +02:00
|
|
|
import {
|
|
|
|
init,
|
|
|
|
groupByScope,
|
|
|
|
checkMetricDisabled,
|
|
|
|
transformDataForRoofline,
|
|
|
|
} from "./generic/utils.js";
|
2024-08-01 16:11:23 +02:00
|
|
|
import Metric from "./job/Metric.svelte";
|
|
|
|
import StatsTable from "./job/StatsTable.svelte";
|
2024-09-05 16:44:03 +02:00
|
|
|
import JobSummary from "./job/JobSummary.svelte";
|
2024-09-04 10:23:23 +02:00
|
|
|
import ConcurrentJobs from "./generic/helper/ConcurrentJobs.svelte";
|
2024-07-26 12:34:18 +02:00
|
|
|
import PlotTable from "./generic/PlotTable.svelte";
|
|
|
|
import Roofline from "./generic/plots/Roofline.svelte";
|
|
|
|
import JobInfo from "./generic/joblist/JobInfo.svelte";
|
|
|
|
import MetricSelection from "./generic/select/MetricSelection.svelte";
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-03-09 10:30:40 +01:00
|
|
|
export let dbid;
|
2024-08-01 18:59:24 +02:00
|
|
|
export let username;
|
2024-03-09 10:30:40 +01:00
|
|
|
export let authlevel;
|
|
|
|
export let roles;
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
// Setup General
|
|
|
|
|
|
|
|
const ccconfig = getContext("cc-config")
|
|
|
|
|
|
|
|
let isMetricsSelectionOpen = false,
|
|
|
|
selectedMetrics = [],
|
|
|
|
selectedScopes = [];
|
|
|
|
|
|
|
|
let plots = {},
|
2024-09-06 12:00:33 +02:00
|
|
|
roofWidth
|
2024-07-22 15:41:33 +02:00
|
|
|
|
|
|
|
let missingMetrics = [],
|
|
|
|
missingHosts = [],
|
|
|
|
somethingMissing = false;
|
|
|
|
|
|
|
|
// Setup GQL
|
|
|
|
// First: Add Job Query to init function -> Only requires DBID as argument, received via URL-ID
|
|
|
|
// Second: Trigger jobMetrics query with now received jobInfos (scopes: from job metadata, selectedMetrics: from config or all, job: from url-id)
|
2023-08-03 19:09:15 +02:00
|
|
|
|
2024-03-09 10:30:40 +01:00
|
|
|
const { query: initq } = init(`
|
2022-06-22 11:20:57 +02:00
|
|
|
job(id: "${dbid}") {
|
|
|
|
id, jobId, user, project, cluster, startTime,
|
|
|
|
duration, numNodes, numHWThreads, numAcc,
|
|
|
|
SMT, exclusive, partition, subCluster, arrayJobId,
|
|
|
|
monitoringStatus, state, walltime,
|
2024-09-16 15:03:38 +02:00
|
|
|
tags { id, type, scope, name },
|
2022-06-22 11:20:57 +02:00
|
|
|
resources { hostname, hwthreads, accelerators },
|
2023-05-16 12:42:06 +02:00
|
|
|
metaData,
|
|
|
|
userData { name, email },
|
2023-11-24 15:11:38 +01:00
|
|
|
concurrentJobs { items { id, jobId }, count, listQuery },
|
2024-07-22 15:41:33 +02:00
|
|
|
footprint { name, stat, value }
|
2022-06-22 11:20:57 +02:00
|
|
|
}
|
2023-07-03 09:37:25 +02:00
|
|
|
`);
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
const client = getContextClient();
|
|
|
|
const query = gql`
|
|
|
|
query ($dbid: ID!, $selectedMetrics: [String!]!, $selectedScopes: [MetricScope!]!) {
|
|
|
|
jobMetrics(id: $dbid, metrics: $selectedMetrics, scopes: $selectedScopes) {
|
|
|
|
name
|
|
|
|
scope
|
|
|
|
metric {
|
|
|
|
unit {
|
|
|
|
prefix
|
|
|
|
base
|
|
|
|
}
|
|
|
|
timestep
|
|
|
|
statisticsSeries {
|
|
|
|
min
|
|
|
|
median
|
|
|
|
max
|
|
|
|
}
|
|
|
|
series {
|
|
|
|
hostname
|
|
|
|
id
|
|
|
|
data
|
|
|
|
statistics {
|
|
|
|
min
|
|
|
|
avg
|
|
|
|
max
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
`;
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
$: jobMetrics = queryStore({
|
|
|
|
client: client,
|
|
|
|
query: query,
|
|
|
|
variables: { dbid, selectedMetrics, selectedScopes },
|
|
|
|
});
|
|
|
|
|
|
|
|
function loadAllScopes() {
|
|
|
|
selectedScopes = [...selectedScopes, "socket", "core"]
|
|
|
|
jobMetrics = queryStore({
|
|
|
|
client: client,
|
|
|
|
query: query,
|
|
|
|
variables: { dbid, selectedMetrics, selectedScopes},
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
// Handle Job Query on Init -> is not executed anymore
|
2024-03-09 10:30:40 +01:00
|
|
|
getContext("on-init")(() => {
|
|
|
|
let job = $initq.data.job;
|
|
|
|
if (!job) return;
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
const pendingMetrics = [
|
2024-03-09 10:30:40 +01:00
|
|
|
"flops_any",
|
|
|
|
"mem_bw",
|
2024-07-22 15:41:33 +02:00
|
|
|
...(ccconfig[`job_view_selectedMetrics:${job.cluster}`] ||
|
|
|
|
$initq.data.globalMetrics.reduce((names, gm) => {
|
|
|
|
if (gm.availability.find((av) => av.cluster === job.cluster)) {
|
|
|
|
names.push(gm.name);
|
|
|
|
}
|
|
|
|
return names;
|
|
|
|
}, [])
|
|
|
|
),
|
2024-03-09 10:30:40 +01:00
|
|
|
...(ccconfig[`job_view_polarPlotMetrics:${job.cluster}`] ||
|
2024-07-22 15:41:33 +02:00
|
|
|
ccconfig[`job_view_polarPlotMetrics`]
|
|
|
|
),
|
2024-03-09 10:30:40 +01:00
|
|
|
...(ccconfig[`job_view_nodestats_selectedMetrics:${job.cluster}`] ||
|
2024-07-22 15:41:33 +02:00
|
|
|
ccconfig[`job_view_nodestats_selectedMetrics`]
|
|
|
|
),
|
|
|
|
];
|
2022-07-08 11:51:58 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
// Select default Scopes to load: Check before if any metric has accelerator scope by default
|
|
|
|
const accScopeDefault = [...pendingMetrics].some(function (m) {
|
|
|
|
const cluster = $initq.data.clusters.find((c) => c.name == job.cluster);
|
|
|
|
const subCluster = cluster.subClusters.find((sc) => sc.name == job.subCluster);
|
|
|
|
return subCluster.metricConfig.find((smc) => smc.name == m)?.scope === "accelerator";
|
2023-07-03 09:37:25 +02:00
|
|
|
});
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
const pendingScopes = ["node"]
|
|
|
|
if (accScopeDefault) pendingScopes.push("accelerator")
|
|
|
|
if (job.numNodes === 1) {
|
|
|
|
pendingScopes.push("socket")
|
|
|
|
pendingScopes.push("core")
|
2024-03-09 10:30:40 +01:00
|
|
|
}
|
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
selectedMetrics = [...new Set(pendingMetrics)];
|
|
|
|
selectedScopes = [...new Set(pendingScopes)];
|
2024-03-09 10:30:40 +01:00
|
|
|
});
|
2022-07-08 12:23:24 +02:00
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
// Interactive Document Title
|
2024-03-09 10:30:40 +01:00
|
|
|
$: document.title = $initq.fetching
|
|
|
|
? "Loading..."
|
|
|
|
: $initq.error
|
|
|
|
? "Error"
|
|
|
|
: `Job ${$initq.data.job.jobId} - ClusterCockpit`;
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-03-09 10:30:40 +01:00
|
|
|
// Find out what metrics or hosts are missing:
|
2024-07-22 15:41:33 +02:00
|
|
|
$: if ($initq?.data && $jobMetrics?.data?.jobMetrics) {
|
2024-03-09 10:30:40 +01:00
|
|
|
let job = $initq.data.job,
|
|
|
|
metrics = $jobMetrics.data.jobMetrics,
|
2024-07-22 15:41:33 +02:00
|
|
|
metricNames = $initq.data.globalMetrics.reduce((names, gm) => {
|
|
|
|
if (gm.availability.find((av) => av.cluster === job.cluster)) {
|
|
|
|
names.push(gm.name);
|
|
|
|
}
|
|
|
|
return names;
|
|
|
|
}, []);
|
2022-06-22 11:20:57 +02:00
|
|
|
|
2024-05-22 15:57:22 +02:00
|
|
|
// Metric not found in JobMetrics && Metric not explicitly disabled in config or deselected: Was expected, but is Missing
|
2024-03-09 10:30:40 +01:00
|
|
|
missingMetrics = metricNames.filter(
|
|
|
|
(metric) =>
|
|
|
|
!metrics.some((jm) => jm.name == metric) &&
|
2024-05-22 15:57:22 +02:00
|
|
|
selectedMetrics.includes(metric) &&
|
2024-03-09 10:30:40 +01:00
|
|
|
!checkMetricDisabled(
|
|
|
|
metric,
|
|
|
|
$initq.data.job.cluster,
|
|
|
|
$initq.data.job.subCluster,
|
|
|
|
),
|
|
|
|
);
|
|
|
|
missingHosts = job.resources
|
|
|
|
.map(({ hostname }) => ({
|
|
|
|
hostname: hostname,
|
|
|
|
metrics: metricNames.filter(
|
|
|
|
(metric) =>
|
|
|
|
!metrics.some(
|
|
|
|
(jm) =>
|
|
|
|
jm.scope == "node" &&
|
|
|
|
jm.metric.series.some((series) => series.hostname == hostname),
|
2023-06-16 16:27:30 +02:00
|
|
|
),
|
2024-03-09 10:30:40 +01:00
|
|
|
),
|
|
|
|
}))
|
|
|
|
.filter(({ metrics }) => metrics.length > 0);
|
|
|
|
somethingMissing = missingMetrics.length > 0 || missingHosts.length > 0;
|
|
|
|
}
|
|
|
|
|
2024-07-22 15:41:33 +02:00
|
|
|
// Helper
|
2024-03-09 10:30:40 +01:00
|
|
|
const orderAndMap = (grouped, selectedMetrics) =>
|
|
|
|
selectedMetrics.map((metric) => ({
|
|
|
|
metric: metric,
|
|
|
|
data: grouped.find((group) => group[0].name == metric),
|
|
|
|
disabled: checkMetricDisabled(
|
|
|
|
metric,
|
|
|
|
$initq.data.job.cluster,
|
|
|
|
$initq.data.job.subCluster,
|
|
|
|
),
|
|
|
|
}));
|
2022-06-22 11:20:57 +02:00
|
|
|
</script>
|
|
|
|
|
2024-09-09 19:01:07 +02:00
|
|
|
<Row class="mb-3">
|
2024-09-09 18:06:13 +02:00
|
|
|
<!-- Column 1: Job Info, Job Tags, Concurrent Jobs, Admin Message if found-->
|
2024-09-06 12:00:33 +02:00
|
|
|
<Col xs={12} md={6} xl={3} class="mb-3 mb-xxl-0">
|
2024-03-09 10:30:40 +01:00
|
|
|
{#if $initq.error}
|
|
|
|
<Card body color="danger">{$initq.error.message}</Card>
|
|
|
|
{:else if $initq.data}
|
2024-09-05 16:44:03 +02:00
|
|
|
<Card class="overflow-auto" style="height: 400px;">
|
|
|
|
<TabContent> <!-- on:tab={(e) => (status = e.detail)} -->
|
2024-09-18 17:23:29 +02:00
|
|
|
{#if $initq.data?.job?.metaData?.message}
|
|
|
|
<TabPane tabId="admin-msg" tab="Admin Note" active>
|
|
|
|
<CardBody>
|
|
|
|
<Card body class="mb-2" color="warning">
|
|
|
|
<h5>Job {$initq.data?.job?.jobId} ({$initq.data?.job?.cluster})</h5>
|
|
|
|
The following note was added by administrators:
|
|
|
|
</Card>
|
|
|
|
<Card body>
|
|
|
|
{@html $initq.data.job.metaData.message}
|
|
|
|
</Card>
|
|
|
|
</CardBody>
|
|
|
|
</TabPane>
|
|
|
|
{/if}
|
|
|
|
<TabPane tabId="meta-info" tab="Job Info" active={$initq.data?.job?.metaData?.message?false:true}>
|
2024-09-05 16:44:03 +02:00
|
|
|
<CardBody class="pb-2">
|
2024-09-18 17:23:29 +02:00
|
|
|
<JobInfo job={$initq.data.job} {username} {authlevel} {roles} showTags={false} showTagedit/>
|
2024-09-09 18:06:13 +02:00
|
|
|
</CardBody>
|
|
|
|
</TabPane>
|
2024-09-05 16:44:03 +02:00
|
|
|
{#if $initq.data.job.concurrentJobs != null && $initq.data.job.concurrentJobs.items.length != 0}
|
|
|
|
<TabPane tabId="shared-jobs">
|
|
|
|
<span slot="tab">
|
|
|
|
{$initq.data.job.concurrentJobs.items.length} Concurrent Jobs
|
|
|
|
</span>
|
|
|
|
<CardBody>
|
|
|
|
<ConcurrentJobs cJobs={$initq.data.job.concurrentJobs} showLinks={(authlevel > roles.manager)}/>
|
|
|
|
</CardBody>
|
|
|
|
</TabPane>
|
|
|
|
{/if}
|
|
|
|
</TabContent>
|
|
|
|
</Card>
|
2024-03-09 10:30:40 +01:00
|
|
|
{:else}
|
|
|
|
<Spinner secondary />
|
2023-11-16 12:49:20 +01:00
|
|
|
{/if}
|
2024-03-09 10:30:40 +01:00
|
|
|
</Col>
|
2024-09-05 16:44:03 +02:00
|
|
|
|
2024-09-18 17:23:29 +02:00
|
|
|
<!-- Column 2: Job Footprint, Polar Representation, Heuristic Summary -->
|
|
|
|
<Col xs={12} md={6} xl={4} xxl={3} class="mb-3 mb-xxl-0">
|
|
|
|
{#if $initq.error}
|
|
|
|
<Card body color="danger">{$initq.error.message}</Card>
|
|
|
|
{:else if $initq?.data && $jobMetrics?.data}
|
|
|
|
<JobSummary job={$initq.data.job} jobMetrics={$jobMetrics.data.jobMetrics}/>
|
|
|
|
{:else}
|
|
|
|
<Spinner secondary />
|
|
|
|
{/if}
|
|
|
|
</Col>
|
2024-09-05 16:44:03 +02:00
|
|
|
|
2024-09-06 12:00:33 +02:00
|
|
|
<!-- Column 3: Job Roofline; If footprint Enabled: full width, else half width -->
|
2024-09-18 17:23:29 +02:00
|
|
|
<Col xs={12} md={12} xl={5} xxl={6}>
|
2024-09-05 16:44:03 +02:00
|
|
|
{#if $initq.error || $jobMetrics.error}
|
|
|
|
<Card body color="danger">
|
|
|
|
<p>Initq Error: {$initq.error?.message}</p>
|
|
|
|
<p>jobMetrics Error: {$jobMetrics.error?.message}</p>
|
|
|
|
</Card>
|
|
|
|
{:else if $initq?.data && $jobMetrics?.data}
|
|
|
|
<Card style="height: 400px;">
|
2024-09-06 12:00:33 +02:00
|
|
|
<div bind:clientWidth={roofWidth}>
|
|
|
|
<Roofline
|
|
|
|
allowSizeChange={true}
|
|
|
|
width={roofWidth}
|
|
|
|
renderTime={true}
|
|
|
|
subCluster={$initq.data.clusters
|
|
|
|
.find((c) => c.name == $initq.data.job.cluster)
|
|
|
|
.subClusters.find((sc) => sc.name == $initq.data.job.subCluster)}
|
|
|
|
data={transformDataForRoofline(
|
|
|
|
$jobMetrics.data.jobMetrics.find(
|
|
|
|
(m) => m.name == "flops_any" && m.scope == "node",
|
|
|
|
)?.metric,
|
|
|
|
$jobMetrics.data.jobMetrics.find(
|
|
|
|
(m) => m.name == "mem_bw" && m.scope == "node",
|
|
|
|
)?.metric,
|
|
|
|
)}
|
|
|
|
/>
|
|
|
|
</div>
|
2024-09-05 16:44:03 +02:00
|
|
|
</Card>
|
|
|
|
{:else}
|
|
|
|
<Spinner secondary />
|
|
|
|
{/if}
|
|
|
|
</Col>
|
2024-03-09 10:30:40 +01:00
|
|
|
</Row>
|
2024-09-05 16:44:03 +02:00
|
|
|
|
2024-09-09 19:01:07 +02:00
|
|
|
<Card class="mb-3">
|
|
|
|
<CardBody>
|
|
|
|
<Row class="mb-2">
|
2024-09-11 11:28:11 +02:00
|
|
|
{#if $initq.data}
|
|
|
|
<Col xs="auto">
|
|
|
|
<Button outline on:click={() => (isMetricsSelectionOpen = true)} color="primary">
|
|
|
|
Select Metrics
|
|
|
|
</Button>
|
|
|
|
</Col>
|
|
|
|
{/if}
|
2024-09-09 19:01:07 +02:00
|
|
|
</Row>
|
|
|
|
<hr/>
|
|
|
|
<Row>
|
|
|
|
<Col>
|
|
|
|
{#if $jobMetrics.error}
|
|
|
|
{#if $initq.data.job.monitoringStatus == 0 || $initq.data.job.monitoringStatus == 2}
|
|
|
|
<Card body color="warning">Not monitored or archiving failed</Card>
|
|
|
|
<br />
|
|
|
|
{/if}
|
|
|
|
<Card body color="danger">{$jobMetrics.error.message}</Card>
|
|
|
|
{:else if $jobMetrics.fetching}
|
|
|
|
<Spinner secondary />
|
|
|
|
{:else if $initq?.data && $jobMetrics?.data?.jobMetrics}
|
|
|
|
<PlotTable
|
|
|
|
let:item
|
|
|
|
let:width
|
|
|
|
renderFor="job"
|
|
|
|
items={orderAndMap(
|
|
|
|
groupByScope($jobMetrics.data.jobMetrics),
|
|
|
|
selectedMetrics,
|
|
|
|
)}
|
|
|
|
itemsPerRow={ccconfig.plot_view_plotsPerRow}
|
2024-03-09 10:30:40 +01:00
|
|
|
>
|
2024-09-09 19:01:07 +02:00
|
|
|
{#if item.data}
|
|
|
|
<Metric
|
|
|
|
bind:this={plots[item.metric]}
|
|
|
|
on:load-all={loadAllScopes}
|
|
|
|
job={$initq.data.job}
|
|
|
|
metricName={item.metric}
|
|
|
|
metricUnit={$initq.data.globalMetrics.find((gm) => gm.name == item.metric)?.unit}
|
|
|
|
nativeScope={$initq.data.globalMetrics.find((gm) => gm.name == item.metric)?.scope}
|
|
|
|
rawData={item.data.map((x) => x.metric)}
|
|
|
|
scopes={item.data.map((x) => x.scope)}
|
|
|
|
{width}
|
|
|
|
isShared={$initq.data.job.exclusive != 1}
|
|
|
|
/>
|
|
|
|
{:else}
|
|
|
|
<Card body color="warning"
|
|
|
|
>No dataset returned for <code>{item.metric}</code></Card
|
|
|
|
>
|
|
|
|
{/if}
|
|
|
|
</PlotTable>
|
2022-06-22 11:20:57 +02:00
|
|
|
{/if}
|
2024-09-09 19:01:07 +02:00
|
|
|
</Col>
|
|
|
|
</Row>
|
|
|
|
</CardBody>
|
|
|
|
</Card>
|
2024-09-05 16:44:03 +02:00
|
|
|
|
2024-09-09 19:01:07 +02:00
|
|
|
<Row class="mb-3">
|
2024-03-09 10:30:40 +01:00
|
|
|
<Col>
|
|
|
|
{#if $initq.data}
|
2024-09-05 16:44:03 +02:00
|
|
|
<Card>
|
|
|
|
<TabContent>
|
|
|
|
{#if somethingMissing}
|
|
|
|
<TabPane tabId="resources" tab="Resources" active={somethingMissing}>
|
|
|
|
<div style="margin: 10px;">
|
|
|
|
<Card color="warning">
|
|
|
|
<CardHeader>
|
|
|
|
<CardTitle>Missing Metrics/Resources</CardTitle>
|
|
|
|
</CardHeader>
|
|
|
|
<CardBody>
|
|
|
|
{#if missingMetrics.length > 0}
|
|
|
|
<p>
|
|
|
|
No data at all is available for the metrics: {missingMetrics.join(
|
|
|
|
", ",
|
|
|
|
)}
|
|
|
|
</p>
|
|
|
|
{/if}
|
|
|
|
{#if missingHosts.length > 0}
|
|
|
|
<p>Some metrics are missing for the following hosts:</p>
|
|
|
|
<ul>
|
|
|
|
{#each missingHosts as missing}
|
|
|
|
<li>
|
|
|
|
{missing.hostname}: {missing.metrics.join(", ")}
|
|
|
|
</li>
|
|
|
|
{/each}
|
|
|
|
</ul>
|
|
|
|
{/if}
|
|
|
|
</CardBody>
|
|
|
|
</Card>
|
|
|
|
</div>
|
|
|
|
</TabPane>
|
2024-03-09 10:30:40 +01:00
|
|
|
{/if}
|
2024-09-05 16:44:03 +02:00
|
|
|
<TabPane
|
|
|
|
tabId="stats"
|
|
|
|
tab="Statistics Table"
|
2024-09-10 12:14:34 +02:00
|
|
|
class="overflow-x-auto"
|
2024-09-05 16:44:03 +02:00
|
|
|
active={!somethingMissing}
|
|
|
|
>
|
|
|
|
{#if $jobMetrics?.data?.jobMetrics}
|
|
|
|
{#key $jobMetrics.data.jobMetrics}
|
|
|
|
<StatsTable
|
|
|
|
job={$initq.data.job}
|
|
|
|
jobMetrics={$jobMetrics.data.jobMetrics}
|
|
|
|
/>
|
|
|
|
{/key}
|
2024-03-09 10:30:40 +01:00
|
|
|
{/if}
|
2024-09-05 16:44:03 +02:00
|
|
|
</TabPane>
|
|
|
|
<TabPane tabId="job-script" tab="Job Script">
|
|
|
|
<div class="pre-wrapper">
|
|
|
|
{#if $initq.data.job.metaData?.jobScript}
|
|
|
|
<pre><code>{$initq.data.job.metaData?.jobScript}</code></pre>
|
|
|
|
{:else}
|
|
|
|
<Card body color="warning">No job script available</Card>
|
|
|
|
{/if}
|
|
|
|
</div>
|
|
|
|
</TabPane>
|
|
|
|
<TabPane tabId="slurm-info" tab="Slurm Info">
|
|
|
|
<div class="pre-wrapper">
|
|
|
|
{#if $initq.data.job.metaData?.slurmInfo}
|
|
|
|
<pre><code>{$initq.data.job.metaData?.slurmInfo}</code></pre>
|
|
|
|
{:else}
|
|
|
|
<Card body color="warning"
|
|
|
|
>No additional slurm information available</Card
|
|
|
|
>
|
|
|
|
{/if}
|
|
|
|
</div>
|
|
|
|
</TabPane>
|
|
|
|
</TabContent>
|
|
|
|
</Card>
|
2024-03-09 10:30:40 +01:00
|
|
|
{/if}
|
|
|
|
</Col>
|
2022-06-22 11:20:57 +02:00
|
|
|
</Row>
|
|
|
|
|
|
|
|
{#if $initq.data}
|
2024-03-09 10:30:40 +01:00
|
|
|
<MetricSelection
|
|
|
|
cluster={$initq.data.job.cluster}
|
|
|
|
configName="job_view_selectedMetrics"
|
|
|
|
bind:metrics={selectedMetrics}
|
|
|
|
bind:isOpen={isMetricsSelectionOpen}
|
|
|
|
/>
|
2022-06-22 11:20:57 +02:00
|
|
|
{/if}
|
|
|
|
|
|
|
|
<style>
|
2024-03-09 10:30:40 +01:00
|
|
|
.pre-wrapper {
|
|
|
|
font-size: 1.1rem;
|
|
|
|
margin: 10px;
|
|
|
|
border: 1px solid #bbb;
|
|
|
|
border-radius: 5px;
|
|
|
|
padding: 5px;
|
|
|
|
}
|
2023-05-16 12:42:06 +02:00
|
|
|
|
2024-03-09 10:30:40 +01:00
|
|
|
ul {
|
|
|
|
columns: 2;
|
|
|
|
-webkit-columns: 2;
|
|
|
|
-moz-columns: 2;
|
|
|
|
}
|
2022-06-22 11:20:57 +02:00
|
|
|
</style>
|