-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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 StreamingFileUpload.asInputStream #9787
Conversation
Repurpose some existing publisher->stream code to implement StreamingFileUpload.asInputStream. This will be useful for micronaut-projects/micronaut-object-storage#113
actually i'm going to make PublisherAsBlocking less abstract again. |
* @return An {@link InputStream} that reads this file's contents | ||
* @since 4.2.0 | ||
*/ | ||
default InputStream asInputStream() { |
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.
add @NonNull
to return type
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.
annotate with @Blocking
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.
the method itself is not blocking even though the stream might be. should it still be annotated as such?
http-netty/src/main/java/io/micronaut/http/netty/PublisherAsBlocking.java
Show resolved
Hide resolved
SonarCloud Quality Gate failed. 0 Bugs 69.8% Coverage Catch issues before they fail your Quality Gate with our IDE extension SonarLint |
Repurpose some existing publisher->stream code to implement StreamingFileUpload.asInputStream. This will be useful for micronaut-projects/micronaut-object-storage#113