MSSQL 2019 supported?

Hi!

We are checking the supported databases table and only appear MSSQL 2016.

¿Is MSSQL 2019 officially supported?

Thanks in advance.
Carlos

Currect keycloak version ships with com.microsoft.sqlserver.mssql-jdbc-11.2.0.jre11.jar, which is the newest one.

Thanks for the answer.

What I would like to know, is regarding to the deployment database support. I found ths information " Configuring the database - Keycloak" and the only version supported is MSSQL2016. So my question is:

Could We deploy keycloak on MsSQL2019 DB schema? is it already tested?

Thanks.

I am running Keycloak 18.0.2 (Wildfly distribution, on Ubuntu 20.04, Java 11), JDBC driver 10.2.0 with MS SQL Server 2019, without problems, but a few simple settings are necessary to get it work smoothly:

  • use simple SQL Server authentication, not integrated Windows security, especially when running Keycloak under Linux (Linux, Java, Kerberos, pain…)
  • enable “Snapshot Isolation” on database level in MS SQL Server (reduces deadlock ocurrence)
  • use sendStringParametersAsUnicode=false flag in JDBC connection string (very important, boosts performance by an order of magnitude, reduces deadlock ocurrence to zero in my case)
  • if you have full access to the SQL Server, the global setting “threshold for parallelism” tuned to a value of 25-50 is recommended, but the two settings above are much more important to reduce deadlocks
  • as far as I know, MS SQL Server has no XA transaction by default, so on Quarkus switch transaction-xa-enabled=false (default value is true)

The most expensive operation on my setup is the automated creation and IdP-linking of users (no special roles, no groups but up to 200 imported attribute values) when they do their first login through an upstream external IdP (SAML). So I made a multithreaded test to create/read/update dummy users in parallel through the Keycloak admin API. This worked without problems and it was significantly faster than necessary for production.

And yes, official Keycloak documentation on MS SQL server is… improvable.

Thank you so much for the information that you are sharing, is more than enough and it is appreciated.

I hope this kind of post help and cheer up the Keycloak team to update de documentation.

Best regards.