-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: Newbie problem: EntityManagerHibernateSessionFactory not bou
PostPosted: Tue Mar 15, 2005 8:22 am 
Beginner
Beginner

Joined: Mon Mar 14, 2005 4:16 pm
Posts: 27
Hi,

I am doing some tests with EJB3 and Jboss4.0.2RC1. I've installed all the stuff following the install instructions in EJB3_preview4.

I've tried the Calculator example for the tutorial and all is ok. I've tried to inject an EntityManager in the CalculatorBean with the following statement:

Code:
@Inject
private EntityManager manager;


and then a test method (also in the CalculatorBean) wich creates a query using an entity named 'BioUser' from another .ejb3:

Code:
public int test() {
       return manager.createQuery("from BioUser").getResultList().size();
   }


I've tried from the calculator example client to add the method calculator.test()... and this is when the error is raised:

Code:
Exception in thread "main" java.lang.RuntimeException: javax.naming.NameNotFoundException: EntityManagerHibernateSessionFactory not bound
   at org.jboss.ejb3.entity.EntityManagerImpl.getSession(EntityManagerImpl.java:143)
   at org.jboss.ejb3.entity.EntityManagerImpl.createQuery(EntityManagerImpl.java:39)
   at org.jboss.tutorial.stateless.bean.CalculatorBean.test(CalculatorBean.java:30)
...


Thanks in anticipation!

Bruno


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 18, 2005 5:24 am 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
You'd better go in http://www.jboss.org/index.html?module=bb&op=viewforum&f=203.
This is a more appropriate place to talk to JBoss EJB3 implmeentation for now

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 18, 2005 5:35 am 
Beginner
Beginner

Joined: Mon Mar 14, 2005 4:16 pm
Posts: 27
Thanks Emmanuel, I had both forum windows opened when writing the message and I posted to the wrong one.
If somebody is intereseted, I've got an answer in the jboss forum.

Regards,

Bruno


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.