6 Replies Latest reply on Nov 10, 2009 6:09 AM by Makarand Kulkarni

    jbpm 4.1 - Pre and Post processing

    Makarand Kulkarni Newbie

      Hi All,

      I am running the process through jbpm-console.

      I have few questions about Pre and Post events before task processing.

      Requirement is to populate the data in FTL forms using external files OR database. Hence I have written Pre step to get the data and set Process variables which can be used in FTL forms to show in FTL forms.

      Problem here is that if there is any external problem in connecting to database/file due to any reason , it fails but then I need to run Pre handler again to populate the form data, there seems to be NO way to run the same task again.

      Is there any way to resolve this problem ?

      Currently I am using on event "start" or "end" to perform some operations before or after task

      Youe help in this is highly appreciated.


        • 1. Re: jbpm 4.1 - Pre and Post processing
          carlos mauricio jaramillo henao Newbie


          Sorry for my English, I speak a little english ......... I installed jBPM 4.2 on Tomcat and Postgres, I wonder if I can explain how I can publish and implement a process from eclipse jbpm-console ... .... Any documentation about it would be useful for my


          • 2. Re: jbpm 4.1 - Pre and Post processing
            Makarand Kulkarni Newbie

            Can anybody help me in getting solution to my queries ?

            • 3. Re: jbpm 4.1 - Pre and Post processing
              Sebastian Schneider Master

              Hello Makarandk502,

              why do you want to use task forms? I have no clue if the thing you want to do is possible and I am not sure if I understood what you are trying to achieve. Maybe you can also elaborate on what you've done so far since it's a lot easier to help then.

              As far as I understood you want to display data coming from a database in the task forms used by users to complete tasks in your process, right?

              Why don't you use something like JSP or JSP with JSF for this? Then you can easily access the jBPM API and the database and you can create nice forms.

              Koen shows how to combine JSF and jBPM in this post:

              Reargind you, cmjhingeniero:

              For different topics please start a new thread! Thank you. To answer your question: There is no way to deploy a process definition in the jBPM-console. Use the ant deployment task shipping with the distro to deploy process definitions.


              • 4. Re: jbpm 4.1 - Pre and Post processing
                Makarand Kulkarni Newbie

                I am really thankful to you for providing jbpm-jsf post.

                Can I get to know some more good posts like this ?

                You have understood correctly.

                Basically I am developing workflow applications using combination of Tasks, forks, joins etc. I am currently using jbpm-console to drive/run this process.

                Each task is having a form populated with external data from file/database and in some cases, simple form is used.

                Now I am starting the process using jbpm-console. Currently I am using Pre and Post events to collect the data from database and populate it in FTL forms

                Can I use JSP/JSF form instead of Freemarker Templates ? Does Jbpm-console supports this ?
                I am currently not using jbpm APIS as my process is running from console.

                • 5. Re: jbpm 4.1 - Pre and Post processing
                  Sebastian Schneider Master

                  I consider the jbpm-console to be more of a tool for administration, prototyping and monitoring especially because of the current state of the task forms which are still very limited.

                  The console only supports Freemarker templates. By pre and post events do you mean events before and after the task (events in the execution of the process) or are you talking about a taskform thing?

                  Because of my point of view stated above I'd advice you to do your own user interface programming. I just know that task forms are still very limited and have not really been using them. My forms are either part of Swing Applications or they are HTML-forms on a java server page.

                  For interesting articles always check the blogs of Ronald, Tom, Joram, Koen etc.

                  • 6. Re: jbpm 4.1 - Pre and Post processing
                    Makarand Kulkarni Newbie

                    Pre and Post events :

                    I mean in the events before and after task (events in the execution of the process), we can set Process Variable and that can be used in Freemarker Templates.This way we can get the data in Pre event and set the process variable and use it in Freemarker Template forms.

                    Post suggested is interesting and worth to try myself.

                    But in this approach I need to implement functionality myself very similar to jbpm console. How you implemented this yourself ? If any such blog/forum which tells more details on this, that would be really great.

                    If there is any tutorial of developing wizard type application(which can be run without jbpm-console) without using jbpm-console, please let me know.

                    Again thanks for the suggestions