如何修复“由org.hibernate.MappingException引起:无法确定org.hibernate.type.PrimitiveByteArrayBlobType的类型”

时间:2019-01-08 10:19:56

标签: hibernate tomcat8

在上下文文件中,我的数据源定义如下:

<bean id="jbpmDataSource" class="org.springframework.jndi.JndiObjectFactoryBean">
    <property name="jndiName" value="java:/comp/env/jdbc/JbpmDataSource" />
</bean>

<bean id="jbpmEmf" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
    <property name="dataSource" ref="jbpmDataSource" />
    <property name="persistenceXmlLocation" value="classpath:META-INF/jbpm-persistence.xml" />
    <property name="persistenceUnitName" value="jbpmPU" />
    <property name="jpaVendorAdapter">
        <bean class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter" />
    </property>
</bean>

tomcat 8的server.xml内部提到了此数据源。启动服务器时,出现异常:

  

原因:org.hibernate.MappingException:无法确定以下表的类型:org.hibernate.type.PrimitiveByteArrayBlobType,在表:ProcessInstanceInfo,

0 个答案:

没有答案