-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed
Labels
Description
Describe the bug
It seems that disable-default-mapper
for the rest client only works when you map the endpoint's return type with a Response
or RestResponse
. All other options don't work.
Example:
@Path("/api/fruit")
@RegisterRestClient(configKey = "fruitivy", baseUrl = "https://www.fruityvice.com")
public interface FruitivyDirectClient {
@GET
@Path("/{name}")
Response findByName(String name); // ----------> disable-default-mapper works
@GET
@Path("/{name}")
RestResponse<Fruit> findByName2(String name); // ----------> disable-default-mapper works
@GET
@Path("/{name}")
Fruit findByName3(String name); // ----------> disable-default-mapper does not work it throws an error
}
Expected behavior
the disable-default-mapper
should work for any return type.
Actual behavior
No response
How to Reproduce?
set quarkus.rest-client."fruitivy".disable-default-mapper=true
and then call:
var response = this.client.findByName3("banana2");
this code should return null, but it throws an exception
Output of uname -a
or ver
No response
Output of java -version
21
Quarkus version or git rev
3.28.2
Build tool (ie. output of mvnw --version
or gradlew --version
)
Maven
Additional information
No response