[
https://issues.jboss.org/browse/ELY-1456?page=com.atlassian.jira.plugin.s...
]
Darran Lofthouse commented on ELY-1456:
---------------------------------------
There are two parts to this really: -
# The JDBC SecurityRealm is older than the IdentityCredentials and CachingSecurityRealm,
it does already load the credentials in one go but stores them in a list, it can instead
add them all to IdentityCredentials that can then take over the supports / get / verify
calls.
# Although there is a single principal query it is executed once per credential type
supported and once for the attributes - instead it should be executed once and the
ResultSet re-used for each item being read from the results.
Two same SQL queries seen during one authentication attempt
------------------------------------------------------------
Key: ELY-1456
URL:
https://issues.jboss.org/browse/ELY-1456
Project: WildFly Elytron
Issue Type: Bug
Components: Realms
Affects Versions: 1.2.0.Beta10
Reporter: Martin Choma
Assignee: Darran Lofthouse
Priority: Critical
Fix For: 1.2.0.Beta11
Two same sql queries are performed on authentication attempt using jdbc-realm.
{noformat}
2017-11-29T15:53:32.399596Z 338 Query select password from user where email =
'alberto(a)myapp.com'
2017-11-29T15:53:32.400879Z 338 Query select role, 'Roles' from user_role_auth
where email = 'alberto(a)myapp.com'
2017-11-29T15:53:32.402531Z 338 Query select password from user where email =
'alberto(a)myapp.com'
{noformat}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)