Package org.tentackle.dbms
package org.tentackle.dbms
Low-level persistence layer implementation.
Provides the Db session, the generic persistence engine
AbstractDbObject, connection management, id sources, statement wrappers,
transactions, batching, modification tracking, and modification logging.
-
ClassDescriptionAbstractDbObject<P extends AbstractDbObject<P>>A persistent low-level database object.AbstractDbOperation<P extends AbstractDbOperation<P>>An
AbstractDbOperationprovides methods that are not part ofAbstractDbObjects and is associated with aDb-session.Base implementation forIdSources.Base class for a transaction.Connection Manager for local connections.A provider for a connection manager.
Implemented by applications that provide the default connection manager for new local sessions, for example, server applications using anMpxConnectionManager.A persistence session.Maintains batches of prepared statements.Statement and its data used in batched transactions.Factory for class variables.
Replaced by a PDO-aware factory in the persistence layer.Utilities for diagnostic purposes with persistence extensions.Session factory for Db instances.Modification information per table.The master serial and the generation of the modification table.The modification tracker for the tentackle persistence layer.The persistence layer's modification types.
The external character values are stored in the modification log, seeModificationLog.DbObjectClassVariables<P extends AbstractDbObject<P>>Holds static class variables for classes derived from AbstractDbObject.
This is a "singleton per class".A reference to a class that is referencing this class.DbOperationClassVariables<P extends AbstractDbOperation<P>>Holds static class variables for classes derived from AbstractDbOperation.Implementation of a session pool.Slot of aDbPoolholding a pooled session.
Closed sessions are removed from the pool.Default implementation for a remote session factory.Local transaction status.Factory for transactions.
Collects duration statistics and monitors transactions.A unique handle to reference an object within aDbTransaction.Persistence utility methods.
This singleton is provided mainly to allow a clean separation between the lower- and higher level persistence layer implementations.
It is replaced byPersistenceUtilitiesfrom the tentackle-persistence module to make it PDO-aware.The default implementation of a connection manager.
Each session will get its own physical connection.DefaultIdSourceConfigurator.Default implementation of a modification log factory.The default reconnection policy.
The policy will reconnect with a fixed interval.Callback of a session enlisted in a global transaction.
Registered by the session viaGlobalTransactionSupport.enlist(Db, GlobalTransactionListener)and invoked by the transaction manager when the global transaction completes.Determines how a local session takes part in global (distributed) transactions.Bridge between local sessions and a global (distributed) transaction manager, such as JTA.Source of ID numbers.Configurator for anIdSource.Runtime exception thrown when anIdSourcebecomes empty.
Provided for application-specific id sources with a limited range of IDs.Runtime exception thrown for id source failures.A visitor to ignore duplicates within a persistence operation.
Used to avoid duplicate key errors, for example, if components are referenced more than once within the same root entity.A JDBC connection managed by theConnectionManager.Maintains a set of all open managed connections.
The connections are held by a weak reference, and the set is cleaned up once a minute.
Optionally, ifManagedConnection.isConnectionKeepAliveEnabled(), idle connections withManagedConnection.isConnectionVerificationNecessary()== truewill be verified (via dummy SELECTs) periodically to prevent premature closing by the database backend.Logging for object modifications.TheModificationLogfactory.Serializer for theModificationLog'sobjectDatafield.Counter to track modifications for a class/table.
The ModificationTracker maintains a list of ModificationTally-objects, one for each tracked name.The modification type.
The default types are defined inDbModificationType, which is an enum.Factory for modification types.
Basically maps character values to modification types.Multiplexing connection manager.Implementation of aMultiUserSessionPool.
The pool is actually a pool ofDbPools, one for eachSessionInfo.AnIdSourceto create unique object IDs.AnIdSourceto create unique object IDs from a database sequence.A reflective visitor to add application-specific functionality to persistence operations.A wrapper for prepared statements.
Will catch and report SQLExceptions and keep track of being used only once afterDb.getPreparedStatement(StatementKey, boolean, int, int, SqlSupplier).A database query.Adapter for aRemoteDbSession.
This hides the remote session and allows extensions independent of the concrete remote session implementation.Factory for remote sessions.Remote transaction status.
Sent from the server to the client.A section of columns within the result set.A subset of the columns returned by aResultSetWrapper.A wrapper forResultSets.Backend-specific SQL-code supplier.History of statement execution.A statement id.The statement key.Statement statistics collector.Statistics result for SQL statements.
Optionally extendsStatisticsResultby fetch duration for the result set and result set size.Statement trace exception.
Not a real exception.On-demand SQL statement tracer.
Primarily used to trace usage of certain SQL statements on demand at runtime.A wrapper for sql statements.
Will catch and report SQLExceptions and keep track of being used only once afterDb.createStatement().Keeps a backlog of expiration sets.Keeps track of all committed or rolled back deletions, updates, or inserts in memory.
Applies to entities with a tableserial.
When loading the tableserials from the database viaAbstractDbObject.selectExpiredTableSerials(long, long), gaps will be present for deletions, rolled back updates, or inserts and PDOs updated more than once since the last query.Transaction statistics collector.Statistics result for transactions.
ExtendsStatisticsResultby the number of statements and rollbacks.