Keycloak migration from 3.4.3 to 11.0.0

I’m trying to update my keycloak which deployed as a pod in Openshift from 3.4.3 to 11.0.0
The upgrade from 3.4.3 to 7.0 goes smoothly and I can login to my services.

But upgrade from 3.4.3 to 11.0 gives me the following error when I try to login to keycloak’s admin console

05:23:49,115 WARN [org.keycloak.services] (default task-2) KC-SERVICES0013: Failed authentication: java.lang.NullPointerException
at org.keycloak.keycloak-services@11.0.0//org.keycloak.theme.DefaultThemeManager.loadTheme(DefaultThemeManager.java:106)

05:23:49,123 ERROR [org.keycloak.services.error.KeycloakErrorHandler] (default task-2) Failed to create error page: java.lang.NullPointerException

05:23:49,123 ERROR [org.keycloak.headers.DefaultSecurityHeadersProvider] (default task-2) MediaType not set on path /auth/realms/XXX/protocol/openid-connect/auth, with response status 500
05:23:49,142 ERROR [io.undertow.request] (default task-2) UT005023: Exception handling request to /auth/realms/XXX/protocol/openid-connect/auth: java.lang.RuntimeException: java.lang.RuntimeException: org.jboss.resteasy.spi.UnhandledException: javax.ws.rs.InternalServerErrorException: HTTP 500 Internal Server Error

The underlying database is postgres.
when I upgrade from 7.0 to 11.0 that also works.

Any help would be appreciated.