[jBPM] - JBPM exception : no process definition with key
by Samrat Roy
Samrat Roy [http://community.jboss.org/people/whizkid.samrat] created the discussion
"JBPM exception : no process definition with key"
To view the discussion, visit: http://community.jboss.org/message/593004#593004
--------------------------------------------------------------
Hi I am new to jBpm , though I have run a couple of examples and i am comfortable with the idea.
I am trying to build a spring web application with jBpm 4.4 and I have defined my process defintion jpdl files. The problem is :
I have made a Spring bean in the application Context as :
<bean id="jbpmRepositoryUtil" class="com.canon.common.util.JbpmRepositoryUtil">
<constructor-arg>
<value>jpdl/LeaveApply.jpdl.xml</value>
</constructor-arg>
<constructor-arg>
<value>jpdl/LeaveDB_bal_Status.jpdl.xml</value>
</constructor-arg>
<constructor-arg>
<value>jpdl/ApproverFlow.jpdl.xml</value>
</constructor-arg>
<constructor-arg>
<ref bean ="repositoryService"/>
</constructor-arg>
</bean>
This bean deploys three Jpdl files at the server Startup (jboss 4.2) . Like:
public JbpmRepositoryUtil (String mainJpdlPath,String subProcessPath,String approverPath ,RepositoryService repositoryService){
mainFlowId = repositoryService.createDeployment().addResourceFromClasspath(mainJpdlPath).deploy();
dbSubProcessId = repositoryService.createDeployment().addResourceFromClasspath(approverPath).deploy();
approverFlowId = repositoryService.createDeployment().addResourceFromClasspath(subProcessPath).deploy();
}
I have run the server in debug mode an confirmed that the method is being hit.
But when I try to start a process instance in my service class like :
ProcessInstance processInstance = executionService.startProcessInstanceByKey("LeaveApply",variables);
I get the following error :
org.jbpm.api.JbpmException: no process definition with key 'LeaveApply'
at org.jbpm.pvm.internal.cmd.StartProcessInstanceInLatestCmd.execute(StartProcessInstanceInLatestCmd.java:58)
at org.jbpm.pvm.internal.cmd.StartProcessInstanceInLatestCmd.execute(StartProcessInstanceInLatestCmd.java:36)
at org.jbpm.pvm.internal.svc.DefaultCommandService.execute(DefaultCommandService.java:42)
at org.jbpm.pvm.internal.tx.SpringCommandCallback.doInTransaction(SpringCommandCallback.java:45)
.....
Naming isnt an issue because if i copy the createDeployment method to the service class just before trying to create a PI it works just fine .. but according to my understanding I should be deploying the jpdl just once and create ProcessInstance as and when needed. So copying to the service class is a bad idea !
HELP !
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/593004#593004]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
15 years
[jBPM] - How to retry blocked node instances?
by luka kama
luka kama [http://community.jboss.org/people/lukakama] created the discussion
"How to retry blocked node instances?"
To view the discussion, visit: http://community.jboss.org/message/592980#592980
--------------------------------------------------------------
Hi,
I'm trying to embed jBPM 5 inside a standalone application, using a DB for persistence. While testing some processes with a custom work item, i got some runtime exception trying to simulate an asynchronous work item completion. The result is that, now, I have some process stored as in active status with pending work items that i'm trying to resume, but, looking inside API, I can't figure out how to retry the blocked note instance or work item.
Someone know how to resume such processes re-executing active nodes or work items through API?
Thanks,
Luca.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/592980#592980]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
15 years
[EJB3] - SAXException in persistence.xml..
by Joseph Hwang
Joseph Hwang [http://community.jboss.org/people/aupres] created the discussion
"SAXException in persistence.xml.."
To view the discussion, visit: http://community.jboss.org/message/592383#592383
--------------------------------------------------------------
JBOSS : jboss 5.0.0.GA
JDK : JDK 5.0
IDE : Eclipse 3.4
DB :MSSQL Server 2008
OS : Windows Server 2008
To get EntityManeger, insert code like below
@PersistenceContext (unitName="myHome")
EntityManager em;
and put persistence.xml file into META-INF folder of jar
persistence.xml is written below
<?xml version="1.0" encoding="UTF-8"?>
<persistence>
<persistence-unit name="MyHome">
<jta-data-source>java:/MSSQLDS</jta-data-source>
<class>com.obci.ejb3.Members</class>
<properties>
<property name="hibernate.show_sql">true</property>
<property name="org.hibernate.hbm2ddl">update</property>
</properties>
</persistence-unit>
</persistence>
But Exception occurs when jboss starts. Logs are
Error installing to Parse: name=vfsfile:/C:/jboss-5.0.0.GA/server/default/deploy/EJBLoginTest.jar/ state=Not Installed mode=Manual requiredState=Parse
org.jboss.deployers.spi.DeploymentException: Error creating managed object for vfsfile:/C:/jboss-5.0.0.GA/server/default/deploy/EJBLoginTest.jar/
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:337)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:297)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:269)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.deploy(AbstractParsingDeployerWithOutput.java:230)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1598)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1062)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:545)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.loadProfile(ProfileServiceBootstrap.java:304)
at org.jboss.system.server.profileservice.ProfileServiceBootstrap.start(ProfileServiceBootstrap.java:205)
at org.jboss.bootstrap.AbstractServerImpl.start(AbstractServerImpl.java:405)
at org.jboss.Main.boot(Main.java:209)
at org.jboss.Main$1.run(Main.java:547)
at java.lang.Thread.run(Unknown Source)
Caused by: org.jboss.xb.binding.JBossXBException: Failed to parse source: Failed to resolve schema nsURI= location=persistence
at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:203)
at org.jboss.xb.binding.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:168)
at org.jboss.deployers.vfs.spi.deployer.JBossXBDeployerHelper.parse(JBossXBDeployerHelper.java:199)
at org.jboss.deployers.vfs.spi.deployer.JBossXBDeployerHelper.parse(JBossXBDeployerHelper.java:170)
at org.jboss.deployers.vfs.spi.deployer.SchemaResolverDeployer.parse(SchemaResolverDeployer.java:132)
at org.jboss.deployers.vfs.spi.deployer.SchemaResolverDeployer.parse(SchemaResolverDeployer.java:118)
at org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer.parseAndInit(AbstractVFSParsingDeployer.java:256)
at org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer.parse(AbstractVFSParsingDeployer.java:188)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:323)
... 22 more
Caused by: org.jboss.xb.binding.JBossXBRuntimeException: Failed to resolve schema nsURI= location=persistence
at org.jboss.xb.binding.sunday.unmarshalling.SundayContentHandler.startElement(SundayContentHandler.java:313)
at org.jboss.xb.binding.parser.sax.SaxJBossXBParser$DelegatingContentHandler.startElement(SaxJBossXBParser.java:401)
at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Source)
at org.apache.xerces.xinclude.XIncludeHandler.startElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.jboss.xb.binding.parser.sax.SaxJBossXBParser.parse(SaxJBossXBParser.java:199)
I need your advice. Thanks in advance...
Best Regards.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/592383#592383]
Start a new discussion in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
15 years
[EJB3] - Re: javax.naming.NameNotFoundException in remote client
by Antoine Brun
Antoine Brun [http://community.jboss.org/people/abr] created the discussion
"Re: javax.naming.NameNotFoundException in remote client"
To view the discussion, visit: http://community.jboss.org/message/592960#592960
--------------------------------------------------------------
Hi,
can you see the EJB being deployed and binded in the jboss server traces?
when I deploy my EJB StagingConsoleBean I get:
14/Mar/2011 09:06:42 INFO [SessionSpecContainer:296] Starting jboss.j2ee:ear=ubi-api.ear,jar=ubi-api-ejb.jar,name=StagingConsoleBean,service=EJB3
14/Mar/2011 09:06:42 INFO [EJBContainer:296] STARTED EJB: com.ubiqube.api.ejb.stagingConsole.StagingConsoleBean ejbName: StagingConsoleBean
14/Mar/2011 09:06:42 INFO [JndiSessionRegistrarBase:296] Binding the following Entries in Global JNDI:
StagingConsoleBean/remote - EJB3.x Default Remote Business Interface
ubi-api/StagingConsoleBean/remote-com.ubiqube.api.interfaces.stagingConsole.StagingConsoleService - EJB3.x Remote Business Interface
*StagingConsoleBean/remote* being the JNDI name I explicitely set with the annotation:
@RemoteBinding(jndiBinding = "StagingConsoleBean/remote") on the bean class
Then I use "StagingConsoleBean/remote" for the JNDI lookup
Antoine
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/592960#592960]
Start a new discussion in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
15 years
[EJB3] - Re: javax.naming.NameNotFoundException: MyEjb3 not bound :(
by Pawan Jajara
Pawan Jajara [http://community.jboss.org/people/pawankjajara] created the discussion
"Re: javax.naming.NameNotFoundException: MyEjb3 not bound :("
To view the discussion, visit: http://community.jboss.org/message/592949#592949
--------------------------------------------------------------
Hello Everybody,
I had been trying to solve the bound problem in my EJB application. Here is the list of errors I am getting when trying to build using Apache Ant and JBoss AS Server 6.0
[java] log4j:WARN No appenders could be found for logger (org.jnp.interfaces.TimedSocketFactory).
[java] log4j:WARN Please initialize the log4j system properly.
[java] javax.naming.NameNotFoundException: GeoCMPEEJB not bound
[java] java.lang.NullPointerException
[java] at ejbclient.loadrouteinfo.deleteroutes(loadrouteinfo.java:31)
[java] at ejbclient.loadrouteinfo.main(loadrouteinfo.java:149)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[java] at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
[java] at java.lang.reflect.Method.invoke(Unknown Source)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217)
[java] at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:152)
[java] at org.apache.tools.ant.taskdefs.Java.run(Java.java:771)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:221)
[java] at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java:135)
[java] at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108)
[java] at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
[java] at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
[java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
[java] at java.lang.reflect.Method.invoke(Unknown Source)
[java] at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
[java] at org.apache.tools.ant.Task.perform(Task.java:348)
[java] at org.apache.tools.ant.Target.execute(Target.java:390)
[java] at org.apache.tools.ant.Target.performTasks(Target.java:411)
[java] at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
[java] at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
[java] at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
[java] at org.eclipse.ant.internal.launching.remote.EclipseDefaultExecutor.executeTargets(EclipseDefaultExecutor.java:32)
[java] at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
[java] at org.eclipse.ant.internal.launching.remote.InternalAntRunner.run(InternalAntRunner.java:423)
[java] at org.eclipse.ant.internal.launching.remote.InternalAntRunner.main(InternalAntRunner.java:137)
[java] javax.naming.NameNotFoundException: GeoCMPEEJB not bound
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/592949#592949]
Start a new discussion in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
15 years