awspring / spring-cloud-aws

The New Home for Spring Cloud AWS
http://awspring.io
Apache License 2.0
891 stars 303 forks source link

SnsNotificationMessage variant for EventBridge #1272

Open frjonsen opened 1 week ago

frjonsen commented 1 week ago

Type: Feature

Is your feature request related to a problem? Please describe. In our projects we've opted for EventBridge rather than SNS. EventBridge also has a wrapper, similar to that of SNS, but some different fields. Currently we are unwrapping this message to get the to the actual data in our own in-house framework, but feel that there could be a case for including a variant of the existing SnsNotificationMessage annotation, but for the EventBridge wrapper.

Describe the solution you'd like A new annotation, such as EventBridgeMessage, as well as a corresponding message converter, similar to SnsMessageConverter.

Describe alternatives you've considered Defining a model like record EventBridgeMessage<T>(T detail) { }.

tomazfernandes commented 2 days ago

Hey @frjonsen, yep, I think this does make sense.

If you could provide a prototype PR with an integration test so we can have a clearer notion of how that looks that'd be great.

Thanks!