Package de.hshannover.dqgui.execution.database.api
Database Abstraction Layer API
-
Interface Summary Interface Description ConnectionHandle<T> A handle for a connection that guarantees the connection is always open.RelationalRepositorySupport This class helps with different SQL dialects for relational databases by supplying implementation dependent queries.
RelationalRepositorySupport returns named prepared statements.
That means instead of writingSELECT * FROM t WHERE name = ?
you would writeSELECT * FROM t WHERE name = :name
RelationalRepositorySupport is used by Engines using the JdbcRepository implementation.
Table, column and parameter names are hard coded and must be used in your implementation.
It is recommended to use this in combination with the subclassYamlConfigurableRelationalRepositorySupport
.
A NoSQL solution would not need to implement this but instead just provide aRepository
andDSLService
implementation.Repository<T> Base type of all database backed repositories. -
Class Summary Class Description DatabaseConnection Abstracts a database connection.DatabaseCredential Represents a common set of credential fields (username, password, database).DatabaseEngine All database engines must extend this base class.
To have the engine loaded they must be in the packagede.hshannover.dqgui.support.database.api
.DatabaseFetcher Database Fetcher Interface.DatabaseSocket Store a socket (host + port).DatabaseTests Some pre-defined database tests and the test result API.DatabaseTests.DatabaseTestResult Database tests must return this.EngineIdentifier An EngineIdentifier uniquely identifies an engine to theEngineManager
.
The identifier will always be converted to an upper case string.
It can be queries as a lower case string tho as it will be converted automatically.EngineLanguage An engine language uniquely identifies the language the database system uses.EngineManager Handles database engine registration.RelationalRepositorySupport.KeyHandle A key handle allows to abstract key creation.
Some databases allow auto incrementing keys with the query, others require you to supply your own key by querying a series first.
The KeyHandle allows to abstract this away so the higher layer always gets the correct primary key.Repository.ValidationReport Reports if the repository fulfills the required schema.YamlConfigurableRelationalRepositorySupport ARelationalRepositorySupport
that is configurable through YAML and results thus in less boiler plate. -
Enum Summary Enum Description DatabaseSocket.HostFormat Possible host formatsRelationalRepositorySupport.KeyType