This is because I use some features that only ORM 2.0 supported. What
is the version of hibernate entitymanager you are using? I use the
latest 3.6.x and have got no errors. This seems that your hibernate
version expects a fix version of 1.0.
2010/11/26, ramram <ramram858(a)gmail.com>:
Hi all,
I have the following exception on the server intialization after applying
the orm.xml files
18:57:25,144 SEVERE [XMLHelper] Error parsing XML: XML InputStream(5)
cvc-complex-type.3.1: Value '2.0' of attribute 'version' of element
'entity-mappings' is not valid w
ith respect to the corresponding attribute use. Attribute 'version' has a
fixed value of '1.0'.
18:57:25,149 ERROR [STDERR] javax.persistence.PersistenceException:
[PersistenceUnit: org.drools.task] Error while reading JPA XML file:
META-INF/task/Attachment.orm.xml
18:57:25,150 ERROR [STDERR] at
org.hibernate.ejb.Ejb3Configuration.addClassesToSessionFactory(Ejb3Configuration.java:909)
18:57:25,150 ERROR [STDERR] at
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:758)
18:57:25,153 ERROR [STDERR] at
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:191)
18:57:25,156 ERROR [STDERR] at
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:253)
18:57:25,159 ERROR [STDERR] at
org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:125)
18:57:25,163 ERROR [STDERR] at
javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:52)
18:57:25,172 ERROR [STDERR] at
javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:34)
18:57:25,176 ERROR [STDERR] at
com.fp.common.view.util.InitializeTaskService.start(InitializeTaskService.java:39)
18:57:25,178 ERROR [STDERR] at
com.fp.common.view.util.InitializeTaskService.startTaskService(InitializeTaskService.java:30)
18:57:25,186 ERROR [STDERR] at
com.fp.common.view.util.ServerInitialization.contextInitialized(ServerInitialization.java:22)
18:57:25,189 ERROR [STDERR] at
org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3910)
18:57:25,193 ERROR [STDERR] at
org.apache.catalina.core.StandardContext.start(StandardContext.java:4393)
18:57:25,195 ERROR [STDERR] at
org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:310)
18:57:25,204 ERROR [STDERR] at
org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:142)
18:57:25,207 ERROR [STDERR] at
org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:461)
18:57:25,210 ERROR [STDERR] at
org.jboss.web.deployers.WebModule.startModule(WebModule.java:118)
18:57:25,213 ERROR [STDERR] at
org.jboss.web.deployers.WebModule.start(WebModule.java:97)
persistence.xml
<persistence-unit name="org.drools.task"
transaction-type="RESOURCE_LOCAL">
<provider>org.hibernate.ejb.HibernatePersistence</provider>
<jta-data-source>java:/comp/env/worDS</jta-data-source>
<mapping-file>META-INF/orm.xml</mapping-file>
<mapping-file>META-INF/task/Attachment.orm.xml</mapping-file> <!--
ATTACHMENT -->
<mapping-file>META-INF/task/BooleanExpression.orm.xml</mapping-file>
<mapping-file>META-INF/task/Comment.orm.xml</mapping-file>
<mapping-file>META-INF/task/Content.orm.xml</mapping-file>
<mapping-file>META-INF/task/Deadline.orm.xml</mapping-file>
<mapping-file>META-INF/task/Deadlines.orm.xml</mapping-file>
<mapping-file>META-INF/task/Delegation.orm.xml</mapping-file>
<mapping-file>META-INF/task/EmailNotification.orm.xml</mapping-file>
<mapping-file>META-INF/task/EmailNotificationHeader.orm.xml</mapping-file>
<mapping-file>META-INF/task/Escalation.orm.xml</mapping-file>
<mapping-file>META-INF/task/Group.orm.xml</mapping-file>
<mapping-file>META-INF/task/I18NText.orm.xml</mapping-file>
<mapping-file>META-INF/task/Notification.orm.xml</mapping-file>
<mapping-file>META-INF/task/OnAllSubTasksEndParentEndStrategy.orm.xml</mapping-file>
<mapping-file>META-INF/task/OnParentAbortAllSubTasksEndStrategy.orm.xml</mapping-file>
<mapping-file>META-INF/task/OrganizationalEntity.orm.xml</mapping-file>
<mapping-file>META-INF/task/PeopleAssignments.orm.xml</mapping-file>
<mapping-file>META-INF/task/Reassignment.orm.xml</mapping-file>
<mapping-file>META-INF/task/SubTasksStrategy.orm.xml</mapping-file>
<mapping-file>META-INF/task/Task.orm.xml</mapping-file> <!-- Task
-->
<mapping-file>META-INF/task/TaskData.orm.xml</mapping-file> <!-- Task
Data
-->
<mapping-file>META-INF/task/User.orm.xml</mapping-file>
<properties>
<property name="hibernate.dialect"
value="org.hibernate.dialect.OracleDialect"/>
<property name="hibernate.connection.autocommit"
value="false" />
<property name="hibernate.hbm2ddl.auto"
value="create-drop" />
<property name="hibernate.max_fetch_depth"
value="3"/>
<property name="hibernate.show_sql" value="true"
/>
<!-- TRANSACTION FOR JBOSS -->
<property name="hibernate.transaction.manager_lookup_class"
value="org.hibernate.transaction.JBossTransactionManagerLookup" />
<!-- TRANSACTION FOR TOMCAT>
<property name="hibernate.transaction.manager_lookup_class"
value="org.hibernate.transaction.BTMTransactionManagerLookup"/ -->
</properties>
</persistence-unit>
and I used the orm files provided
I tried it only for the Attachment and the table were created succesfully if
the version is 1.0 in orm file but then i got one-to-many error in the
Deadlines
any ideas
Regards,
Ram
--
View this message in context:
http://drools-java-rules-engine.46999.n3.nabble.com/Drools-Human-Task-Ser...
Sent from the Drools - User mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users