-
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
Default parameter conversion for REST Client Reactive #27430
Comments
You added a link to a Zulip discussion, please make sure the description of the issue is comprehensive and doesn't require accessing Zulip.
|
Thanks. |
So, what we're trying to cover here is the following use case: public interface FormClient {
@POST
@Consumes(MediaType.APPLICATION_FORM_URLENCODED)
@Produces(MediaType.TEXT_PLAIN)
String formWithTypes(@FormParam("text") String text, // Already working
@FormParam("number") int number, // not working
@FormParam("param") @PartType(MediaType.APPLICATION_JSON) Person person); // not working
} And the right solution should be to reuse the message readers to parse integer or any other type (like the Person class) to String, plus taking into account the media type defined in the Is this right? |
Sorry, I don't think this is enough. I didn't have time to review your PR or I would have mentioned it, sorry :( I tweaked your code in #27526 as well, since I had to have a workaround at the time I worked on the PR, and I did it by implementing But this issue is larger, because it's also about the other cases, using Anyway, reopening. |
Description
At the moment, REST Client Reactive, supports only String parameters or parameters that have registered custom parameter converters.
Anything else results in
On the server side, we convert parameters according to the JAXRS spec:
We should support similar conversions on the client side (but the client side needs to convert from some type, e.g. primitive, to string).
CC @FroMage @Sgitario @geoand
Origin: https://quarkusio.zulipchat.com/#narrow/stream/187038-dev/topic/RESTEasy.20Reactive.20client.20ParamConverter
Implementation ideas
No response
The text was updated successfully, but these errors were encountered: