[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-08 Thread qzhengyy
After some debugging I found the cause of the problem my self. In components.xml you need to configure managed-persistence-context and also in persistence.xml you need to set jboss.entity.manager.factory.jndi.name property for your database. I try to learn seam from the hotel booking

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-08 Thread petemuir
Reference Manual wrote : The Seam Application Framework only works with Seam-managed persistence contexts. By default, the components will look for a persistence context named entityManager. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044018#4044018 Reply

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-08 Thread qzhengyy
That sentence make sense now after all the trouble I have been through. However, for a beginner, that sentence alone probably will not have much help initially. It would be more helpful if it states that you have to this and that or refer to the corresponding sections. Otherwise its become

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-08 Thread petemuir
I updated the SeamProblemsFAQ to cover this in more depth - a more suitable place I think. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4044096#4044096 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4044096

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-07 Thread petemuir
Show your components.xml View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4043764#4043764 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4043764 ___ jboss-user mailing list

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-05 Thread petemuir
You've got an NPE in you own code. Fix it. At least show the code that gives the NPE! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4043428#4043428 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4043428

[jboss-user] [JBoss Seam] - Re: Help: problem with EntityHome

2007-05-05 Thread qzhengyy
Here is the code | public class FooHome extends EntityHomeFoo { | @In EntityManage em | @Transactional | public String persist() { | getEntityManager().joinTransaction(); | getEntityManager().persist( getInstance() ); | getEntityManager().flush(); |