Skip to content

Don't wait for parameter/connection string resources#7314

Merged
davidfowl merged 1 commit intomainfrom
davidfowl/parameter-hang
Jan 29, 2025
Merged

Don't wait for parameter/connection string resources#7314
davidfowl merged 1 commit intomainfrom
davidfowl/parameter-hang

Conversation

@davidfowl
Copy link
Copy Markdown
Contributor

Description

Parameter resources do not have a lifecycle and it's not possible to wait on them today, yet this hangs. This PR special cases those for now but that's not the long-term solution. We need a design to let the system know when resources do or don't have a lifecycle (or we need to be able to detect terminal states). I chose to unblock this scenario for now with simpler code because it affects a key scenario: Using existing resources.

Fixes #6858

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • No
  • Does the change make any security assumptions or guarantees?
    • No
  • Does the change require an update in our Aspire docs?
    • No

- Skip from waiting on them at the annotation level

Fixes #6858
@davidfowl davidfowl requested a review from mitchdenny as a code owner January 29, 2025 09:11
@davidfowl davidfowl requested review from JamesNK and Copilot and removed request for mitchdenny January 29, 2025 09:11
Copy link
Copy Markdown
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.

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

// Parameters and connection string resources are inert and don't need to be waited on.
// If we add support for parameter resources that can be waited on, we can remove this check.
// As of right now, we don't support waiting on parameter resources.
continue;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Write a warning log message? Let people know they're doing it wrong.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Can't yet. Take a look at the issue, this pattern is from our docs.

@davidfowl davidfowl enabled auto-merge (squash) January 29, 2025 09:56
@davidfowl davidfowl merged commit 444eb64 into main Jan 29, 2025
@davidfowl davidfowl deleted the davidfowl/parameter-hang branch January 29, 2025 10:35
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 1, 2025
@github-actions github-actions Bot added the area-app-model Issues pertaining to the APIs in Aspire.Hosting, e.g. DistributedApplication label Mar 10, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-app-model Issues pertaining to the APIs in Aspire.Hosting, e.g. DistributedApplication

Projects

None yet

Development

Successfully merging this pull request may close these issues.

.WaitFor never completes when using a ConnectionString resource

3 participants