I've upgrade Roo to 1.1.2 and run my script to create an App using GAE Persistence. I still have to make fixes in my Tour_Roo_JavaBean.aj to get it to compile. This entity has many-to-many relationships implemented as Set with some of my other entities. There are 2 problems.
- HashSet is used in the Set<Key> declarations but not imported.
- The getters and setters try to create (instanciate) new Set<...>() rather than new HashSet<...>().
After fixing these, I still have a problem when I try to Run on Server (STS 2.5.2). I'm getting this exception:
Code:
2011-03-03 06:16:45,347 [main] ERROR org.springframework.web.context.ContextLoader - Context initialization failed
org.springframework.transaction.CannotCreateTransactionException: Could not open JPA EntityManager for transaction; nested exception is java.lang.NullPointerException: No API environment is registered for this thread.
at org.springframework.orm.jpa.JpaTransactionManager.doBegin(JpaTransactionManager.java:382)
at org.springframework.transaction.support.AbstractPlatformTransactionManager.getTransaction(AbstractPlatformTransactionManager.java:371)
at org.springframework.transaction.interceptor.TransactionAspectSupport.createTransactionIfNecessary(TransactionAspectSupport.java:335)
at org.springframework.transaction.interceptor.TransactionAspectSupport.createTransactionIfNecessary(TransactionAspectSupport.java:273)
at org.springframework.transaction.aspectj.AbstractTransactionAspect.ajc$before$org_springframework_transaction_aspectj_AbstractTransactionAspect$1$2a73e96c(AbstractTransactionAspect.aj:63)
at com.getrolling.cis.InsertTestData.init(InsertTestData.java:33)
at com.getrolling.cis.InsertTestData.onApplicationEvent(InsertTestData.java:28)
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:97)
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:303)
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:911)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:428)
...
Any help?
Dan