marcospereirampj / python-keycloak

MIT License
704 stars 297 forks source link

Perf issues with the function KeycloakAdmin.get_client_id() #510

Closed aurelien-alet closed 5 months ago

aurelien-alet commented 8 months ago

Hello, We are using python-keycloak lib to manage our keycloak instance, thanks for your work ! On some of our realms, we have more than 4000 clients, and getting a client id with the function KeycloakAdmin.get_client_id() takes about a minute. Rather than requesting all the clients of a realm and filter them on code side, it's possible tu use the endpoint admin/realms/{realm-name}/clients?clientId={client-id} with a clientId query param. It will result in better perfomances on big realms. Thanks for your help Aurélien Alet