Default unavailable deployment targets to fail-fast#424
Merged
Conversation
An unconfigured project's "Transient Deployment Targets" policy defaulted to SkipAndContinue: when a target was unavailable at deployment start it was silently dropped and the deployment still reported success. A failed target masquerading as a green deploy is a dangerous default. Flip the unconfigured default to FailDeployment so an unreachable target aborts the deployment up front. The fail-fast plumbing already existed in phase 4 and the preview path; only the default value changes. System.Text. Json keeps the property initializer when the field is absent, so a project that explicitly persisted SkipAndContinue is preserved and only never- configured projects pick up the new default. The per-project setting remains the opt-out for operators who want the lenient behaviour. The enum wire encoding is unchanged (value 0 stays SkipAndContinue); the default is applied at the settings DTO, not by enum ordinal, so persisted blobs are unaffected.
ppXD
force-pushed
the
fix/unavailable-target-fail-fast-default
branch
from
June 10, 2026 07:58
5396973 to
90e9a2a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
SkipAndContinue: an unavailable target at deployment start was silently dropped and the deployment still reported success. A failed target masquerading as a green deploy is a dangerous default.FailDeployment(TransientDeploymentTargetsDto.UnavailableDeploymentTargetsinitializer) so an unreachable target aborts the deployment up front. The fail-fast plumbing already existed in phase 4 (PrepareDeploymentPhase) and the preview path — only the default value changes.SkipAndContinueis preserved; only never-configured projects pick up fail-fast. The per-project "Transient Deployment Targets" setting remains the opt-out for operators who want the lenient behaviour.Exclude) is unchanged. The enum wire encoding is unchanged (value 0 staysSkipAndContinue); the default is applied at the DTO, not by enum ordinal, so persisted blobs are unaffected.Test plan
FailDeployment; explicitSkipAndContinuepreserved over the default (opt-out)ApplyProjectPolicy(null/empty/invalid)→ unavailable →FailedUnavailable, unhealthy still excluded; preview⇿deploy convergence still holdsDeploymentTargetException; null settings + only-unhealthy still excludes (no throw)GetAsyncon an unconfigured project returnsFailDeploymentServices.Deploymentsunit namespace 3983/3983 green;dotnet build Squid.sln0 errorsFailDeploymentbehaviour and its phase-4/preview plumbing are unchanged and already coveredOperator note
The frontend Deployment Settings UI renders the enum value the API returns, so an unconfigured project now shows "Fail deployment" preselected (the accurate new default) — no frontend change required.