From 103b02cad3a181951a3872fa8f6a811a7125fdda Mon Sep 17 00:00:00 2001 From: Stephen Smith Date: Wed, 22 Jun 2022 23:14:50 -0400 Subject: [PATCH] 19093: Add process details attriutes warning for container retry Arvados-DCO-1.1-Signed-off-by: Stephen Smith --- .../process-runtime-status.tsx | 21 ++++++++++++++++--- .../process-details-attributes.tsx | 2 +- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/views-components/process-runtime-status/process-runtime-status.tsx b/src/views-components/process-runtime-status/process-runtime-status.tsx index 3858e49e..41a0ae05 100644 --- a/src/views-components/process-runtime-status/process-runtime-status.tsx +++ b/src/views-components/process-runtime-status/process-runtime-status.tsx @@ -26,7 +26,8 @@ type CssRules = 'root' | 'error' | 'errorColor' | 'warning' - | 'warningColor'; + | 'warningColor' + | 'disabledPanelSummary'; const styles: StyleRulesCallback = (theme: ArvadosTheme) => ({ root: { @@ -65,15 +66,20 @@ const styles: StyleRulesCallback = (theme: ArvadosTheme) => ({ warningColor: { color: theme.customs.colors.yellow900, }, + disabledPanelSummary: { + cursor: 'default', + pointerEvents: 'none', + } }); export interface ProcessRuntimeStatusDataProps { runtimeStatus: RuntimeStatus | undefined; + containerCount: number; } type ProcessRuntimeStatusProps = ProcessRuntimeStatusDataProps & WithStyles; export const ProcessRuntimeStatus = withStyles(styles)( - ({ runtimeStatus, classes }: ProcessRuntimeStatusProps) => { + ({ runtimeStatus, containerCount, classes }: ProcessRuntimeStatusProps) => { return
{ runtimeStatus?.error &&
@@ -103,5 +109,14 @@ export const ProcessRuntimeStatus = withStyles(styles)(
} + { containerCount > 1 && +
+ + + {`Warning: Process retried ${containerCount - 1} time${containerCount > 2 ? 's' : ''} due to failure.`} + + +
+ }
-}); \ No newline at end of file +}); diff --git a/src/views/process-panel/process-details-attributes.tsx b/src/views/process-panel/process-details-attributes.tsx index 1e3e5591..4af2c9cd 100644 --- a/src/views/process-panel/process-details-attributes.tsx +++ b/src/views/process-panel/process-details-attributes.tsx @@ -64,7 +64,7 @@ export const ProcessDetailsAttributes = withStyles(styles, { withTheme: true })( const mdSize = props.twoCol ? 6 : 12; return - + {!props.hideProcessPanelRedundantFields && -- 2.30.2