Support `StreamingOutput` or document alternative in RESTEasy Reactive
See original GitHub issueDescription
I have seen this issue discussed in both #26473 and #15891, but it still remains unclear to me how to do the equivalent of StreamingOutput
with RESTEasy Reactive. If StreamingOutput
cannot be directly supported as return type for blocking endpoints, I think it would make sense if the documentation provided some clear guidance on how to do this, including how to set headers (e.g. Content-Disposition
as in the linked discussion), as RESTEasy Reactive is being promoted as the JAX-RS implementation of choice.
As in the discussion #26473 we also have a blocking endpoint which returns the output of some third-party library and having to first store that as a temporary file is IMO not very nice.
Implementation ideas
No response
Issue Analytics
- State:
- Created a year ago
- Comments:14 (12 by maintainers)
Top Results From Across the Web
Announcing RESTEasy Reactive - Quarkus
It gives the Quarkus and RESTEasy teams great pleasure to announce that RESTEasy Reactive integration in Quarkus has landed in the main ...
Read more >RESTEasy JAX-RS - JBoss.org
Alternatively, Jackson's documentation suggest doing the same in a servlet filter; ... RESTEasy supports more reactive types than the specification.
Read more >RestEasy reactive with javax.ws.rs.core.StreamingOutput
Hello,. While working on moving to rest easy reactive I ran into an issue with using javax.ws.rs.core.StreamingOutput to stream ...
Read more >StreamingOutput (Java(TM) EE 7 Specification APIs)
Interface StreamingOutput. public interface StreamingOutput ... This is a lightweight alternative to a MessageBodyWriter . Since: 1.0; Author: Paul Sandoz, ...
Read more >Jersey 2.37 User Guide - GitHub Pages
Implementing Support for Custom Reactive Libraries (SPI) ... Similarly, in case you spot any errors in the Jersey documentation, please report them by ......
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 Free
Top 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
I will have to do some more testing, but I think this may do the trick and would allow my endpoints to transparently use
StreamingOutput
:This workaround is a lifesaver! Been troubleshoothing for hours why I got some weird result back from the StreamingOutput (when processing it showed the classname$1… instead of the filecontent). Adding this
StreamingOutputMessageBodyWriter
does the trick.