dapr / dotnet-sdk

Dapr SDK for .NET
Apache License 2.0
1.12k stars 341 forks source link

Support case insensitive cloudevent payloads and forward cloudevent props s headers #1153

Closed IliasP91 closed 1 month ago

IliasP91 commented 1 year ago

Description

Extend the existing CloudEvent Middleware to:

This will make the middleware accept JSON payloads that are Pascal cases, as the default ASP Net core options already do. And add the option to forward all the cloud event properties that are not automatically forwarded by the Dapr sidecar as headers. I had a use case where I wanted to read the type of the event (not just filter it) in my handler and currently there is no way of doing it as the middleware just unfolds the cloudevent envelope and discards it.

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

IliasP91 commented 1 year ago

hi again, could someone have a look at this PR? I has been sitting there for a few months now...

marcduiker commented 1 day ago

@holopin-bot @IliasP91 Thank you Ilias!

holopin-bot[bot] commented 1 day ago

Congratulations @IliasP91, the maintainer of this repository has issued you a badge! Here it is: https://holopin.io/claim/cm4895ufb00340cmbfubhpwrf

This badge can only be claimed by you, so make sure that your GitHub account is linked to your Holopin account. You can manage those preferences here: https://holopin.io/account. Or if you're new to Holopin, you can simply sign up with GitHub, which will do the trick!