我很难找到迁移文档。我正在使用sping 3.0.5和hibernate 3.4。将应用程序上下文配置迁移到Spring 3.1和Hibernate 4.0
我迁移到最新版本候选人:春季3.1和Hibernate 4.0
我能够修改我的类没有问题,但对Hibernate的应用程序上下文是给我的问题,因为我还没有看到任何例子如何配置它。
具体做法是:
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSource"/>
<property name="mappingResources">
<list>...</list>
</property>
<property name="hibernateProperties">
<props>
...
<prop key="hibernate.connection.provider_class">org.hibernate.service.jdbc.connections.internal.C3P0ConnectionProvider</prop>
<prop key="hibernate.cache.provider_class">????</prop>
...
</props>
</property>
</bean>
显然性质dataSource
,mappingResources
和hibernateProperties
不再存在,我不那么肯定要放什么hibernate.connection.provider_class
和hibernate.cache.provider_class
。
而且我不断收到:
Caused by: java.lang.ClassNotFoundException: org.hibernate.engine.FilterDefinition
在应用程序启动。
https://jira.springsource.org/browse/SPR-8096?page=com.atlassian.jira.plugin.system.issuetabpanels%3achangehistory-tabpanel – craftsman