Feature: Support AOT across Dapr clients
- Dominant language
- C#
- Stars
- 1.2k
- Forks
- 378
- Avg merge
- 2d 1h
- Merged PRs (30d)
- 6
Description
## Expected Behavior
In a project where subscriptions are made via the bus using .WithTopic("name", nameof(class)), I would like the MapSubscribeHandler to work correctly in AOT (Ahead-Of-Time) mode.
Currently, it seems that AOT is not fully supported in this scenario, which leads to issues when using Dapr with this pattern. It would be great if this functionality could be improved to support AOT seamlessly.
## Actual Behavior
At startup, the application throws the following error, which I believe is related to the Subscription class in the following line of code:
https://github.com/dapr/dotnet-sdk/blob/master/src/Dapr.AspNetCore/DaprEndpointRouteBuilderExtensions.cs#L189

## Steps to Reproduce the Problem
=> Project c# 9 aot
=> Juste add enpoint with WithTopic
=> and use compoenent type: pubsub.rabbitmq
=> Start service
## Release Note
RELEASE NOTE: **FIX** support AOT when subscribing with the bus
Contributor guide
Assessment
This issue has not been assessed yet.