Next: LRU Image Cache Cleanup
Up: Common Services
Previous: Connection Pool
Contents
HID web app uses a code-generated Data Access Object (DAO) based simple object-to-relational mapping
strategy with query by example (QBE) as the main retrieval mechanism. Even though QBE is
not a very powerful approach, it was adequate enough for most of the data maintenance related
queries. Multi-table complex queries are build by handcoded query builders using an abstract syntax
tree (AST) representation of the user query translated to native SQL from AST representation. Also
there is a query by criteria (QBC) service for single table complex queries as provided by the
implementation of the IQueryProcessor interface. The AbstractQueryProcessor provides
the common QBC functionality. The OracleQueryProcessor and PostgresQueryProcessor
provide Oracle and Postgres specific QBC functionality, respectively.
Transparent multiple database support for DAOs is provided by using abstract factory design pattern.
The DAOFactory class creates the corresponding DAO for the corresponding database type for the
provided database ID and returns the DAO interface instead of the actual implementation.
Next: LRU Image Cache Cleanup
Up: Common Services
Previous: Connection Pool
Contents
Burak Ozyurt
2008-03-28