-
Notifications
You must be signed in to change notification settings - Fork 223
Adding raw event subscription alongside CloudEvent subscription #1617
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
base: master
Are you sure you want to change the base?
Adding raw event subscription alongside CloudEvent subscription #1617
Conversation
|
@dapr/approvers-java-sdk and @dapr/maintainers-java-sdk could you please take a look and approve. This has been requested by @alicejgibbons. One thing I want to mention, I am not really fond of the new name An alternative would be to rename the old method to |
Another possibility is naming the new one |
|
Regardinging renaming, can we have multiple overloads to subscribeToEvents? |
@alicejgibbons unfortunately we can not have the same overloads that depends just on generic type. @alicejgibbons as I was thinking more and more. Instead of coming up with different APIs, customers can leverage Flux via a simple It is an additional step, but it is not too bad. Please let me know your thoughts. |
sdk-tests/src/test/java/io/dapr/it/pubsub/stream/PubSubStreamIT.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Artur Ciocanu <[email protected]>
Signed-off-by: Artur Ciocanu <[email protected]>
e5dc0ec
b4601a8 to
e5dc0ec
Compare
|
@alicejgibbons @cicoyle @javier-aliaga I went a different route, since this is not released yet, I think a breaking change is OK. The final API is the following: There are different examples in the integrations tests for raw payload and CloudEvent. Let me know your thoughts. |
Signed-off-by: Artur Ciocanu <[email protected]>
Looks good to me, it feels more simple. |
cicoyle
left a comment
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.
Can you review the tests bc CI is failing with:
Error: Errors:
Error: PubSubStreamIT.testPubSub:115 » Runtime org.opentest4j.AssertionFailedError: expected: <100> but was: <95>
Error: PubSubStreamIT.testPubSubCloudEvent:207 » Runtime org.opentest4j.AssertionFailedError: expected: <100> but was: <0>
Signed-off-by: Artur Ciocanu <[email protected]>
Signed-off-by: Artur Ciocanu <[email protected]>
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #1617 +/- ##
============================================
+ Coverage 76.91% 78.93% +2.02%
- Complexity 1592 2083 +491
============================================
Files 145 227 +82
Lines 4843 6277 +1434
Branches 562 692 +130
============================================
+ Hits 3725 4955 +1230
- Misses 821 970 +149
- Partials 297 352 +55 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@cicoyle @alicejgibbons and @javier-aliaga the PR is looking good and the build is 🟢. Could you please take another look. Thank you. |
Description
Adding raw event subscription alongside CloudEvent subscription
Issue reference
We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.
Please reference the issue this PR will close: #1616
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list: