Skip to content

Conversation

@karolz-ms
Copy link
Collaborator

A fix for an issue that I discovered when testing some Aspire updates. Basically, we might fail to update EffectiveEnv and EffectiveArgs properties during asynchronous Executable startup.

Most of this change is about adding required test infra and tests to ensure we do not regress this in future. The actual fix is in the Executable controller.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request fixes an issue where EffectiveEnv and EffectiveArgs properties of Executable resources might not be properly updated during asynchronous Executable startup.

Changes:

  • Fixed the Executable controller to properly track and propagate status changes when computing effective environment and arguments, even during asynchronous startup
  • Added test infrastructure (TestProcessExecutableRunner) to simulate asynchronous executable startup with configurable delays
  • Extended existing integration tests to cover both synchronous and asynchronous startup scenarios
  • Fixed a typo in a comment (Falback → Fallback)

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
controllers/executable_controller.go Core fix: Changed computeExecutableEnvironment to return success flag and objectChange, ensuring EffectiveEnv/EffectiveArgs updates are propagated even during async startup; fixed typo
internal/exerunners/process_executable_runner.go Fixed ordering: Set StartupError before calling OnStartupCompleted
internal/testutil/ctrlutil/test_process_executable_runner.go New test wrapper to simulate asynchronous executable startup with configurable delays
internal/testutil/process.go Moved process-related types from test_process_executor.go and added AsynchronousStartupDelay field
internal/testutil/test_process_executor.go Removed process-related types that were moved to process.go
test/integration/executable_controller_test.go Extended three tests to run with both sync and async startup scenarios
test/integration/standard_test_env.go Integrated TestProcessExecutableRunner into test environment
test/integration/controllers_common_test.go Added global testProcessExecutableRunner variable
test/integration/advanced_test_env.go Updated to use TestProcessExecutableRunner and return AdvancedTestEnvironmentInfo
test/integration/container_network_tunnel_proxy_test.go Updated to use new AdvancedTestEnvironmentInfo structure

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 28, 2026 21:32
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@karolz-ms karolz-ms enabled auto-merge (squash) January 28, 2026 21:51
@karolz-ms
Copy link
Collaborator Author

/backport to release/0.22

@github-actions
Copy link

Started backporting to release/0.22: https://github.com/microsoft/dcp/actions/runs/21456865049

@github-actions
Copy link

@karolz-ms backport PR couldn't be created automatically, please create the backport PR manually!

Open backport PR into release/0.22.

@karolz-ms karolz-ms merged commit bd943a4 into main Jan 28, 2026
17 checks passed
@karolz-ms karolz-ms deleted the dev/karolz/effective-env branch January 28, 2026 22:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants