Skip to content

feat: add precise pre-deployment workflow readiness checks#923

Merged
mertilginoglu merged 3 commits intostagingfrom
feat/precise-pre-deployment-readiness
Apr 9, 2026
Merged

feat: add precise pre-deployment workflow readiness checks#923
mertilginoglu merged 3 commits intostagingfrom
feat/precise-pre-deployment-readiness

Conversation

@mertilginoglu
Copy link
Copy Markdown
Contributor

@mertilginoglu mertilginoglu commented Mar 20, 2026

Motivation

Related issue: #348

Deployments can currently be triggered immediately after a new commit is pushed, even if the corresponding Build workflow for that exact branch and commit has not finished yet. In that case, deployment may fail because the required build artifacts do not exist yet.

This change improves that flow by checking whether required pre-deployment workflows are ready for the exact revision being deployed and warning the user when they are not.

Description

  • Added support for configuring requiredPreDeploymentWorkflows per environment, including persistence, DTO changes, and the database migration.
  • Added a deployment readiness API that checks the exact source branch and commit against the configured required workflows and reports whether they are READY, WAITING, FAILED, or MISSING_RUN.
  • Updated the environment edit form so maintainers can configure required pre-deployment workflows separately from the deployment workflow.
  • Updated the deploy confirmation dialog to:
    • show the actual source branch and commit being deployed
    • evaluate readiness for that exact revision
    • warn when required workflows such as Build are still running, failed, or missing
    • link to the latest matching workflow runs for easier inspection
  • Passed the commit SHA through the deploy flow so readiness checks are based on the exact revision instead of only the branch name.
  • Regenerated the OpenAPI specification and client bindings and added server/client tests for the new readiness behavior.

Testing Instructions

Prerequisites:

  • GitHub Account without having any additional access-rights (e.g. admin, owner)
  • A repository in Helios with at least one deployable environment
  • An environment configured with a deployment workflow and at least one required pre-deployment workflow such as Build
  • A branch/commit pair where one required workflow is still running, failed, or has no matching run
  • Optional: set Deployment Workflow Branch to a different branch than the source branch to verify the displayed source reference

Flow:

  1. Log in to Helios as a Developer.
  2. Navigate to the environment settings of a deployable environment.
  3. Select a deployment workflow and one or more required pre-deployment workflows, then save the environment.
  4. Open the deploy flow for a branch or PR and choose that environment.
  5. Verify the confirmation dialog shows the actual source branch and commit that will be deployed.
  6. Verify a warning is shown when a required workflow such as Build for the exact branch and commit is still running, failed, or missing.
  7. Verify the warning lists the affected workflows and offers links to the latest matching runs.
  8. Verify deployment is still possible even when the warning is shown.
  9. Re-run the same flow for a branch/commit where all required workflows succeeded and verify the warning is no longer displayed.

Screenshots

Checklist

General

Server

  • Code is performant and follows best practices
  • I documented the Java code using JavaDoc style.

Client

  • I documented the TypeScript code using JSDoc style.
  • I added multiple screenshots/screencasts of my UI changes.

@github-actions
Copy link
Copy Markdown

There hasn't been any activity on this pull request recently. Therefore, this pull request has been automatically marked as stale and will be closed if no further activity occurs within seven days. Thank you for your contributions.

@github-actions github-actions Bot added stale and removed stale labels Mar 30, 2026
@mertilginoglu mertilginoglu force-pushed the feat/precise-pre-deployment-readiness branch from 1c78e77 to 09c496d Compare April 7, 2026 14:25
@codacy-production
Copy link
Copy Markdown

codacy-production Bot commented Apr 7, 2026

Not up to standards ⛔

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🔴 Metrics 22 complexity

Metric Results
Complexity ⚠️ 22 (≤ 20 complexity)

View in Codacy

🟢 Coverage 85.21% diff coverage · +0.62% coverage variation

Metric Results
Coverage variation +0.62% coverage variation (-1.00%)
Diff coverage 85.21% diff coverage

View coverage diff in Codacy

Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (aace175) 9705 3916 40.35%
Head commit (c139f2e) 9843 (+138) 4033 (+117) 40.97% (+0.62%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#923) 142 121 85.21%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

TIP This summary will be updated as you push new changes. Give us feedback

@mertilginoglu mertilginoglu force-pushed the feat/precise-pre-deployment-readiness branch from 09c496d to ca2710c Compare April 8, 2026 13:19
@mertilginoglu mertilginoglu marked this pull request as ready for review April 8, 2026 13:25
@mertilginoglu mertilginoglu requested a review from a team as a code owner April 8, 2026 13:25
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ca2710c53d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Contributor

@meryemefe meryemefe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I reviewed and tested locally in detail. It looks very good!

@meryemefe meryemefe self-requested a review April 9, 2026 15:31
@meryemefe meryemefe self-requested a review April 9, 2026 15:34
@mertilginoglu mertilginoglu merged commit a924741 into staging Apr 9, 2026
15 of 16 checks passed
@mertilginoglu mertilginoglu deleted the feat/precise-pre-deployment-readiness branch April 9, 2026 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants