1 2 Previous Next 18 Replies Latest reply on Sep 23, 2011 3:37 PM by Chris Nash

    Domain-specific processes not registering

    Chris Nash Newbie

      Hi All,

       

      I'm trying to create a domain-specific process. Following the instructions in the manual (http://docs.jboss.org/jbpm/v5.1/userguide/ch13.html#d0e3557), I placed the .wid and .conf files in a new META-INF folder off of the project's resources folder, i.e.:

       

      workspace/<project base>/src/main/resources/META-INF

       

      but the new process doesn't show in the Eclipse BPMN editor. I know Eclipse isn't finding it because I excluded the default "WorkDefinitions.conf" file, but it still shows the "Log" and "Email" tasks under "Service Tasks". So the folder must not be included in my classpath correctly. It's included under Properties | Java Build Path | Source. I tried including it under Order and Export as well, but that didn't help so I removed it. I'm pretty sure my syntax in the .conf and .wid files is correct (nearly identical to what the doc shows). Any idea what I can do to resolve this?

       

      Thanks in advance!

        • 1. Re: Domain-specific processes not registering
          Tihomir Surdilovic Master

          Hi Chris, hope this video helps you: http://people.redhat.com/kverlaen/DomainSpecificWorkItem.swf. It's an older video but still really good...just make sure the file extension is .wid because this has changed since. If you are working with a maven project (not a drools project) it gets a little tricky, but you just have to make sure that the folders with your configurations are actually set as source folders in the project settings.

           

          If you are using the new BPMN2 Eclispe editor I really do not know if this feature is supported there. The web designer fully supports workitem definitions saved in Guvnor, for this check out these videos: http://vimeo.com/24288229 , http://vimeo.com/26126678.

           

          Hope this helps.

          • 2. Re: Domain-specific processes not registering
            Chris Nash Newbie

            Thanks, Tihomir. I like the video, but it's adding a DSP to a rule resource, not a workflow. Can DSP be added to workflows or just rules? And what is the difference between "rules" and "workflows"? Are rules just called by workflows? I haven't seen this discussed in the docs. And the docs I linked above make it sound like DSP can be implemented for workflows. Following the video, the DSPs don't show up for workflows.

             

            I have to say, I'm having serious misgivings about jBPM5 (5.1 specifically). I recommended our project use it for a workflow process solution based on the initial documentation and recommendations I heard for it online: "mature", "stable", "robust". With nearly every experiment I've tried to do with it, I've run into roadblocks and crashes. I realize this is a community-developed product, but is there a stable version with complete documentation? We'd even be willing to pay for support, but JBoss doesn't seem interested in our money. Is there some reason anyone can give me for choosing jBPM over something else, like Activiti?

            • 3. Re: Domain-specific processes not registering
              Tihomir Surdilovic Master

              >> but it's adding a DSP to a rule resource, not a workflow. Can DSP be added to workflows or just rules?<<

              I assume here you are refering to http://people.redhat.com/kverlaen/DomainSpecificWorkItem.swf. Not sure why you think its added to a rule resource, maybe because of the .rf extension to the process file? As mentioned, this is an old video from the drools-flow era, and the file extension for processes was .rf (rule-flow). These files used a proprietary xml standard (similar but not same to jPDL in jBPM 3.x and 4.x). jBPM5 uses the BPMN2 standard as the default process definition language. However, the notion of being able to add "domain-specific" nodes into your business process is something that already existed in drools-flow, from which jBPM5 was born, and most of the same rules and configuration options (especially in eclipse env.) still apply. This chapter http://docs.jboss.org/jbpm/v5.1/userguide/ch13.html of the docs I belive explains well what a domain-specific extension is. Not many BPM engines AFAIK have this feature built in natively so it's a really nice thing to have.

               

              >> Are rules just called by workflows? << The BPMN2 specification defines a BusinessRuleTask node which is an extension of the Task node and is able to call upon some defined rules. jBPM follows this spec and is able to execute Drools rules in an user-defined ruleflow-group when this node is encountered in the process. The tight integration between jBPM5 and Drools also allows you to specify rules in sequence flows, script tasks, etc.

               

              >> With nearly every experiment I've tried to do with it, I've run into roadblocks and crashes. << I am first of all sorry that you ran into issues. However believe that you would have had a very similar experience with other OSS type of BPM solutions. The difference is how quickly you receive(d) help and quickly you can overcome these issues/questions that is important, and I think in your case this time has been fairly if not very quick.

               

              >> We'd even be willing to pay for support, but JBoss doesn't seem interested in our money. << This is not good, and if you can please email me directly at tsurdilo at redhat dot com and I will make sure that your message gets forwarded to the appropriate people to make sure they contact you. Currently we are running a jBPM5 pilot program, and you would be more than welcome to take part of that.

               

              >> Is there some reason anyone can give me for choosing jBPM over something else, like Activiti? << My opinion is of course biased so I will not comment on this. It is ultimately your decision on what software you use

              • 4. Re: Domain-specific processes not registering
                Chris Nash Newbie

                Thank you. The fact that the video is outdated is probably whats holding me up. I like the visual implementation because its easy to follow step-by-step and pause and rewind when necessary. But the fact that it's showing something I'm not seeing is what threw me. Even so, following the steps it showed, the DSPs did not show up for my workflow.

                 

                I emailed you. Thanks for all the support!

                • 5. Re: Domain-specific processes not registering
                  Tihomir Surdilovic Master

                  I am still unclear on the type of eclipse project you are working with. If it's small project maybe you could provide a zip so we are on the same page? Also what Eclipse BPMN2 editor are you using?

                  • 6. Re: Domain-specific processes not registering
                    Chris Nash Newbie

                    I'm just doing a test project right now, to try and get DSP working. It's nothing special; I have 3 script nodes, each which just prints out a string to the console. I wanted to implement another custom one (a DSP) that does something similar, just as a proof-of-concept, just to see how it's done. I'm using the old Eclipse BPMN editor (not the new one, which I couldn't get to work).

                    • 7. Re: Domain-specific processes not registering
                      Tihomir Surdilovic Master

                      Thanks for the info. I'll create am example and put up a blog in the next day. I'm sure you are not the only one with the same question.

                      1 of 1 people found this helpful
                      • 9. Re: Domain-specific processes not registering
                        Chris Nash Newbie

                        Tihomir Surdilovic wrote:

                         

                        I'll create am example and put up a blog in the next day. I'm sure you are not the only one with the same question.

                         

                        Still eagerly awaiting this blog entry!  : D

                        • 10. Re: Domain-specific processes not registering
                          Tihomir Surdilovic Master

                          Hi Chris, sorry I was traveling last week then had to catch up with things in last days. Here is a blog post and a video .. hope it helps:

                           

                          http://blog.athico.com/2011/09/jbpm5-tooling-support-for-service-nodes.html

                           

                           

                          Thanks.

                          1 of 1 people found this helpful
                          • 11. Re: Domain-specific processes not registering
                            Chris Nash Newbie

                            Thanks for posting that, Tihomir. It worked up until 4:11. Following the video, my custom tasks don't show up; I even rebooted to make sure nothing was lurking in the system. I just have the two standard Service Tasks: Log and Email. A couple of things:

                             

                            • Your video was kind of low-res, so I couldn't always make out what you were typing (I think I got it right, though). The pace and narration were great though: clear and easy to follow.
                            • You're using a Mac, I'm using Windows Server 2003 (but that shouldn't make a difference)
                            • Your video doesn't mention anything, but my icons are 16x16 PNG files, which the docs say are what's required. If they were wrong, I would still expect them to show up, just cropped or with a default icon of some sort.

                             

                            I'm kind of at a loss about how to troubleshoot this problem. Anything I can try?

                             

                            TIA!

                            • 12. Re: Domain-specific processes not registering
                              Tihomir Surdilovic Master

                              The only thing I can think of right now is that your src/main/resources directory may not be a source folder. Right-click on your project, select Properties and then select Java Build Path, in the source tab make sure you have <projectName>/src/main/resources as a source folder there. In you expand this folder, you should see Included: (All), Excluded: (None).

                               

                              >>Your video was kind of low-res, so I couldn't always make out what you were typing (I think I got it right, though). The pace and narration were great though: clear and easy to follow.<<

                              Here are all the files used in that part of the demo:

                               

                              1) MyDefinitions.wid:

                               

                              import org.drools.process.core.datatype.impl.type.StringDataType;

                               

                              [

                               

                                [

                                  "name" : "Twitter",

                                  "parameters" : [

                                      "id" : new StringDataType(),

                                      "message" : new StringDataType()

                                  ],

                                  "displayName" : "Twitter",

                                  "icon" : "icons/twittericon.png",

                                  "customEditor" : "org.drools.eclipse.flow.common.editor.editpart.work.SampleCustomEditor"

                                ],

                               

                                [

                                  "name" : "Facebook",

                                  "parameters" : [

                                    "id" : new StringDataType(),

                                    "message" : new StringDataType()

                                  ],

                                  "displayName" : "Facebook",

                                  "icon" : "icons/facebookicon.png",

                                  "customEditor" : "org.drools.eclipse.flow.common.editor.editpart.work.SampleCustomEditor"

                                ]

                               

                              ]

                               

                              2) drools.rulebase.conf:

                               

                              drools.workDefinitions=MyDefinitions.wid

                               

                              >> Your video doesn't mention anything, but my icons are 16x16 PNG files <<

                              The size should not matter and I am pretty sure ones I used in that video were not exactly 16x16. Maybe the file extension matter (.png vs. .PNG) so maybe check on that.

                               

                              Hope this helps.

                              • 13. Re: Domain-specific processes not registering
                                Chris Nash Newbie

                                Thanks for responding so quickly, Tihomir. I checked everything in your reply, and everything is in order. The only other thing I can think of, is something that doesn't matter: the PC I'm running it on is actually a VM. This really shouldn't have any effect at all: as far as it knows, it's really a hardware box running Windows Server 2003.

                                 

                                Anyway, I get no errors in the console window; it just doesn't show the DSP nodes. My Package Explorer looks just like yours in the video, with the Exception of being on Windows vs. a Mac. No idea...

                                • 14. Re: Domain-specific processes not registering
                                  Tihomir Surdilovic Master

                                  >> Anyway, I get no errors in the console window; it just doesn't show the DSP nodes. <<

                                  Does it show none at all or does it still show the default Log and Email ones?

                                   

                                  I just tried this on my Fedora machine and it works as well, I don't have Windows handy  to try it there. Obviously I am guessing here but have you tried closing all the editor tabs and cleaning + refreshing your project? Maybe even go to the point of closing/reopening your project in eclipse or deleting the project (do not delete on the actual file system ) and then re-importing it back?

                                   

                                  Are the new workitems not showing up for reopened existing processes as well as when creating a brand new process?

                                  Are you creating the processes in src/main/resources directory?

                                   

                                  I am not sure why in your case the runtime is not picking up drools.rulebase.conf and overwriting the default with it. In the cases I have seen this before was where I did not place drools.rulebase.conf in a folder that was actually a source folder in the project, but it seems this is not the case with your setup. Have you been able to test the same thing on another machine?

                                   

                                  EDIT: Do you have "Build project automatically" turned off by chance? Try turning that on and trying again..

                                  EDIT2: Are you creating your processes in a source folder?

                                  1 2 Previous Next