So we've nailed down most of our performance issues (figured out why
caching was off as well). We're seeing that the last call that's
struggling is the whoami call. We see 5k SQL executions for the following
query: 5,111 × select userrolema0_.ROLE_ID as col_0_0_ from
USER_ROLE_MAPPING userrolema0_ where userrolema0_.USER_ID=?
I've put together a gist of the request/response to better highlight what I
believe the issue is. Basically, for every realm and every role the user
has, one query is executed. This data isn't loaded from the cache for some
reason. I'm wondering if for role mapping does it make sense to simply
load all of them for a given user?