jamesnetherton opened a new issue, #9528:
URL: https://github.com/apache/camel-quarkus/issues/9528
Since Quarkus 4.0.0, `quarkus-keycloak-admin-resteasy-client` depends on
`org.keycloak:keycloak-admin-client-jackson3` (and transitively
`keycloak-client-common-synced-jackson3`) instead of the Jackson 2 based
`keycloak-admin-client`.
`camel-keycloak` still depends on the Jackson 2 artifacts:
* `org.keycloak:keycloak-admin-client` -> `keycloak-client-common-synced`
* `org.keycloak:keycloak-authz-client` -> `keycloak-client-common-synced`
`keycloak-client-common-synced` and `keycloak-client-common-synced-jackson3`
contain ~430 classes with the same names (split packages). The Jackson 2
variants of the representation classes win on the classpath, but the admin
client now deserializes responses with Jackson 3. For example
`RealmRepresentation.clientProfiles` is a Jackson 2 `JsonNode` in the Jackson 2
jar (vs `org.keycloak.json.RawJsonValue` in the Jackson 3 jar), so fetching a
realm fails:
```
tools.jackson.databind.exc.InvalidDefinitionException: Cannot construct
instance of `com.fasterxml.jackson.databind.JsonNode` (no Creators, like
default constructor, exist): abstract types either need to be mapped to
concrete types, have custom deserializer, or contain additional type information
(through reference chain:
org.keycloak.representations.idm.RealmRepresentation["clientProfiles"])
at
dev.resteasy.providers.jackson.ResteasyJacksonProvider.readFrom(ResteasyJacksonProvider.java:144)
...
at
org.apache.camel.component.keycloak.KeycloakProducer.getRealm(KeycloakProducer.java:485)
```
Most of the `integration-tests/keycloak` tests fail as a result (#9527).
Camel switching to `keycloak-admin-client-jackson3` is necessary, but not
sufficient. There is no Jackson 3 variant of `keycloak-authz-client`, and it
depends on Jackson 2 directly (`ObjectMapper`, `TypeReference`) and on
`org.keycloak.util.JsonSerialization`, which only exists in the Jackson 2
`keycloak-client-common-synced` jar. So the Jackson 2 synced jar cannot simply
be excluded.
Possible resolutions:
* A Jackson 3 variant of `keycloak-authz-client` from Keycloak
* `camel-keycloak` dropping `keycloak-authz-client` and calling the authz
endpoints directly
Until then, the keycloak tests are disabled.
*This issue was generated by an AI agent (Claude Code on behalf of
jamesnetherton) and may contain inaccuracies.*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]