3 Replies Latest reply on Jul 5, 2012 4:45 AM by objectiser

    How do I write CDM's that can generate BPMN2

    steverosstalbot

      I have a fairly small CDM model (attached I hope) and I have turned on the super validation for the CDM model. My aim is to generate BPMN2 for the CDM but I still have errors in the CDM that are as a result of the super validation which I cannot figure out.

       

      Anyone out there have any suggestions as to what I need to do?

       

      The errors are:

       

      DescriptionResourcePathLocationType
      [ActivitiesScreenParticipant] Choice for role 'ActivitiesScreenParticipant' is not projected to all pathsCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem
      [UserLogServiceParticipant] Choice for role 'UserLogServiceParticipant' is not projected to all pathsCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem
      [WFAssignWorkBSParticipant] Choice for role 'WFAssignWorkBSParticipant' is not projected to all pathsCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem
      Activity at role 'HomePageViewParticipant' is not connected to preceding activitiesCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem
      Name 'UserParticipant' has already been declaredCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem
      Role(s) 'ActivitiesScreenParticipant, UserLogServiceParticipant & WFAssignWorkBSParticipant' cannot be projectedCDM_02-07-2012 14-05-40-v1.cdm/SCN2CDM/ModelsUnknownSavara Problem

       

      Cheers

       

      Steve T

        • 1. Re: How do I write CDM's that can generate BPMN2
          objectiser

          This is the scribble representation that has been derived from this CDL:

           

          protocol LOCProcess(role UserParticipant) {
              HomePageViewParticipant introduces ActivitiesScreenParticipant, UserParticipant;
              UserParticipant introduces UserLogServiceParticipant, WFAssignWorkBSParticipant;
          
              Login(Login) from UserParticipant to UserLogServiceParticipant;
          
              choice at UserLogServiceParticipant {
                  Login(LoginFailed) from UserLogServiceParticipant to UserParticipant;
              } or {
                  run HomePageViewCollaboration(HomePageViewParticipant, ActivitiesScreenParticipant, UserParticipant, WFAssignWorkBSParticipant) from HomePageViewParticipant;
              }
          
              protocol HomePageViewCollaboration(role HomePageViewParticipant, role ActivitiesScreenParticipant, role UserParticipant, role WFAssignWorkBSParticipant) {
                  ActivitiesScreen(EnterView) from HomePageViewParticipant to ActivitiesScreenParticipant;
          
                  choice at UserParticipant {
                      ManualAssign(ManualAssign) from UserParticipant to WFAssignWorkBSParticipant;
                  }
          
                  choice at UserParticipant {
                      run CaseReviewManagerCollaboration(HomePageViewParticipant, UserParticipant) from HomePageViewParticipant;
                  } or {
                      SRRejection(SRRejectNotification) from UserParticipant to HomePageViewParticipant;
                  }
          
                  protocol CaseReviewManagerCollaboration(role HomePageViewParticipant, role UserParticipant) {
                      choice at UserParticipant {
                          SRRepair(SRRepairNotification) from UserParticipant to HomePageViewParticipant;
                      }
          
                      protocol WFAPAFunctionsCollaboration {
                      }
                  }
          
                  protocol WFActionBCCollaboration {
                  }
              }
          }
          

           

          The first issue is that there appears to be a bug causing all of the participants to be declared at the beginning of the top level protocol, whereas only UserParticipant and UserLogServiceParticipant are actually used in this outer most protocol. The others should only be introduced if the HomePageViewCollaboration protocol is activated. So if you could raise a jira for this, as this is probably causing the first three errors.

           

          The fourth error is related to the fact that the HomePageViewCollaboration protocol begins with an interaction from HomePageViewParticipant, and therefore the 'run' of this protocol is considered to be initiated by this participant also (hence the 'from HomePageViewParticipant' at the end of the run clause. However the choice in the top level protocol is located at the UserLogServiceParticipant participant (i.e. it is the decision maker). So the problem is, how can this participant make the decision about which choice path to take, but another participant act on that decision, without their being any communication between those two participants - so essentially there is a disconnect here.

           

          This 'unconnected activity' error occurs in a number of other places in this protocol. Essentially if two activities are defined in sequence (or directly dependent as in the case of choice paths), then the activities must be linked. If a sequence contains two activities with totally unrelated participants, then how can they be sequenced?

           

          Hope this helps.

           

          Regards

          Gary

          • 2. Re: How do I write CDM's that can generate BPMN2
            objectiser

            Have created a jira for the first issue: https://issues.jboss.org/browse/SAVARA-345

            • 3. Re: How do I write CDM's that can generate BPMN2
              objectiser

              http://hudson.jboss.org/hudson/view/SAVARA/job/savara-tools-eclipse-master/596/artifact/sources/site/target/site_assembly.zip

               

              This is a snapshot build with a fix for localising the role introductions correctly. This was being done, but didn't work when the role was only used in a sub-protocol - which it does now.

               

              When testing out a snapshap, best to use a fresh temporary environment, as the plugins cannot subsequently be overwritten with other snapshot builds.

               

              Regards

              Gary