-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Quarkus Multipart not working for multi layer applications #23986
Comments
/cc @FroMage, @geoand, @stuartwdouglas |
This is about the Multipart support in the Reactive REST Client, so cc'ing @michalszynkiewicz |
the only thing that didn't work for me in the reproducer with the current version was receiving small files, I fixed it with the linked pull request. |
I just checked and the version you were using didn't support multipart responses at all, we support them since 2.7: #22855 |
@michalszynkiewicz thanks. Will upgrade to 2.7.2.FINAL from 2.5.0.FINAL, test and will revert. |
@git4rputuval please note that until a new version that contains #24014 is released it will be failing on small files (smaller than 16KB) |
Thanks @michalszynkiewicz … I was struggling to understand why the sample project kept failing. Once I added the code to push the file size to above 16KB, it worked. So now I have to wait till #24014 is resolved. Any timeline you have in mind to get this fixed. We have a release in April 2022. |
…active fixes quarkusio#23986 (cherry picked from commit 8efb2f7)
Describe the bug
We have an export-import microservice design that exports and imports data, one microservice component per family of entities.
This microservice design imports & exports using rest reactive design. And it works perfectly without any issues.
Requirement
But now we have a different requirement. We have a module that provides the user a page to select the list of microservices that needs to be exported and/or imported. After selecting multiple microservices and clicking on "Export" button, a zip file will be generated that contains the exported file of all the microservices selected on the page.
Design
Since all the components already have the export import function, all I have to do is created a separate service that will do the following.
UniJoin.Builder<CommonAccountTypeXMLDto> builder = Uni.join().builder(); builder.joinAll().andFailFast();
Issue
The service uses Rest Reactive Client to connect to the individual microservices. So I use the 'Rest Reactive Client with Multipart' approach. But it gives an error.
022-02-25 16:13:11,174 ERROR [org.jbo.res.rea.com.cor.AbstractResteasyReactiveContext] (executor-thread-0) Request failed: javax.ws.rs.ProcessingException: Response could not be mapped to type class com.company.services.exim.client.DownloadFormData
Expected behavior
A Quarkus microservice using Rest Reactive Client fails with an exception when it connects with a Quarkus Rest Reactive Service. Though the requirement is for Multipart bodies, it fails for normal bodies too.
In summary, a Quarkus service calling another quarkus service using Rest Reactive Client fails.
Actual behavior
Quarkus Rest Reactive Client should be able to connect to a Quarkus Rest Service.
How to Reproduce?
Steps to reproduce the issue:
Error occurs:
022-02-25 16:13:11,174 ERROR [org.jbo.res.rea.com.cor.AbstractResteasyReactiveContext] (executor-thread-0) Request failed: javax.ws.rs.ProcessingException: **** could not be mapped to type class ***.***.***.*******
Output of
uname -a
orver
Microsoft Windows [Version 10.0.19044.1526]
Output of
java -version
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.11+9-LTS-194, mixed mode)
GraalVM version (if different from Java)
No response
Quarkus version or git rev
2.5.0.FINAL
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.8.3 (ff8e977a158738155dc465c6a97ffaf31982d739)
Additional information
Error.txt
raj-quarkus-multipart.zip
Sample
For the sake of simplicity, I am attaching a single project that contains a server project and a client project.
Also attached is the error text. You can run the project and reproduce the same error. Use postman to call the function.
Please help find the actual cause of the error. Thanks!
The text was updated successfully, but these errors were encountered: