Dashboard > 江南白衣博物馆 > ... > Data Service > DataAccessImplement
  江南白衣博物馆 Log In | Sign Up   View a printable version of the current page.  
  DataAccessImplement
Added by Calvin, last edited by Calvin on 2007-12-16  (view change)
Labels: 
(None)

资料

ORM方案的构成

1.Singleton的Persistence Unit(SessionFactory)

   公共资源存放处:映射元数据,二级对象缓存与查询结果缓存,编译语句缓存,数据库连接池。

2.Per Request的Persitence Context(Session)

   Session资源存放处:会话内对象列表Map<ID,Entity>,已修改对象列表List<entity>。

3.数据访问器

实际执行者:SQL生成器,Resultset处理器,执行者。

4.Cache Manager

   调度一,二级缓存。

ByteCode Enhancement

  • 实现对象直接访问而无需反射。
  • 自动的对象属性修改跟踪。
  • 实现Lazy Field loading。

实现手段

Hibernate对JPA的附加实现(JPA Annotation, JPQL, JPA),让人觉得可以基于它来DIY自己的方案。

hibernate的包

说明
org.hibernate hibernate API
org.hibernate.impl hibernate API实现
org.hibernate.cfg
org.hibernate.mapping
org.hibernate.meta
hibernate定义与元模型定义
org.hibernate.hql
org.hibernate.dialect
org.hibernate.sql
sql生成与数据库语法
org.hibernate.loader 处理resultset,组装为对象
org.hibernate.connection
org.hibernate.jdbc
数据库连接与jdbc执行
org.hibernate.cache 缓存
org.hibernate.transaction 事务
org.hibernate.jmx
org.hibernate.stat
状态监控

Site powered by a free Open Source Project / Non-profit License (more) of Confluence - the Enterprise wiki.
Learn more or evaluate Confluence for your organisation.
Powered by Atlassian Confluence, the Enterprise Wiki. (Version: 2.2.9 Build:#527 2006-09-07) - Bug/feature request - Contact Administrators
Get SpringSide at SourceForge.net. Fast, secure and Free Open Source software downloads