-
Notifications
You must be signed in to change notification settings - Fork 152
Fix dapr using the wrong component annotations #879
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix dapr using the wrong component annotations #879
Conversation
There was a problem hiding this 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 PR fixes a bug in the Dapr integration where component annotations were being read from the wrong resource, and updates the Dapr example to use correct Redis configuration.
- Fixes
DaprDistributedApplicationLifecycleHookto readDaprComponentReferenceAnnotationfrom the Dapr sidecar instead of the main resource - Updates the Dapr example to use the correct Redis port property and conditionally add Redis password metadata
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/CommunityToolkit.Aspire.Hosting.Dapr/DaprDistributedApplicationLifecycleHook.cs |
Fixes annotation lookup to use daprSidecar.Annotations instead of resource.Annotations |
examples/dapr/CommunityToolkit.Aspire.Hosting.Dapr.AppHost/Program.cs |
Updates Redis configuration to use correct port property and conditionally adds password metadata |
|
@dotnet-policy-service agree |
Closes #878
This fixes the issue described in #878 by referencing the correct daprSidecar annotations instead of using the main components annotations when looking for
DaprComponentReferenceAnnotationinDaprDistributedApplicationLifecycleHookIt also updates the Dapr example to use the correct redis port and redis password.
PR Checklist
Other information