How to import existing bpmn file into the modeler?

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2010 04:58 AM
I have an existing BPMN file created from scratch, which works fine in the engine.
How can I import this file into the modeler?
How can I import this file into the modeler?
Labels:
- Labels:
-
Archive
13 REPLIES 13
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-05-2014 05:26 AM
Hi Fred,
Can you help me to resolve the problem.
Thanks
George
Can you help me to resolve the problem.
Thanks
George
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-06-2014 04:52 AM
If you want to import a file into the MODELER, you need DI-information. There is no auto-layouting going on there. Deploying such a process to the engine itself (using either REST or java API) should work just fine. If you want to edit the process in the modeller, you'll have to run it through the auto-layout module first. See http://stacktrace.be/blog/2013/03/dynamic-process-creation-and-deployment-in-100-lines/ - instead of making a model in Java, you just need to deploy the bpmn20.xml, get the Model pogo from it and run it through the auto-layout…
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-07-2014 06:35 AM
Thanks Frederick,
I ran the following code with activiti 5.16
try
{
ProcessEngine processEngine = ProcessEngineConfiguration.createProcessEngineConfigurationFromResource(CONFIG_FILE).buildProcessEngine();
RepositoryService repositoryService = processEngine.getRepositoryService();
Deployment deployment = repositoryService.createDeployment()
.addClasspathResource("InitialProjectPlan.bpmn20.xml")
.disableBpmnValidation()
.disableSchemaValidation()
.deploy();
System.out.println("Name >>" + deployment.getName() + "ID >> " + deployment.getId());
}
catch(Exception ex)
{
ex.printStackTrace();
}
I have used disableBpmnValidation() and disableSchemaValidation() to pass thru deployment . otherwise it is not allowing to deploy through this code. I have attached Initial Project Plan.bpmn20.xml . ran this with isExecutable="true". After this it was allowing to deploy because not able to find the import type.
Following is the error
org.activiti.engine.ActivitiException: Could not import item of type http://www.omg.org/spec/BPMN/20100524/MODELorg.activiti.engine.ActivitiException: Could not import item of type http://www.
omg.org/spec/BPMN/20100524/MODEL
at org.activiti.engine.impl.bpmn.parser.BpmnParse.createImports(BpmnPars
e.java:303)
at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java
:227)
at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeploy
er.java:112)
=============
So I commented all the import lines and tried to deploy . Now I was able to deploy and it is loaded in the process definitions
But diagram is not displayed and not able to edit the model because the Button is disabled.
1) Where you able to deploy the attached file(without bpmndi xml tags) through the code and see the diagram and able to edit the model?
Please help me in this regard to solve the problem
Thanks In Advance
George
I ran the following code with activiti 5.16
try
{
ProcessEngine processEngine = ProcessEngineConfiguration.createProcessEngineConfigurationFromResource(CONFIG_FILE).buildProcessEngine();
RepositoryService repositoryService = processEngine.getRepositoryService();
Deployment deployment = repositoryService.createDeployment()
.addClasspathResource("InitialProjectPlan.bpmn20.xml")
.disableBpmnValidation()
.disableSchemaValidation()
.deploy();
System.out.println("Name >>" + deployment.getName() + "ID >> " + deployment.getId());
}
catch(Exception ex)
{
ex.printStackTrace();
}
I have used disableBpmnValidation() and disableSchemaValidation() to pass thru deployment . otherwise it is not allowing to deploy through this code. I have attached Initial Project Plan.bpmn20.xml . ran this with isExecutable="true". After this it was allowing to deploy because not able to find the import type.
Following is the error
org.activiti.engine.ActivitiException: Could not import item of type http://www.omg.org/spec/BPMN/20100524/MODELorg.activiti.engine.ActivitiException: Could not import item of type http://www.
omg.org/spec/BPMN/20100524/MODEL
at org.activiti.engine.impl.bpmn.parser.BpmnParse.createImports(BpmnPars
e.java:303)
at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java
:227)
at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeploy
er.java:112)
=============
So I commented all the import lines and tried to deploy . Now I was able to deploy and it is loaded in the process definitions
But diagram is not displayed and not able to edit the model because the Button is disabled.
1) Where you able to deploy the attached file(without bpmndi xml tags) through the code and see the diagram and able to edit the model?
Please help me in this regard to solve the problem
Thanks In Advance
George
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-20-2014 03:25 AM
Hi Frederik,
Can you help me on this. Please verify whether code is correct.
Thanks in advance
George
Can you help me on this. Please verify whether code is correct.
Thanks in advance
George
