[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1415) SMPC in a SFSB throws a nullpointer

Moshe Immerman (JIRA) jira-events at lists.jboss.org
Thu Jun 7 08:23:14 EDT 2007


SMPC in a SFSB throws a  nullpointer
------------------------------------

                 Key: JBSEAM-1415
                 URL: http://jira.jboss.com/jira/browse/JBSEAM-1415
             Project: JBoss Seam
          Issue Type: Bug
    Affects Versions: 1.2.1.GA
         Environment: IceFaces DR#5, JBoss Seam 1.2.1GA,  Jboss AS 4.0.5 
            Reporter: Moshe Immerman


When injecting the Seam Managed Persistence Context in a Stateful Session bean, it does not get injected and subsequent references to the entityManager throws a NullPointer Exception.


The below code demonstrated the problem, When @Stateful is removed everything works fine.


@Name("forward")
@Scope(value=ScopeType.CONVERSATION)
@Stateful
public class Forward  implements   ForwardLocal{
	@In
	private EntityManager em;

        List<User> users;
	

	@Create
	public void init() {
		 users= em.createQuery(" from User as u").getResultList();
		
	}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list