[
https://jira.jboss.org/jira/browse/JBSEAM-3977?page=com.atlassian.jira.pl...
]
Julien Kronegg updated JBSEAM-3977:
-----------------------------------
Description:
Generating entities with seam-gen produce an error when the table specified in the
seam-gen.reveng.xml file has a composite key:
freemarker.core.InvalidReferenceException: Expression
property.value.identifierGeneratorStrategy is undefined on line 2, column 75 in
pojo/GetPropertyAnnotation.ftl
This is because the composite key has null identifier, see
https://jira.jboss.org/jira/browse/JBSEAM-562
We've found references for that problem in
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4013107
and in
http://opensource.atlassian.com/projects/hibernate/browse/HBX-1004
Interestingly, we could not reproduce the problem using Seam 2.0.0.GA.
One method to correct that issue is to guard the expression in *.ftl files by something
like: property.value.identifierGeneratorStrategy?exists
However, since Seam 2.0.0.GA .ftl files do not have such guards, it must be another way to
correct the problem.
Note that the problem is the same for table or views without identifier because Hibernate
generates a composite id with all the columns.
was:
Generating entities with seam-gen produce an error when the table specified in the
seam-gen.reveng.xml file has a composite key:
freemarker.core.InvalidReferenceException: Expression
property.value.identifierGeneratorStrategy is undefined on line 2, column 75 in
pojo/GetPropertyAnnotation.ftl
This is because the composite key has null identifier, see
https://jira.jboss.org/jira/browse/JBSEAM-562
We've found references for that problem in
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4013107
and in
http://opensource.atlassian.com/projects/hibernate/browse/HBX-1004
Interestingly, we could not reproduce the problem using Seam 2.0.0.GA.
One method to correct that issue is to guard the expression in *.ftl files by something
like: property.value.identifierGeneratorStrategy?exists
However, since Seam 2.0.0.GA .ftl files do not have such guards, it must be another way to
correct the problem
Seam-gen generate-entities does not work for tables with composite
key
----------------------------------------------------------------------
Key: JBSEAM-3977
URL:
https://jira.jboss.org/jira/browse/JBSEAM-3977
Project: Seam
Issue Type: Bug
Components: Tools
Affects Versions: 2.1.1.GA
Environment: DB2
Reporter: Julien Kronegg
Generating entities with seam-gen produce an error when the table specified in the
seam-gen.reveng.xml file has a composite key:
freemarker.core.InvalidReferenceException: Expression
property.value.identifierGeneratorStrategy is undefined on line 2, column 75 in
pojo/GetPropertyAnnotation.ftl
This is because the composite key has null identifier, see
https://jira.jboss.org/jira/browse/JBSEAM-562
We've found references for that problem in
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4013107
and in
http://opensource.atlassian.com/projects/hibernate/browse/HBX-1004
Interestingly, we could not reproduce the problem using Seam 2.0.0.GA.
One method to correct that issue is to guard the expression in *.ftl files by something
like: property.value.identifierGeneratorStrategy?exists
However, since Seam 2.0.0.GA .ftl files do not have such guards, it must be another way
to correct the problem.
Note that the problem is the same for table or views without identifier because Hibernate
generates a composite id with all the columns.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira