Fixed SonarCloud smells:
Level blocker:
- Removed 'dbType' field from CreateIndexTransaction (is in Transaction)
- Removed unused 'dbSystem' from AnalysisContainer
This class is no longer required since responsibility of storage of
sessions now lies with the caller and it's functionality can be
achieved by not saving the returned optional.
- Removed TableSqlParser, not used
- Removed Select#from that used Column
- Removed Update#values that used Column
- Removed Insert#values that used Column
- Added a Database Access Lock object
- Access log lets OperationCriticalTransactions through
- Transactions skip query access log check
- executeTransaction returns a Future to allow easier synchronization
- ServerInfo waits for the server to be registered. This could lead
to issues if a new server is registering to old database. It should
not be too big of an issue since no patches need to be applied
on first enable of the database.
- Added database states: CLOSED <-> INITIALIZING -> OPEN -> CLOSED
These two changes allow restricting queries to the database until the
database has properly initialized (Schema is in correct format)
- Removed SQLDB as a Patch class variable
Tests use Guava direct thread executor on the database to reduce
concurrency issues during tests. Another option would be to wait for
each transaction.
- Removed SaveOperations#session
- Removed DBSystem dependency from SessionCache, so SessionCache does
not need to be called from async thread. (SessionCache does not save,
responsibility now with the caller)
- Refactored UsersTable#getSavedUUIDs to a query
- Removed #getRegisterDates, #updateName, #getAllTimesKicked,
#getUUIDsAndNamesByID - not used
- Refactored UserInfoTable#getSavedUUIDs to a query
- Removed UserInfoTable#getServerUserInfo - not used