Core components of sqltoy-orm
5.6The sqltoy-orm module consists of several key architectural components:
- SqlToyDaoSupport: The base class for developers to extend; it integrates all database operation methods.
- LightDao: A shortcut DAO for use within services to focus on business logic.
- DialectFactory: A factory that selects the appropriate database dialect implementation (e.g., Oracle, MySQL) based on the current connection.
- SqlToyContext: The core configuration and exchange area of the framework; Spring configurations primarily target this context.
- EntityManager: Managed within
SqlToyContext, it maps POJO objects to database tables using@SqlToyEntityannotations. - ScriptLoader: A parser for SQL configuration files, which must follow the
*.sql.xmlnaming convention. - TranslateManager: Manages cache translation XML files and implementations. It defaults to a high-efficiency local Ehcache implementation.
- ShardingStrategy: Manages database sharding and partitioning. In version 4.x+, strategies are managed dynamically via Spring definitions.