[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-2047) NullPointerException in org.jboss.seam.contexts.BusinessProcessContext.getNamesFromContext()

Jo Geraerts (JIRA) jira-events at lists.jboss.org
Fri Oct 5 07:59:03 EDT 2007


NullPointerException in org.jboss.seam.contexts.BusinessProcessContext.getNamesFromContext()
--------------------------------------------------------------------------------------------

                 Key: JBSEAM-2047
                 URL: http://jira.jboss.com/jira/browse/JBSEAM-2047
             Project: JBoss Seam
          Issue Type: Bug
          Components: BPM, Core
    Affects Versions: 2.0.0.CR1
         Environment: jboss 4.2.1.GA, postgresql db
Linux pc0236 2.6.17-12-generic #2 SMP Sun Sep 23 22:56:28 UTC 2007 i686 GNU/Linux

            Reporter: Jo Geraerts


When creating a JBPM Process Instance with @CreateProcess but no Attributes are outjected to the BusinessProcessContext a NullPointerException will be thrown at you. Example Code:

@Stateless
@Name("inklessProcessManager")
public class InklessProcessManagerImpl implements InklessProcessManager {

	@CreateProcess(definition="inkless")
	@TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)
	public void startProcess() {
	}

}

Stacktrace:
Caused by: java.lang.NullPointerException
	at org.jboss.seam.contexts.BusinessProcessContext.getNamesFromContext(BusinessProcessContext.java:1
15)
	at org.jboss.seam.contexts.BusinessProcessContext.getNames(BusinessProcessContext.java:97)
	at org.jboss.seam.contexts.Contexts.destroy(Contexts.java:241)
	at org.jboss.seam.contexts.Contexts.flushAndDestroyContexts(Contexts.java:356)



Code that works:

@Stateless
@Name("inklessProcessManager")
@Interceptors(SeamInterceptor.class)
public class InklessProcessManagerImpl implements InklessProcessManager {

	@Out(scope=ScopeType.BUSINESS_PROCESS, value="foo") Integer someThing;

	@CreateProcess(definition="inkless")
	public void startProcess() {
		someThing=new Integer(5);
	}

}




-- 
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