Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.0.3
-
Fix Version/s: 1.0.4
-
Component/s: Persistence
-
Labels:None
-
Environment:mac os x 10.5, java 1.5
Description
Peter L figured this out –
It appears that if you set the logging level to "debug" – and use an enum within your data model, you get an NPE exception / stack trace at :
...
Caused by: java.lang.NullPointerException
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.logCascadeMapping(GrailsDomainBinder.java:1713)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.setCascadeBehaviour(GrailsDomainBinder.java:1702)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.bindProperty(GrailsDomainBinder.java:1650)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.createProperty(GrailsDomainBinder.java:1464)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.createClassProperties(GrailsDomainBinder.java:1277)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.bindRootPersistentClassCommonValues(GrailsDomainBinder.java:1152)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.bindRoot(GrailsDomainBinder.java:927)
at org.codehaus.groovy.grails.orm.hibernate.cfg.GrailsDomainBinder.bindClass(GrailsDomainBinder.java:839)
–
If you set it to "info" level or higher, no problems. Of course, when you DO get the stack trace, etc. it doesn't correctly generate the field in the DB or persist it, etc.
Appears that some "debug information" isn't there for logging if the field type winds up being an enum ..
Issue Links
| This issue relates to: | ||||
| GRAILS-3201 | Add columnDefinition (or sqlType) to GORM DSL |
|
|
|
Activity
- All
- Comments
- Work Log
- History
- Activity
- Git Commits