8000 Not possible to sync latest keycloak-admin-client to keycloak-client by mposolda · Pull Request #47950 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Not possible to sync latest keycloak-admin-client to keycloak-client - #47950

Merged
vmuzikar merged 1 commit into
keycloak:mainfrom
mposolda:47889-main
Apr 13, 2026
Merged

vmuzikar merged 1 commit into
keycloak:mainfrom
mposolda:47889-main

Conversation

@mposolda
@mposolda mposolda commented Apr 10, 2026 •
Copy link
Copy Markdown
Contributor

closes #47889

As described in #47889, it is not possible to sync keycloak-admin-client in keycloak-clients .

The keycloak-admin-client-tests now declares dependency on keycloak-admin-v2-rest . That module contains new Client V2 API and is compatible only with Java 17 (admin client is compatible with Java 11 and that's the version, which is supposed to work for keycloak-admin-client in the keycloak-client repository ). Due to this, it is not possible to sync the current keycloak-admin-client-tests to the keycloak-admin-client in keycloak-client repository.

Approaches I considered to address the issue:

  1. Make sure that it is possible to sync keycloak-admin-client without dependency on keycloak-admin-v2-rest .

  2. Make sure that keycloak-admin-client is synced to keycloak-client repository together with all new stuff (class Clients as well as the library keycloak-admin-v2-rest ).

I used approach (1) as:

  • keycloak-clients is supposed to be Java 11, but keycloak-admin-v2-rest has compatibility with Java 17

  • Official admin client version keycloak-admin-client from keycloak-clients is supposed to preserve backwards compatibility. But I guess the API introduced for Clients V2 is still under development and there are not any backwards compatibility requirements yet as it is experimental feature?

This PR does only that method Keycloak.clients() uses reflection to create Clients instance, so that class org.keycloak.admin.client.wrapper.Clients is not directly imported in Keycloak class. Hence it is possible to sync Keycloak class in the keycloak-client without syncing also class Clients and whole keycloak-admin-v2-rest library.

@rmartinc rmartinc left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mposolda! For me it's OK, you are just removing the dep and not using at all the new Clients class. Don't know if you want to also ask the cloud team for this.

@michalvavrik
Copy link
Copy Markdown
Member

Thanks @mposolda! For me it's OK, you are just removing the dep and not using at all the new Clients class. Don't know if you want to also ask the cloud team for this.

@shawkins had a go on this issue as well, please let him review as well, thanks

@michalvavrik
michalvavrik requested a review from shawkins April 13, 2026 14:23
@vmuzikar vmuzikar left a comment •
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mposolda Thank you for the PR. This works for me but rather just as a temporary workaround. It's not really something we'd want users to use. It should be possible to include the Client v2 module back again once #47874 is merged.

@shawkins shawkins left a comment
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works for me as a workaround for now, and we'll continue to delay #45803

@vmuzikar
vmuzikar merged commit 15ede46 into keycloak:main Apr 13, 2026
85 checks passed
mposolda added a commit to mposolda/keycloak that referenced this pull request Apr 13, 2026
…eycloak#47950)

closes keycloak#47889

Signed-off-by: mposolda <mposolda@gmail.com>
(cherry picked from commit 15ede46)
mposolda added a commit that referenced this pull request Apr 14, 2026
…47950)

closes #47889

Signed-off-by: mposolda <mposolda@gmail.com>
(cherry picked from commit 15ede46)
@stianst stianst mentioned this pull request Jun 1, 2026
sashyo pushed a commit to tide-foundation/keycloak-IGA that referenced this pull request Jul 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Not possible to sync latest keycloak-admin-client to keycloak-client

5 participants

0