Class JdbcSignInMethodsLock
java.lang.Object
com.irurueta.authserver.authorization.infrastructure.persistence.social.JdbcSignInMethodsLock
- All Implemented Interfaces:
SignInMethodsLock
SignInMethodsLock over a PostgreSQL transaction-level advisory lock on the account: it opens no transaction
and holds the lock until the caller's ends, so the removals of the sign-in methods of one account (unlinking an
identity, unbinding a certificate) run one after the other and each counts what the previous one left.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.springframework.jdbc.core.simple.JdbcClientJDBC client used to run the statement.private static final StringStatement taking the advisory lock of an account, released when the caller's transaction ends.(package private) static final intFirst key of the advisory locks of the accounts, which keeps them apart from every other advisory lock. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
SIGN_IN_METHODS_LOCK_NAMESPACE
static final int SIGN_IN_METHODS_LOCK_NAMESPACEFirst key of the advisory locks of the accounts, which keeps them apart from every other advisory lock.- See Also:
-
LOCK_ACCOUNT
Statement taking the advisory lock of an account, released when the caller's transaction ends.- See Also:
-
jdbcClient
private final org.springframework.jdbc.core.simple.JdbcClient jdbcClientJDBC client used to run the statement.
-
-
Constructor Details
-
JdbcSignInMethodsLock
public JdbcSignInMethodsLock()
-
-
Method Details
-
lock
- Specified by:
lockin interfaceSignInMethodsLock
-