ui(deploy): strategy hint on Resources tab + indicator on StatusCard

Resources tab: add a hint under the Deploy Strategy dropdown that
explains the blue-green vs rolling trade-off (resource peak, failure
semantics), switching text based on the current selection.

StatusCard: show the active deployment's strategy inline in the info
grid so users can tell at a glance which path was taken for a given
deployment.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
hsiegeln
2026-04-23 10:00:44 +02:00
parent e9f523f2b8
commit b6e54db6ec
2 changed files with 17 additions and 9 deletions

View File

@@ -172,15 +172,22 @@ export function ResourcesTab({ value, onChange, disabled, isProd = false }: Prop
/> />
<span className={styles.configLabel}>Deploy Strategy</span> <span className={styles.configLabel}>Deploy Strategy</span>
<Select <div>
disabled={disabled} <Select
value={value.deployStrategy} disabled={disabled}
onChange={(e) => update('deployStrategy', e.target.value)} value={value.deployStrategy}
options={[ onChange={(e) => update('deployStrategy', e.target.value)}
{ value: 'blue-green', label: 'Blue/Green' }, options={[
{ value: 'rolling', label: 'Rolling' }, { value: 'blue-green', label: 'Blue/Green' },
]} { value: 'rolling', label: 'Rolling' },
/> ]}
/>
<span className={styles.configHint}>
{value.deployStrategy === 'rolling'
? 'Replace one replica at a time; peak = replicas + 1. Partial failure leaves remaining old replicas serving.'
: 'Start all new replicas, swap once all are healthy; peak = 2 × replicas. Partial failure preserves the previous deployment.'}
</span>
</div>
<span className={styles.configLabel}>Strip Path Prefix</span> <span className={styles.configLabel}>Strip Path Prefix</span>
<div className={styles.configInline}> <div className={styles.configInline}>

View File

@@ -35,6 +35,7 @@ export function StatusCard({ deployment, version, externalUrl }: Props) {
{version && <><span>JAR</span><MonoText size="sm">{version.jarFilename}</MonoText></>} {version && <><span>JAR</span><MonoText size="sm">{version.jarFilename}</MonoText></>}
{version && <><span>Checksum</span><MonoText size="xs">{version.jarChecksum.substring(0, 12)}</MonoText></>} {version && <><span>Checksum</span><MonoText size="xs">{version.jarChecksum.substring(0, 12)}</MonoText></>}
<span>Replicas</span><span>{running}/{total}</span> <span>Replicas</span><span>{running}/{total}</span>
<span>Strategy</span><span>{deployment.deploymentStrategy ?? '—'}</span>
<span>URL</span> <span>URL</span>
{deployment.status === 'RUNNING' {deployment.status === 'RUNNING'
? <a href={externalUrl} target="_blank" rel="noreferrer"><MonoText size="sm">{externalUrl}</MonoText></a> ? <a href={externalUrl} target="_blank" rel="noreferrer"><MonoText size="sm">{externalUrl}</MonoText></a>