RestAction should implement Publisher
See original GitHub issueIssue
Issue Type
- Bug Report
- Feature Request
Description
I have been using Project Reactor for a few months now. Libraries like these make it easy to work with async operations in a functional way. Lately, I figured that JDA’s RestAction
can be adapted to fit into this API by implementing Publisher
.
A Publisher’s action will only start once it has been subscribed to (similar to rest actions). Multiple subscribers may be added. Subscribers are like event handlers, and handle these 4 events:
onSubscribe(Subscription)
onNext(T)
onError(Throwable)
onComplete()
The problem with this is that the flow API was introduced in Java 9. I am not sure if the JVM allows us to implement an interface which is not loaded (say when running JRE 8).
Documentation:
Issue Analytics
- State:
- Created 5 years ago
- Comments:12 (5 by maintainers)
Top Results From Across the Web
Mastering own Reactive-Streams implementation. Part 1
Through this topic, I will share basics coding steps, pitfalls, and patterns that will be useful for future implementors. In the first part...
Read more >Prior Restraint | The First Amendment Encyclopedia
Prior restraint is a form of censorship that allows the government to review the content of printed materials and prevent their publication.
Read more >Understand the Google Publisher Policies and Google ...
Google Publisher Policy must be fixed. Policy violations are enforced with either "Ad serving disabled" or "Restricted demand". · Google Publisher Restrictions ...
Read more >Publishing and Linking on the Web - W3C
Many content publishers seek to control the use of their content on the ... You must not use our logo to link to...
Read more >Managing Intellectual Property in the Book Publishing Industry
National publishers' association should also be a good source of advice. ... enforce this restriction is this: 'The author may not write another...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
As we are building against java8, this will probably not work then.
And we will very likely stay on 8 for a while (compatibility) and then sometime in the future switch to Java 11. At that point we can consider adding the stuff described in the issue, but currently it won’t work i guess.
The reason we do not want to update is backward compatibility. Considering that we don’t gain a lot of bumping the version while we bring an inconvenience to the userbase is a big influence on the decision that we want to stay java 8 compatible for now.