Quantcast
Channel: Camunda BPM Team Blog
Viewing all 143 articles
Browse latest View live

camunda BPM 7.0.0-alpha6 released

$
0
0

Today we announce the release of camunda BPM 7.0.0-alpha6. In this release we focused on visualizing process instance state on top of a rendered diagram in cockpit. We added the following features: 
41 issues were closed. See the complete release notes in Jira

Process Instance Detail View in Cockpit

In cockpit we started work on the process instance detail view. This view will allow you to drill down into a single process instance and explore it's running and completed activities as well as the variables, tasks, jobs...  associated. To open the process instance detail view, you can select a process definition on the start page (dashboard), navigate the the process definition page and select a process instance from the instance list.



In the initial increment we focused on rendering the process diagram (using our Javascript-based BPMN renderer) and visualizing the currently active activity instances on this diagram:

Multi Instance
Embedded Subprocess and Scoping
Compensation
Parallel Join

How does it work?

In order to visualize these diagrams, camunda Cockpit creates two client side models:
  • The process definition object model: is a Javascript object model representation of the parsed BPMN 2.0 process definition XML. The model has the form of a tree structured in accordance with the BPMN 2.0 semantic process model. We merge the BPMN Diagram Interchange information into this tree.
  • The process instance object model: is a Javascript object model representation of the current process instance state. The model has the form of a tree and is constructed from the Activity Instance Tree (new feature) retrieved from the process engine. 
Both the process definition tree and the process instance tree have the same structure (ie. activity instances in the process instance tree are at the same level as their corresponding activity definitions in the object model.). In order to achive this, we had to make a couple of additions in the core process engine (PVM-Process Virtual Machine). 

Visualizing the Activity Instance Tree

We will visualize the Activity Instance tree in the process instance detail view on the left hand side:


See CAM-719

Read more about the activity instance tree in this follow up blog post.


Introducing an Activity Instance Model to the core Process Engine

$
0
0

(this post was originally part of the 7.0.0-alpha6 release blog post but later extracted into an own post).

In 7.0.0-alpha6 we introduced the concept of activity instances and the activity instance tree to the core process engine. This post explains the motivation and gives some insight into the internal implementation.

Why do we need an Activity Instance Tree?

The activity instance tree contains a node for each activity that is currently active in the process instance. Some activity instances are scopes (such as Embedded Subprocesses). Such scope activity instance may have child activity instances:
Activity Instance Tree and Scopes
So far so good. But is that not the execution tree provided by the process engine? To some extent yes, but not in  all cases. There are numerous cases where the execution tree is not aligned with activity scoping in BPMN 2.0.

Scoping vs. Concurrency

The process engine uses the concept of a "child execution" both for scoping and for concurrency. If a non-concurrent execution reaches a parallel gateway, it will stay there and concurrent child executions are spawned for each outgoing sequence flow. The effect is that the child executions are nested below an inactive execution waiting in the parallel gateway (fork). This concept is an internal implementation detail and not aligned with the BPMN 2.0 specification and usually very hard to understand for new users of the process engine:
In the execution tree (left hand side) you will see an inactive scope execution waiting in the parallel gateway (even though the process instance has already completed that activity and is now executing the service tasks). The executions executing the service tasks are nested below the inactive scope execution waiting in the fork gateway. In the activity instance tree (right hand side), this execution is not visible. 
In the activity instance tree, the root node in the activity instance tree represents the process instance itself (ie. the instance of the process definition activity) and its children represent active activity instances for both service tasks.

Another example is Parallel Multi Instance. Consider the following examples: 
1) Single parallel multi instance task:


2) Multi instance subprocess:

The additonal executions in the execution trees on the left hand side are needed for internal process engine reasons. In cockpit we want to visualize the activity instance tree which is easier to understand and more aligned with BPMN 2.0. 

Execution Tree Compacting and Optimization

A second reason for introducing the activity instance tree is that the process engine compacts and optimizes the execution tree at runtime. Consider the example of a parallel gateway with two usertasks. Initially both T1 and T2 are active. In the execution tree we will see the inactive concurrent root execution waiting at the parallel gateway and two child executions, one for each task. The activity instance tree has the same structure but the root node corresponds to the process instance itself and is not waiting in the parallel gateway. After the task T2 is completed, the process engine will compact the execution tree, prune the execution for T1 and replace it with the root execution. If the execution T1 references variables or tasks they are moved to the root execution. The activity instance tree look different: it still contains an activity instance for T1 and for the process definition itself.  
Execution Tee compacting

A ramification of this behavior is that in the execution tree there is no concept of "activity instance identity". There is no unique identifier representing an instance of an activity. In general, it is not guaranteed that the same execution that enters an activity instance will be the same execution that completes it. In the example above T1 is started by an execution with Id=2 and ended by an execution with Id=1.

(This is why in general you should never use execution IDs for message correlation, BTW!!!)

In cockpit we want to allow users to select activity instances and explore their details (variables, tasks ...). If we used the execution IDs the following behavior could occur: the user selects T1 and we write the execution id to the url. While he is looking at the details, T2 is completed and the execution tree is compacted by the process engine. Now the user types F5 (refresh) in the browser. He gets an error since the execution he previously selected does not exist anymore even though the Task is still active. Fail!
(Even worse: he could send the effectively-non-deep-link to a colleague.)

Unifying the model for History and Execution

The third reason for adding the activity instance tree to the process engine is that it is better aligned with the way the process engine history works. In the process engine history we always had the concept of historic activity instances. Aligning history and runtime tree structures allows us to use the same client-side code in cockpit for visualizing both running an historic activity instances and activities. In addition: cockpit also works if history is turned off.

How is the Activity Instance Tree implemented? 

The activity instance tree is squeezed into the execution tree. We added a new column to the execution table named ACT_INST_ID_: 
New ACT_INST_ID_ column added in Execution table.
It was not necessary changing anything else as far as the database is concerned. The values of all other columns remain untouched and we have the same number of executions as before. 

The activity instance IDs are generated by the Atomic Operations that start/ end activities:
New Atomic Operation Type Hierarchy
There are testcases verifying that activity instance Id generation and activity start / end listener invocation works as expected (ie. an activity instance ID is generated BEFORE the activity START listeners are invoked etc.).

How can I retrieve an Activity Instance Tree?

Currently you can retrieve the activity instance tree only for a whole process instance.

Using the Java API:

ActivityInstance rootActivityInstance = runtimeService.getActivityInstance(pi.getProcessInstanceId());


You can also use the REST API:

GET engine-rest/process-instance/8f72bc9f-d505-11e2-bafa-3c970e140ef1/activity-instances

{
    "id": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
    "parentActivityInstanceId": null,
    "activityId": "executionProcess:1:8ef5c393-d505-11e2-bafa-3c970e140ef1",
    "processInstanceId": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
    "processDefinitionId": "executionProcess:1:8ef5c393-d505-11e2-bafa-3c970e140ef1",
    "childActivityInstances": [
        {
            "id": "SubProcess_1:8f72bca4-d505-11e2-bafa-3c970e140ef1",
            "parentActivityInstanceId": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
            "activityId": "SubProcess_1",
            "processInstanceId": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
            "processDefinitionId": "executionProcess:1:8ef5c393-d505-11e2-bafa-3c970e140ef1",
            "childActivityInstances": [],
            "childTransitionInstances": [
                {
                    "id": "8f72bca9-d505-11e2-bafa-3c970e140ef1",
                    "parentActivityInstanceId": "SubProcess_1:8f72bca4-d505-11e2-bafa-3c970e140ef1",
                    "processInstanceId": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
                    "processDefinitionId": "executionProcess:1:8ef5c393-d505-11e2-bafa-3c970e140ef1",
                    "targetActivityId": "ServiceTask_1",
                    "executionId": "8f72bca9-d505-11e2-bafa-3c970e140ef1"
                },
                {
                    "id": "8f72bcaa-d505-11e2-bafa-3c970e140ef1",
                    "parentActivityInstanceId": "SubProcess_1:8f72bca4-d505-11e2-bafa-3c970e140ef1",
                    "processInstanceId": "8f72bc9f-d505-11e2-bafa-3c970e140ef1",
                    "processDefinitionId": "executionProcess:1:8ef5c393-d505-11e2-bafa-3c970e140ef1",
                    "targetActivityId": "ServiceTask_2",
                    "executionId": "8f72bcaa-d505-11e2-bafa-3c970e140ef1"
                }
            ],
            "executionIds": [
                "8f72bc9f-d505-11e2-bafa-3c970e140ef1"
            ]
        }
    ],
    "childTransitionInstances": [],
    "executionIds": [
        "8f72bc9f-d505-11e2-bafa-3c970e140ef1"
    ]
}

Step by step we will roll out the support for activity instances in public API, add an Activity Instance Query etc.

Will executions be deprecated?

I am not sure yet but my gut feeling is yes. The concept of "Execution" is a proprietary internal process engine concern and will gradually be replaced by the activity instance model. We might go down a road where you can still query for executions but you will in fact get activity instances as result, in order not to break the API. But not before 7.1 or probably 8.0 :)

Announcing the Release Date of camunda BPM 7.0.0 GA

$
0
0
We are proud to announce the major release date of camunda BPM:

7.0.0 GA* on 31.08.2013


 All features will be open source, exept for the IBM Websphere AS distribution.
From that day on, there will also exist the supported enterprise edition of  camunda BPM.
(*General Availability)

Highlights of 7.0.0

  • New webapplication for process monitoring with BPMN 2.0, based on an open plugin infrastructure
  • Faster process engine with asynchronous history, optimized for high load scenarios
  • New embeddable REST API, based on JAX-RS
  • Java Script library for rendering BPMN 2.0 diagrams 
  • Support for: Tomcat, JBoss, Glassfish and IBM Websphere AS
  • Enahnced user management, supporting LDAP and JAAS

Also new in 7.0.0

Fully Java EE 6 compliant process engine, support for message correlation, HTML5 Tasklist for human workflow, a new incident infrastructure in the process engine, lots of bugfixes, lots of helpful documentation.

    Start using camunda BPM today!

    Although still tagged as alpha, our current releases are already considered stable, especially the process engine itself. There are already customers going live with the current alpha5 - we have no worries - but keep in mind that some things might still be subject to change:
    • History (we expect some database changes)
    • Central User Management (will be added)
    • Cockpit (more features will be added; the plugin API might still change)

    Just being the product owner, I will not build any of this stuff myself. The credits go to our team, the contributors and the community.

    Great work, great project!

    camunda BPM 7.0-alpha7 released

    $
    0
    0
    camunda BPM 7.0.0-alpha7 is out now!

    The highlights of this new release are:
    • In Cockpit we worked on the visualization of Process Instances:
      • Incidents of a running process instance will be shown in the corresponding rendered process diagram.
      • The former introduced Activity Instance Tree will be visualized as a tree.
      • Now it is possible to select a BPMN element in the rendered process diagram or to select a activity instance wihtin the activity instance tree. If a single BPMN Element is selected, the corresponding activity instances will also be selected in the tree (and vice versa).
      • Variable instances of the process instance/activity instances will be shown in the view.
    • In Cockpit you can switch between the configured process engines (multi-tenancy).
    • The variable instances can be selected via an introduced Java and REST Api.
    • Support of a further Bpmn 2.0 Element: Link Event.
    • New user guide for Cycle and Tasklist.
    33 issues were closed. See the complete release notes in Jira.

    Visualization of a Process Instance

    The following screencast summarizes all in this release implemented features in camunda Cockpit:




    Support of multi-tenancy in camunda Cockpit

    Due to the possibility to run multiple tenants on the camunda BPM platform you can now switch between the configured process engines in Cockpit to get the process engine specific information.


    Variable Instance query

    Now it is possible to create a variable instance query to get variables instances:
    runtimeService
    .createVariableInstanceQuery()
    .list()
    Furthermore, with the Java Api you are able to query after variables instances for more than one task id, process instance id, execution id and activity instance id at once. For example:
    runtimeService
    .createVariableInstanceQuery()
    .taskId("aTaskId", "anotherTaskId")
    .list
    In the case of the example you will get all variable instances with the task id "aTaskId" and "anotherTaskId". This is also possible with the process instance ids, execution ids and activity instance ids.

    Note: At the moment it is not possible to select variable instance with the type 'bytes'.

    The variable instance query is also exposed via the REST Api.




    camunda BPM camunda BPM 7.0.0-alpha8 released

    $
    0
    0
    Here comes the latest camunda BPM alpha release with the following highlights:

    New features in cockpit webapplication:

    • Greatly improved layout
    • Editing process variables
    • Cancelling a process instance
    • Increment retries for failed jobs
    • Login based on Process Engine Identity Service
    We added a new application called camunda Admin which provides support for
    • Managing users & groups based on the process engine engine identity service
    • Creating an initial user for a process engine
    The REST API was enhanced 
    The Process Engine got smarter
    • Started work on authorization service
    Braking change: the URL for cockpit is now http://localhost:8080/camunda/.

    All in all, 33 issues were closed, including 8 bugfixes. Read the full release notes in JIRA.



    Additions to the Webapps

    Nico Rehwaldt & Roman Smirnov have given cockpit a complete layout overhaul and added a lot of features:

    New Cockpit layout:

    Editing process variables:


    Cancelling Process Instances:

    Increment Job retries

    Selecting a process engine

    Switching to a different application

    The camunda Admin application allows managing Users and Groups

    Started Work on Authorizations:

    We started work on a resource-based authorization system in the process engine:

    The authorization service allows managing Authorizations. Authorizations manage permissions of a given user/group to interact with a given resource.

    Creating an authorization
    An authorization is created between a user/group and a resource. It describes the user/group's permissions to access that resource. An authorization may express different permissions, such as the permission to READ, WRITE, DELTE the resource.

    Granting / revoking permissions
    In order to grant the permission to access a certain resource, an authorization object is created:
     Authorization auth = authorizationService.createNewAuthorization();
    //... configure auth
    authorizationService.saveAuthorization(auth);
    The authorization object can be configured either for a user or a group:
     auth.setUserId("john");
    -OR-
    auth.setGroupId("management");
    and a resource:
     auth.setResource(Resources.USER);
    auth.setResourceId("mary");
    finally the permissions to access that resource can be assigned:
     auth.addPermission(Permissions.READ);
    and the authorization object is saved:
     authorizationService.saveAuthorization(auth);
    As a result, the given user or group will have permission to READ the referenced process definition.


    Checking a permission
    Permissions can be checked using a query:
     authorizationQuery.userId("john")
    .resourceType("processDefinition")
    .resourceId("2313")
    .hasPermission(Permissions.READ)
    .hasPermission(Permissions.WRITE)
    .hasPermission(Permissions.DELETE)
    .list();
    Selects all Authorization objects which provide READ,WRITE,DELETE Permissions for the user "john". 

    In the 7.0 final release, authorizations will work on the Resources USER, GROUP, APPLICATION, AUTHORIZATION. In 7.1 we will extend authorization support to process definitions. 
    (All plans are subject to change :) )

    What's coming up next?

    - Authorizations
    - Many awesome features in cockpit :)

    Prague: history, beer and …camunda BPM

    $
    0
    0

    Yes, fellow BPM-enthusiasts it is time to head to Prague for the camunda BPM community event of the year!

    We are heading across the border and are hosting our first event in a non-German speaking country on Friday, October 18th at the fusion hotel in the great city of Prague.

    You will get the chance to learn more about camunda BPM from the people behind the platform (the whole team will be present!) but also get real-life reports from users.

    There will be plenty of time for open discussion as we are eager to hear your opinions, feedback and suggestions and of course we will take advantage of our surroundings and head out for a few Prague beers afterwards.

    You can find out more and register here.

    For those of you who cannot wait to see what is in store, here is the current agenda (subject to change):

    When?What?Who?
    12.00 - 13.00Registration and chitchat
    13.00 - 13.10Welcome and camunda VisionBernd and Jakob (CEOs)
    13.10 - 13.30camunda BPM Introduction and technical VisionDaniel (Project Lead)
    13.30 - 14.00Latest and greatest from the development teamCore Team
    14.00 - 14.30BREAK
    14.30 - 15.00Real-Life Experience Report: Processes within 1&1
    Starting from jBPM 3, we're closely working with the open-source community to build the next 1&1 Process Platform, supporting our high-volume business processes. Checkout our experience with providing an enterprise software stack based on camunda BPM.
    Mehmet Sürü, 1&1 Internet AG
    15.00 - 15.30Best Practices from our customer projectsConsulting Team
    15.30 - 16.00BREAK
    16.00 - 16.20How do we work?
    How can you contribute?
    How to be part of the camunda BPM community?
    Daniel (Project Lead)
    16.20 - 16.40Contribution spotlights and contribution awardsContributors
    16.40 - 18.00camunda BPM roadmap and next steps, discussion of concrete features / contributionsall - moderated by Robert (Product Owner)
    18.00 - ?End of official event – grab some beers around and dicsuss everything that REALLY mattersall
    03.00Time to think about sleeping

    We look forward to seeing you in Prague in October.

    camunda BPM 7.0.0-alpha9 released

    $
    0
    0
    Today we are happy to announce the next alpha version of camunda BPM. Get it here.

    Highlights of this Release


    cockpit:
    • instance filters added that allow you to filter for business key and variables
    • called process definition tab added
    • called process instances tab added
    admin:
    • administrate users and groups added
    • change group memberships added
    • manage authorizations added
    • assign access rights to cockpit and tasklist added (as part of manage authorizations)
    engine:
    • ability to run process engine in a heterogenous cluster added
    • unique constraint on business key removed (applied to new installations only)
    • #noRetriesLeft to jobQuery added
    • bpmn element throwing message event added
    • bpmn element send task added
    • exception types in error codes to declare business exceptions
    • history performance improved
    • configuration from camunda.cfg.xml file possible (in addition to activity.cfg.xml)

    Breaking changes:

    In total, 80 issues have been addressed including more than 20 bug fixes. Check out the complete list for all the details.

    Thanks to KristinRafael and Clint for contributing to this release through their pull requests. 
    And thanks to Stefan for your continuous fight for better IE compatibility ;-).


    Under the Hood

    A major contribution to this release was Daniel's work a sophisticated authorization mechanism.
    Through that mechanism you have fine grained control over which users and groups may create, view, edit and delete which resources.

    As a first step, we applied that mechanism to cockpit, tasklist and the admin app. From today on, you will only be able to access the apps you have been authorized for ;-).

    Furthermore, superpowered users may configure all this through the extended admin application.

    Manage users, groups and authorizations through the admin app.

    Daniel also worked on improving the history, both in terms of structure and performance. The result moved into our code base, expect a blog post about it, soon.

    In the meantime Roman and I overhauled the cockpit process definition and process instance view internals. The result is a small library called angular-data-depend and a cleaner code base.
    Each action you perform is reflected in the url. As a result, you can are able to walk back through what you have done using your browsers history.

    Walking through your process data with cockpit and jump back using your browsers history.
    (Excuse bad quality, not enough pixels ;-)

    Last but not least, we created a process instance filter that tells you exactly where you are and what you filter for. It allows you to narrow the displayed process instances based on their business key and process variables, too.
    Finds the process instances interesting for you.
    As always, tell us what you think on our mailing list.

    camunda BPM participates in BPMN Roundtrip Demo of OMG

    $
    0
    0
    The camunda BPM platform participated in a somewhat extreme BPMN roundtrip demo of the OMG. During that demo, the camunda engine managed to execute a BPMN process model that we pushed through five different modeling tools. Altogether, eight tools participated in the entire roundtrip. Among them where camunda Modeler for editing BPMN in Eclipse, the camunda engine for executing the BPMN process and camunda-bpmn.js for rendering BPMN in JavaScript. In addition, I also did a demo of how to use camunda Cycle for automating BPMN roundtrips.

    Find the full story, screenshots and videos at BPM-Guide.de: BPMN Roundtrip works: Interchange Demo with 8 Tools.


    It's done: camunda BPM 7.0.0-Final released

    $
    0
    0
    We are happy to announce the first major release of camunda BPM: 7.0.0-Final. The highlights of this release are
    Distributions are available for Apache Tomcat, JBoss Application Server 7 and Glassfish Application Server 3. An additional IBM WebSphere Application Server 8 distribution is reserved for enterprise customers only. For more information about this release, please join us for our (free) upcoming webinars: English Speaking Webinar, German Speaking Webinar.

    Enterprise Support

    The 7.0 release is the first supported production release for camunda BPM. It is fully supported in the camunda BPM enterprise subscription. Support includes Help Requests based on different SLAs as well as access to camunda BPM maintenance releases. Maintenance releases allow customers to get bugfixes for production systems based on the 7.0 codebase. While the community project will forge ahead for 7.1, we will backport bugfixes to the 7.0 branch and perform maintenance releases reserved for enterprise subscription customers.

    There is a Migration Guide targeting existing camunda fox installations.

    Looking Back

    A little over 5 months have passed since we announced the camunda BPM project launch. During that time we have performed 9 community preview releases and 14 developers have contributed a little over 1200 commits to the main codebase. As project lead of camunda BPM I want to take this opportunity for thanking my team at camunda for their exceptional work and commitment to this project. Getting to where we are today, to me, felt like one single intense coding session and I must say that the whole team really rocked it to the max.

    The heros of camunda BPM 7.0 are
    QA Engineer: Michael Schöttes
    QA/CI Infrastructure, Maintenance & Build Automation: Christian Lipphardt, Stefan Hentschel
    Product Management: Robert Gimbel

    Besides us core guys who can work on camunda BPM every day, we have a growing number of community members who contribute to camunda BPM in various ways. Among these I want to stress the restless efforts of Bernd Rücker who is our chief evangelist and probably the most black-belt BPM practitioner out there. He also co-organizes many of our community meetings. The community meetings are free discussion meetings where people get together and talk about BPM and related topics. So far, we have organized 12 community meetings and the next ones are already scheduled. Bernd is heading the team of camunda consultants among which I want to thank Kristin Polenz and Falko Menge for their many many contributions to the project and channeling a huge amount of customer feedback. From the community outside of camunda I want to highlight the efforts of Clint Manning from 1&1 who made large contributions to the REST Api as well as Marcel Wiczorek and Jörg Bellmann from zalando for their contributions to the process engine history refactoring.

    The camunda Incubation space was launched with three interesting projects:

    Looking Forward

    We will do an international (English speaking) community Day in Prague. Entry  is free and I hope that as many of you as possible can make it.

    And other than that, we will forge ahead for the 7.1 release!

    Do not miss our Webinars: German Speaking | English Speaking

    How to use BPMN 2.0 ScriptTask with Groovy in JBoss

    $
    0
    0
    Recently at a customer we added a ScriptTask to a process and wanted to run a Groovy script. Pretty easy with camunda BPM - but in the JBoss environment you have to know how to correctly put Groovy on the classpath - as we correctly use the JSR 223 stuff to recognize existing Scripting Languages.


    To help others and to remind myself I quickly wanted to blog how to do this.

    1.) Add groovy module to your JBoss

    Download latest groovy-all.jar and copy it to JBOSS_HOME/modules/groovy/main/groovy-all.jar.

    Create JBOSS_HOME/modules/groovy/main/module.xml with the following content:

    <?xml version="1.0" encoding="UTF-8"?>
    <module xmlns="urn:jboss:module:1.0" name="groovy">
        <resources>
            <resource-root path="groovy-all.jar"/>
        </resources>
           
        <dependencies>
            <module name="javax.api"/>
            <module name="org.apache.commons.logging"/>
        </dependencies>
    </module>

    2.) Add dependency to groovy in the camunda engine module

    Edit file  JBOSS_HOME/modules/org/camunda/bpm/camunda-engine/main/module.xml. Add one line in the dependencies:

      <module name="groovy" services="import" export="true" />

    Important is the services="import" which tells JBoss to recognize the META-INF/services directory in groovy - which is does not by default. This is the small thing with normally takes some hours to solve - hope this helps somebody out there. You can find the according JBoss documentation online. The whole module.xml now looks more or less like this: 

    <module xmlns="urn:jboss:module:1.0" name="org.camunda.bpm.camunda-engine">
      <resources>
        <resource-root path="camunda-engine-7.0.0-Final.jar" />
      </resources>

      <dependencies>
        <module name="javax.api" />
        <module name="javax.transaction.api"/>
        <module name="javax.enterprise.api" />
        <module name="javax.inject.api" />
        <module name="javax.ejb.api" />
        <module name="javax.xml.bind.api" /> 
        <module name="javax.servlet.api" />
        
        <module name="org.jboss.vfs" />
        <module name="org.mybatis.mybatis" />
        <module name="com.fasterxml.uuid.java-uuid-generator"/>
        <module name="org.joda.time" slot="2.1" />        
        
        <module name="groovy" services="import" export="true" />   
      </dependencies>
    </module>

    3.) Have fun with the ScriptTask!



    camunda share: Discuss your BPMN 2.0 process model in the cloud

    $
    0
    0
    Once a year the whole camunda team does a ShipIt-Day (inspired by Atlassian) - developing something awesome within 24 hours. This year, Kristin, Falko and me did "camunda share" - a web application in the cloud to share and discuss BPMN 2.0 process models. And we shipped it! It is live.

    Try it today: http://camunda.org/share/


    Why camunda share?

    We often discuss with colleagues, partners or customers about process models. We often send around annotated PDF files via email. We were tired of it and wanted to have something like doodle for this. And with camunda BPM and especially the camunda-bpmn.js component we had everything at hand to get that going. And we had 24 hours :-)

    The idea is to avoid any hazzle with logins or users - you get a unique URL nobody can guess and can send that to everybody who is interested.

    Feature Overview

    The following screenshots should give a brief overview of the features of camunda share as of today. As we hacked the last 24 hours I will not go into much more details now...

    Upload a BPMN 2.0 process model (you can use every tool capable of BPMN 2.0)
    comment on elements of the BPMN 2.0 process models
    See all other comments visualized on the model and add your answers
    Multiple features explained
    See or change (as admin) the BPMN 2.0 XML
    You can anonymize process models during upload if you want to discuss on structure without providing company internal information. 

    Roadmap

    First of all: We have small remaining problems with Internet Explorer - we will remove them pretty quickly! For the moment please use Firefox or Chrome.

    We plan to integrate camunda share in the camunda.org community and to develop it further. But there is no fixed roadmap yet. With the beta state of this ShipIt Day we want to collect feedback from users (you!!) and start using it in our own consulting work. Then we will decide how to move forward. So let us know what you think - use the camunda BPM User Forum.

    Where to send the flowers?

    The camunda team at the ShipItDay 2013 in Mamerow
    No need to - we had a lot of fun! But tell all your friends how awesome camunda share, camunda BPM and the whole camunda team is :-)

    camunda BPM + Apache Camel: Integrating two Open Source frameworks for a lightweight BPM+SOA infrastructure

    $
    0
    0
    Apache Camel is a well known Open Source framework solving a lot of integration problems and implementing the Enterprise Integration Patterns. So combining it with camunda BPM is a perfect match: solve workflow and BPM requirements with camunda and integration requirements with Camel.

    Together with Rafael Cordones we took the existing Activiti Camel Module as a basis and did a huge refactoring. For everybody knowing this module I compiled the changes at the end of this article. For everybody else: Lean back and enjoy the show while I quickly walk you through the features. I do this based on our "camel use cases" example which is available on GitHub (by the way - you can discuss this process model on camunda share):


    The process does not solve any real-life business problem but showcases different use cases:
    • Start a process instance when a file is dropped into a folder
    • Start a process instance when a new Tweet is shared on Twitter with the term 'camunda' in it
    • Call a Camel route ("Service") from a ServiceTask. This Service always throws an Exception which we catch with a BPMN Error Event.
    • Call a Camel route ("Service") from a SendTask and retrieve the response asynchronous in a following Message Event.
    • Between all steps there is a UserTask so that you can click through the example using Tasklist.
    The camunda BPM Camel component

    We developed a Camel component to talk to camunda BPM from Camel. You can easily add this component to your own project as described here: https://github.com/camunda/camunda-bpm-camel. I currently work on a JBoss AS 7 distribution already containing Camel and this component - which would make it even more easy to get started. But that's for another time. Let's examine what the component can do for you:

    Start a Process Instance

    Starting a new process instance is really easy - just call the "camunda-bpm:start" endpoint within your Camel Route and specify which process definition should be used. In the example the File Component is used which can watch a drop folder for new files:

    from("file://C:/temp/")
       .convertBodyTo(String.class) // convert content into String
       .to("camunda-bpm:start?processDefinitionKey=camel-use-cases");

    As an alternative you can start a process instance by a message (then the message start event is triggered and the process definition has not to be specified). In the example the Twitter Component is used polling Twitter for new Tweets with the keyword 'camunda':

    from("twitter://search?type=polling&delay=5&keywords=camunda&consumerKey="...")  
     .transform().groovy("def map=[:] \n" +
              "map['tweet.what'] = request.body.text       \n" +
              "map['tweet.when'] = request.body.createdAt  \n" +
              "request.body = map")
     .to("camunda-bpm:message?messageName=camel.start");

    Note that I used a Groovy script to transform the data from what I get from Twitter to what I want to have in the process engine. As I am not a Groovy expert I am sure that there is a more elegant solution to do that - but it worked within minutes - so I was happy. Camel supports multiple possibilities to transform data easily .

    Call a Camel Route from the Process Instance

    In order to call a camel route you have to add a simple expression to your BPMN 2.0 process model:


    In the background this will create the following XML:

    <bpmn2:serviceTask id="ServiceTask_1" name="call some service"
        camunda:expression="#{camel.sendTo('direct:syncService')}">

    Which references a Camel route:

    from("direct://syncService")
      .onException(SampleException.class) // map exception to BPMN error
            .throwException(new BpmnError("camel.error"))
      .end()
      .process(new Processor() {        
            @Override
            public void process(Exchange exchange) throws Exception {
                // always throwing error to demonstrate error event
               throw new SampleException("some error occured in service");
            }
      });

    What you do in the Camel route is completely up to you and not part of this blog post. What I did in the above route is to always throw an exception (do not consider this best practice ;-)). But this allows me to show how to map any exception a BPMN error which can be handled in the BPMN process model. Note that this should only be done in cases of errors you want to model in your process model - see How-To on Error Handling for details.

    Get a response message

    Calling the route with the SendTask is the same as with the ServiceTask. But interesting is how to get the response to the process instance waiting in the message event. The following screenshot shows one process instance waiting for the message in cockpit:


    This is again easy:

    from("seda:someQueue")
        .to("camunda-bpm:message?messageName=camel.answer"); 

    The message name corresponds to the message name in the BPMN 2.0 XML:



    In the example expect the property CamundaBpmProcessInstanceId to be present in the Camel message properties, this is how correlation currently is done. You could hook in some logic in your Route to do correlation/matching yourself, as e.g. shown in the Bank Account Opening Example (this uses by the way a ReceiveTask instead of a Message Event - both is possible):

    from("file://" + postidentFolder)
      .process(new Processor() {
         public void process(Exchange exchange) throws Exception {
           // extract key from file name
           String businessKey = 
              exchange.getIn().getHeader("CamelFileName").toString()
                .split("-")[1]
                .substring(0, 4);
           exchange.setProperty(CAMUNDA_BPM_BUSINESS_KEY, businessKey);
         }
      })
      .to("camunda-bpm://message?activityId=wait_for_postident").

    Where to get it?

    Note that camunda-bpm-camel is still in incubation phase!
      Why is it cool?

      Personally I like Apache Camel especially because it introduced a common language and a well adopted Component concept having a simple solution available for a lot of integration problems out there. File handling, Streaming, huge CSV files processes in parallel? No problem with Camel. Twitter, Salesforce, Hadoop or whatever? There might be a component, see this amazing list here: https://github.com/apache/camel/tree/master/components.

      Camel is no rocket-science. It is not a complex ESB. It is a down-to-earth Java framework making your live easier and reducing the amount of code for quite some problems. The philosophy is matching pretty well with ours. Together with camunda BPM you can already built some sophisticated BPM/SOA solution.

      Further topics
      • Correlation: We have some Correlation Mechanism already built in camunda BPM. So we want to make that available in the Camel integration as well. Currently we discuss how this can be done best - basically which parameters to set in a Camel message in order to get that working. Join our forum to add your opinion!
      • Retry Mechanism: Camel has some retry strategies if some external service is unavailable. camunda BPM has own retry strategies as well. I recommend to use retrying from camunda normally - as this makes monitoring easier. But I am happy to get feedback.
      Ongoing discussions and next steps

      If you follow the forum you will notice that we are still discussing. Join the discussion if you like! To give you an impression - there are a couple of things we ask ourselves:
      • I would like to have Camel installed as a JBoss module and the route deployed within a Process Application. This should be easy doable - but currently we lack time for it.
      • Should we rely on camel-cdi? As this has some drawbacks
      • Properties or Header for CamundaBpm properties? Currently we use properties. Properties are hanging off the Exchange and not off the messages that flow through a route. A processor in a route can copy the headers but may not do it. Properties are maintained all through the route. But normally headers are used. Maybe we should switch?
      • Is it interesting to get a camunda-bpm://events?filter=… consumer endpoint that captures Audit Log events from the engine and send them down the route? 
      • Should we support multiple process engines? Ho do we expose this on the camel API? As a parameter (camunda-bpm://start?processEngine=...)?

      Changes compared to Activiti Camel Module

      And for everybody familiar with the Activiti Camel Module it might be interesting what we changed. In a nutshell:
      • Refactored the core code base to make it easier understandable.
      • Added examples.

      camunda BPM: Power to Embedded Taskforms

      $
      0
      0
      For everyone out there using embedded task forms in the camunda tasklist there is great news:
      The forms are getting way more powerful.

      The upcoming alpha of camunda 7.1 introduces two extensions for embedded task forms: Client side form validation and form extensions via JavaScript.

      Form Validation

      Validation directives provided by AngularJS may now be attached to form fields to activate simple client-side validation constraints for them.

      The following form field will only accept one of the strings demo, john, maryor peter due to the defined pattern:

      <input form-field type="string" name="assignee"ng-pattern="/^(demo|john|mary|peter)$/" />

      If a user enters an invalid value in a form field the field will be marked as invalid. Additionally the complete task button will be disabled and the form may not be submitted.

      An invalid form
      The validation state of both the form as well as single form fields may be queried through the variable variablesForm that represents the form inside the scope of an embedded task form.

      The following snipped is a valid form markup that renders the message Your form contains errors!
      when the form itself is invalid. In addition, it renders a red Not a valid user! message to the user for specific validation problems of the assignee form field:

      <p ng-if="variablesForm.$invalid">
      Your form contains errors!
      </p>
      <p
      ng-if="variablesForm.assignee.$invalid" style="color: red">
      Not a valid user!
      </p>

      JavaScript Form Extensions

      More complex validations may be performed using form script - JavaScript embedded into task forms. form script is injected into the task form context via a special <script form-script type="text/form-script" /> tag:

      <input form-field type="string" name="approver"ng-change="approverChanged()" />

      <script form-script type="text/form-script">
      $scope.approverChanged= function(e) {
      var formField = $scope.variablesForm.assignee,
      value = formField.$modelValue;
      allowedNames = ['demo', 'john', 'mary', 'peter'];

      // value must be contained in allowed names
      if (allowedNames.indexOf(value) == -1) {
      value.$setValidity('validAssignee', false);
      } else {
      value.$setValidity('validAssignee', true);
      }
      };
      </script>

      The above form script performs the same validation as the ng-pattern directive but via JavaScript. To do that it registers a change listener on the form input that is attached to the forms $scope inside the form script.

      For even more elaborated use cases application services such as $http may be injected into the form script. using the inject callback. Given the $http service backend validation may be performed for a form or its attributes: 

      <script form-script type="text/form-script">

      inject([ '$scope', '$http', function($scope, $http) {

      $scope.approverChanged= function(e) {
      var formField = $scope.variablesForm.assignee,
      value = formField.$modelValue;

      $http.get("...?assignee=" + value).success(function(data) {
      if (data == "ok") {
      value.$setValidity('validAssignee', true);
      } else {
      value.$setValidity('validAssignee', false);
      }
      });
      };
      }]);
      </script>
      Find all of this including an improved documentation of embedded task forms in the next camunda BPM alpha release.

      Power to the forms!

      camunda Modeler 2.1.0 released

      $
      0
      0
      Today we relased a new version of the camunda Modeler. It provides better property editing support for BPMN 2.0 and camunda BPM properties, improvements in pool and lane handling and fixes a number of important bugs.


      Property Editing Support

      Kristin and Roman extended the property panel to achieve partity with new engine extensions and features introduced in camunda BPM 7.0:

      In addition, documentation may now be maintained for all BPMN 2.0 elements.

      Modeling enhancements

      To enhance the modeling experience I worked on an improved pool and lane handling
      • Pools and lanes may not be shrinked below their children bounds
      • Bendpoints are properly update upon pool or lane resize
      • Sufficient space is added on the diagram when adding a new pool
      Furthermore we fixed the boundary event attachment on attached element resize. 

      BPMN 2.0 Compatibility

      Daniel, Roman and I improved the interoperability of the modeler by fixing a number of diagram import and export related bugs:

      • No more xsi:type=“xsd:anyType" is added to extension elements on export
      • Documentation is exported correctly without reordering
      • Data object references are supported on import and are correctly created by the modeler
      • Diagrams containing invalid DI references to data objects are automatically fixed during import

      Finally, we switched from activiti to camunda as the default namespace prefix for engine attributes. 

      Check out the release notes for a complete list of changes.

      Behind the Scenes

      Christian and Roman integrated the modeler tests into our continuous integration. As a result the ~500 modeler tests run now continuously and no test covered feature will accidently be broken again.

      What is lying ahead of us? For the next modeler release we look into Eclipse Kepler support and more modeling improvements.

      Feel free to try out the new modeler and give us feedback via our forums or twitter.

      What a wonderful community day in Prague

      $
      0
      0

      Last Friday we had our first camunda BPM community day! It was really awesome! Thanks everybody who joined. I am really impressed that we could organize that so close after the 7.0 release and so many people already traveled to Prague just for us. I can just repeat myself: AWESOME!

      Today I want to share some impressions and slides with you - we recorded the sessions and hope we will get videos online soon as well.




      Introduction & Vision

      After welcoming everybody Daniel talked about camunda BPM and the technical vision, which is about to empower developers to build awesome BPM applications. He briefly discussed the improved performance in 7.0 and I saw a lot of people nodding when Daniel talked about HUGE history data when running big scenarios and got good feedback about the solution strategies he sketched. He also explained why it is essential to be an Open Source framework for our vision.

      SLIDES

      Latest and greatest from the dev team

      Afterwards Nico talked about the latest news from the development team. He focused on the user interface with camunda tasklist, cockpit, camunda-bpmn.js and last but not least the plugin-infrastructure. Yeah - you see right - he developed a Macgyver Plugin for cockpit. That is really awesome :-)

      SLIDES
      customer experience report: 1&1 Internet AG


      A highlight of the day was the talk from Mehmet Sürü from 1&1, a leading telecommunication provider at least in Germany. And hey - they already have modeled over 5.500 processes in BPMN - wow! He explained their learning curve, leading from SOA to BPM (because in processes not services lie the real value) and technologically speaking from a platform composed of JBoss AS 4 + jBPM 3 to JBoss AS 7 + camunda BPM 7. He also talked about why Open Source, Community and Contributions are vital for their core "Service + Process Platform". And camunda BPM is already in production for a couple of processes at 1&1 - great to hear!

      SLIDES

      Tales from Consulting

      Falko and me talked about some experiences from our consulting work at various customers using BPMN 2.0 and camunda BPM. We talked about the online working group best practices (see our next meeting), some results we already got, versioning of processes and process applications, Liferay Portal Integration, asynchronous continuation, heterogeneous cluster support and the power of it, JMS usage, Business-IT-Alignment, Handling of Incidents and own cockpit Plugins and some small but really helpful stuff in real life - like the task name beautifier. Hope not too much content in too short time.

      SLIDES

      Contributors

      We already have a quite active ecosystem of contributors. Two contributions were highlighted in Prague:

      Martin Schimak (Plexiti): Martin kicked-off and worked on camunda-bpm-testing (together with a couple of people in the meanwhile). We showed us the variety of topics already covered: fluent API, behavior driven development, mocking, ...

      SLIDES (and he blogged about the community day as well: camunda.org Community Day 2013 in Prag!)

      As second contribution Rafael Cordones wanted to present camunda-bpm-camel, the integration with Apache Camel. As he had to cancel the visit in short notice I quickly introduced that. Cool to have a couple of people in the audience already using Camel!

      SLIDES



      How do we work, Roadmap and Feedback

      The rest of the afternoon was packed with some demonstrations about how we work (JIRA, Kanban-Board, GitHub, Pull-Requests, Contributions-Guidelines, Forum and so on). We discussed the current roadmap and plans - and we got pretty good feedback from the community - that further confirmed that we are on the right track. And the most amazing thing: There were no issues raised which is urgent or problematic - so camunda BPM 7.0 was definitely a step in the right direction. That was the right time to start partying (see below) :-)

      Which city to go next time?

      The venue this year was fantastic. Prague is a wonderful city really worth visiting. The Hotel was really nice, food was plenty available (no lie that they had "unlimited supply") and even the weather was perfect!

      Hard to beat next year - but we can try. If you have a recommendation for a city, which is: easy to reach from different European cities, not too expensive and nice: Let us know!









      Some more impressions

      Last minute slides ;-)

      One feature was developed live (CAM-1380)!

      It looks like even Daniel learned something.

      Merging pull requests was kind of fun :-)

      Hard to imagine a community day without beer - good to be in Czech Republic. 

      The real questions about 1&1 platform came later on.

      Finally we found a pub where we got space, we simply were too much people...

      ...and it seems that we even managed to drink one barrel of beer. Wow!
      Pork me on GitHub?

      Last but not least we had a really - really good idea (imagine that we liked it somewhere around midnight ;-)). As most of the people ate some fresh grilled pork in the evening we came up the new badge idea: pork me on GitHub. Actually no idea what it means - but maybe better not to think about it:



      But as vegetarian I have to add that Prague offered a good choice of vegetarian and vegan restaurants - so I could try a vegetarian and a vegan goulash. And both were really perfect! This is how the future must look like :-)

      You can even enjoy vegan pancake - gorgeous.



      How to send an email when a usertask is assigned

      $
      0
      0
      "I don't want to watch my camunda Tasklist all day. When there is something to do, I want to get an email containing a link that takes me directly to the respective task!"

      This is a typical statement by process participants (aka business users). There are numerous possible ways to implement such a requirement in your process application, e.g. using a service task:




      But this is not really appropriate, since it makes the process model rather verbose and therefore less valuable for business-IT-alignment.

      The more elegant way is to use a task listener: This very powerful concept is described in detail in the userguide, and the behavior we want is a perfect use case, so let's see how it works!



      Let's say we created a simple process application (like in the Get Started Tutorial), but this process contains only one usertask. The next step is to created a Task Listener Class like the one below. The important parts are:

      • It implements the Task Listener Interface.
      • It retrieves the assignee from the Task Object and loads the according User Profile including the assignee's email address.
      • It creates a simple mail containing a deep link to the task instance.

      package org.camunda.bpm.quickstart;

      import java.util.logging.Level;
      import java.util.logging.Logger;

      import org.apache.commons.mail.Email;
      import org.apache.commons.mail.SimpleEmail;
      import org.camunda.bpm.engine.IdentityService;
      import org.camunda.bpm.engine.delegate.DelegateTask;
      import org.camunda.bpm.engine.delegate.TaskListener;
      import org.camunda.bpm.engine.identity.User;
      import org.camunda.bpm.engine.impl.context.Context;

      public class TaskAssignmentListener implements TaskListener {

        // TODO: Set Mail Server Properties
        private static final String HOST = "mail.example.org";
        private static final String USER = "admin@example.org";
        private static final String PWD = "toomanysecrets";

        private final static Logger LOGGER = Logger.getLogger(TaskAssignmentListener.class.getName());

        public void notify(DelegateTask delegateTask) {

          String assignee = delegateTask.getAssignee();
          String taskId = delegateTask.getId();

          if (assignee != null) {
         
            // Get User Profile from User Management
            IdentityService identityService = Context.getProcessEngineConfiguration().getIdentityService();
            User user = identityService.createUserQuery().userId(assignee).singleResult();

            if (user != null) {
           
              // Get Email Address from User Profile
              String recipient = user.getEmail();
           
              if (recipient != null && !recipient.isEmpty()) {

                Email email = new SimpleEmail();
                email.setHostName(HOST);
                email.setAuthentication(USER, PWD);

                try {
                  email.setFrom("noreply@camunda.org");
                  email.setSubject("Task assigned: " + delegateTask.getName());
                  email.setMsg("Please complete: http://localhost:8080/camunda/app/tasklist/default/#/task/" + taskId);

                  email.addTo(recipient);

                  email.send();
                  LOGGER.info("Task Assignment Email successfully sent to user '" + assignee + "' with address '" + recipient + "'.");          

                } catch (Exception e) {
                  LOGGER.log(Level.WARNING, "Could not send email to assignee", e);
                }

              } else {
                LOGGER.warning("Not sending email to user " + assignee + "', user has no email address.");
              }

            } else {
              LOGGER.warning("Not sending email to user " + assignee + "', user is not enrolled with identity service.");
            }

          }

        }

      }

      The last step is to assign the class as a task listener to the usertask in the process model. As you can see below, the task listener will be executed when the usertask has been assigned:



      And that's about it! If you want to see an example ready to run, just check out the Task Assignment Email Quickstart.

      From a user perspective, it will look like this:




      Have fun with camunda :)

      camunda Modeler 2.2.0 released: Kepler support and modeling improvements

      $
      0
      0
      Today we are happy to anounce the new release of the camunda Modeler. This version adds official support for Eclipse Kepler. On top of that it ships with the ability to change the type of tasks, events and gateways as well as a simplified connection of elements.

      Eclipse Kepler Support

      Kepler support is finally there. Head over to the downloads site and get a fresh version of the modeler, ready for Kepler.

      Morphing áka Changing Flow Node Types

      Morphing flow nodes to different types is something we are pretty exited about because it makes it a lot easier to change existing process models. Thanks to Roman, this feature is now available via the actions menu as two small gears for tasks, events and gateways.

      Morphing an exclusive gateway via the actions menu
      Changing the flow node type performs a semantic check on the model and makes sure that invalid outgoing flows (according to the BPMN 2.0 specification) are removed. You may undo the operation via CTRL-Z if it has unexpected implications on your model.

      Have a look on the screen cast shown below to see how the new morphing feature feels like.
      Morphing all around over the world.

      Easier Connection of Elements

      We simplified the connection of objects via the actions menu. In the new version of the Modeler the tool will automatically choose the correct connection type based on the rules defined in BPMN 2.0. That also means that some invalid connections may no longer be drawn. Bear with us, it is all for the sake of better BPMN 2.0 models. 

      See the screen cast below to for a quick overview on the changed look and feel.
      Simple connection drawing. Really.

      Property Panel Improvements

      Some other notable changes to the properties panel include (thanks to Kristin and Roman):
      • targetNamespace editable
      • compensation task editable
      • message names editable
      • async throwing message event editable
      • datastores and data objects may be maintained
      • loop for activities can be set
      • call activity property validation added

      BPMN 2.0 Compatibility

      To help mitigating common modeling errors we added further checks to the Modeler for flow and flow node addition, as well as reconnection of flows. These reduce the likelyhood that invalid BPMN 2.0 is the result of a modeling session. 

      Check out the all closed issues for a complete list of changes.

      Behind the Scenes

      Michael has done a great job on improving our Jubula QA. The others in the team are already working on features for the next modeler version. Expect something exciting!

      For now, feel free to try out the new modeler. Is there anything you particularily liked or a feature that is still missing? Tell us on via our forums or on twitter.

      Synchronous vs. Asynchronous Service Invocations - BPMN Service Task (1)

      $
      0
      0
      The BPMN 2.0 Specification provides the Service Task activity allowing users to invoke some application service. In this Blogpost I want to explain the difference between a synchronous and an asynchronous service invocation in camunda BPM.

      NOTE: this bogposts covers the topic at an abstract level. If you are looking for concrete, ready-to-use examples, have a look at our quickstart repository: 

      Synchronous Service Invocations

      Let’s start with synchronous service invocations. A synchronous service invocation follows the well-known Request / Response Pattern:

      The process engine performs a synchronous request to a service and waits for a response. The characteristic property of this invocation pattern consists in the fact that the process engine thread sending the request is blocked until the response is obtained:

      Transactional process engines such as the camunda process engine will typically associate a database transaction (Process Engine Tx in the illustration above) with this thread.

      Implementing a synchronous service invocation in camunda BPM is very straight forward:
      1.           Model a Process containing a Service Task
      2.           Attach a “JavaDelegate”-Implementation to the service task.
      Check out this quickstart on synchronous service invocations to learn how to to implement this.

      Asynchronous Service Invocations

      An asynchronous service invocation usually follows the Request / Acknowledge / Callback Pattern:


      The process engine sends the request to the service. But instead of processing the request right away, the the service first puts the request into a Queue. It then acknowledges the receipt of the request to the process engine. The request is then delivered asynchronously to the actual request processor. The request processor executes the business logic. Finally it sends a callback to the process engine which may now continue execution in the process instance. 

      In practice, we encounter multiple variations of this pattern. For example, the callback itself may be delivered synchronously or asynchronously. Furthermore, the queuing of the requests may be performed before or behind the service boundary. Here is an illustration of two of such variations: 


      Contrary to the synchronous service invocation, the transaction context of the process engine is  not propagated to the service implementation. In fact, an asynchronous service invocation always comes down to at least two transactions (labelled Tx1 and Tx2 in the illustration below):

      1. in the first transaction (Tx1), the request message is sent. If the request is acknowledged, the process engine interrupts execution and commits the transaction.
      2. in the second transaction (Tx2), the callback is sent and processed. This constitutes a new transaction in which the process engine resumes the state of the execution and ends the service task activity.
      Implementing an asynchronous service invocation in camunda BPM is a lot more complicated than implementing a synchronous service invocation. You have to:
      1.  Model a Process containing a Service Task
      2.  Attach a “SignallableActivityBehavior”-Implementation to the service task.
      3. In the execute() method, send a message to the actual Business Logic
      4. Implement a callback message which is correlated to the same process instance from which the request message was sent.
      Check out this quickstart on asynchronous service invocations to learn how to to implement this.


      Creative Commons License
      This blogpost including images & illustrations is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.

      camunda BPM PHP SDK v1.1.0 released

      $
      0
      0
      Today we released version 1.1.0 of the PHP SDK. The highlights of this release are:

      • Add compatibility with camunda BPM 7.0.0 Final
      • Fully object oriented API
      • Improved test coverage through PHPUnit
      • Add support for composer
      The packages are pushed to Packagist.

      camunda PHP SDK allows PHP users to interact with the process engine and build BPMN 2.0 and Workflow enabled applications.


      Create a camunda BPM Process Application using Maven Archetype in 1 minute

      $
      0
      0
      For quite some time we already use Maven Archetypes in our camunda BPM training and at customer projects to create camunda BPM Process Applications - which are normally simple Maven projects. Today I made a quick screencast to show how easy it is to use them:


      And I created a 30 seconds survey to get feedback on archetypes - please fill it out: http://kwiksurveys.com/app/rendersurvey.asp?sid=d9juq1qriakt2ls257813


      We currently have two archetypes available:
      • war: Use on Servlet containers like Tomcat.
      • ejb: Use on EJB containers like JBoss AS, WebSphere, Glassfish or WebLogic.
      You can find the full documentation online: Maven Archetypes (Project Templates).So you can start using it today.

      Give us feedback!

      We currently discuss how important archetypes are for our community and what types of archetypes we should provide (if any). Please take 30 seconds to fill in our survey. Thank you!
      Viewing all 143 articles
      Browse latest View live