-
Notifications
You must be signed in to change notification settings - Fork 63
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
Add a spring-cloud-stream-binder for Amazon SQS #8
Comments
This would be extremely useful, especially if it could also support sending to a SNS topic and consuming from a SQS queue. |
Indeed, we can configure SQS queue to subscriber to the SNS topic. But how about if we will just have a Kinesis Binder and get a gain of the whole bunch of possibilities? |
any update? |
I would love for AWS SQS to be supported. SQS support would be a big help for our project. |
I wonder why not Kinesis: https://github.com/spring-cloud/spring-cloud-stream-binder-aws-kinesis ? The SQS doesn't fit fully the SCSt communication model. There is no publish-subscribe semantics, no partition and offset management etc. |
I would say SNS can achieve similar pub-sub semantics and combined with SQS can make the SNS topics durable, in a sense. Also, most of my use cases don't have a need for partitioning or offset management but find SCS without those to still be useful. This could be because I don't understand the best scenarios for those features though. Edit: Sorry spoke too soon. After re-reading the SCS docs about partitioning I believe partitioning can be achieved by using separate SQS queues for each partition and subscribing the queues to the SNS topic in use. |
I see your point, @tvrmsmith . Thank you for sharing! Unfortunately we don't have resources to jump to this area. Contribution is welcome of course! |
I've done some work on this but haven't found the time to get it into a working state. Also, I just want to thank you guys for making Spring so awesome. |
Ha-ha! No, that is big thanks to you, Community. Without your comprehensive feedback and valuable contributions the Spring wouldn't be so awesome! 😉 |
I've done some work putting together a project for this, but am running into an issue where the SQS API only accepts Strings for their message payloads. This would mean the default MessageConverters would have to be extended to send String representations (or keep the original String representations instead of converting to byte[]). I think this would work, but that would mean the project wouldn't conform to https://docs.spring.io/spring-cloud-stream/docs/current/reference/htmlsingle/#mime-types-and-java-types which seems quite fundamental and thus maybe SQS just doesn't fit? @artembilan if you disagree I can continue down that route and finish up an initial version of this binder. |
If you want to know my opinion, then I don't see reason in this binder since we have a Kinesis one. Anyway even
|
Right, but in the case of |
Shouldn't the content type be indicating to the inbound channel how to decode/parse the message? |
@artembilan As far as I understand, Kinesis doesn't support consumed-once semantics. |
@chrylis , Well, you know we ensure that with the Anyway I don't mind against the AWS SQS+SNS Binder. Just we don't have resources right now to jump into this feature. Thank you for feedback! |
Hi all, |
I've started working on SQS binder: https://github.com/maciejwalkowiak/spring-cloud-stream-binder-sqs. |
Looks great at a glance! A couple remarks:
Thanks so far for the effort! |
Thank you @artembilan for quick feedback! Sure, there's a lot of things to be done there. Thanks for hints how to deal with customer groups. |
After making it work well with SQS only I started implementing customer group support with SNS and I am having one issue perhaps @artembilan you can guide me. I need to register two extra converters in the The code in on the branch here: maciejwalkowiak/spring-cloud-stream-binder-sqs#8 |
first of all it is called Your Anyway this is not what I would recommend to do. Such a converter in the global To fix it properly I would suggest to have a |
Too much business podcasts 🤦♂️ @artembilan, thank you for advice, adding interceptor to |
In case you found yourself in this thread from Google, we have built Spring Cloud Stream binders for SQS and SNS. You can find them over here: We've been using them in production without issues since about half a year now. They also support the SNS fanout pattern (i.e. you publish to SNS and have multiple queues subscribed to it, which are then consumed by another service). |
This is great @mKeRix, i just added them to the front page - https://spring.io/projects/spring-cloud-stream |
@mKeRix I saw you had archived the repo. Do you aware if there are any plans to impl such binder officially SCS? |
We were also planning on using Spring Cloud Stream with SNS (with a future switch to MSK) |
Missed the comment from a couple months ago, sorry about that. Unfortunately, I left that company about 2 years ago, so I wasn’t involved with the decision to archive. I believe that the team maintaining the repo chose to re-architect their workloads away from Spring Cloud Stream and therefore didn’t feel like they had the capacity to maintain these binders anymore. I could create a fork on my private account, but I don‘t use Spring regularly anymore (in fact, haven’t touched Java since I switched jobs). So I don’t think that I would be a good steward for the project, since I couldn’t do any dogfooding and am also out of touch with what updates from all the related projects would change. If there is anyone that feels like they could take up maintainership of these projects (maybe because you would like to use them?) let me know and I can try to broker whatever is needed to move the library ownership. |
From @mstine on September 19, 2015 0:58
Seems like this should be relatively easy by leveraging the SQS support in Spring Cloud AWS. We'd like to use this to support spring-cloud/spring-cloud-netflix#545, so that we can use SQS when running Spring Cloud Services on PWS.
Copied from original issue: spring-cloud/spring-cloud-stream#135
The text was updated successfully, but these errors were encountered: