6 Replies Latest reply on Jan 12, 2006 12:07 PM by Koen Aers

    Externally crafted XML does not deploy

    Michael Holtzman Newbie

      Greetings! I am building a process definition in jpdl from our own application, and need to deploy it in jbpm.

      If I follow the instructions in http://www.jboss.com/index.html?module=bb&op=viewtopic&t=71393
      I get a graph with all elements in the top left, but I cannot resize or relocate anything but the transition labels.

      The xml is legal according to the schema (no errors flagged in the source view), but when I try to deploy it this method fails silently.

       ProcessDefinition definition = ProcessDefinition.parseXmlResource(processName);
      

      (jbpm terminates without reporting any errors)

      This is jbpm 3.0.2 and GPD 3.0.5

      My process definition xml:

      <?xml version="1.0" encoding="UTF-8"?>
      <process-definition
      
       xmlns="http://jbpm.org/3/jpdl"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://jbpm.org/3/jpdl http://jbpm.org/xsd/jpdl-3.0.xsd"
      
       name="SettlementProcess">
      
       <start-state name="Start">
       <transition name="StartTransition" to="StartingCheckout" />
       </start-state>
      
       <end-state name="Stop" />
      
       <fork name="StartingCheckout">
       <transition name="1_ReferenceDataCheck" to="ReferenceDataCheck" />
      
       <transition name="1_CreatePrelimInvoice" to="CreatePrelimInvoice" />
      
       <transition name="1_ManualCheckout" to="ManualCheckout" />
       </fork>
      
       <node name="ReferenceDataCheck">
       <action class="com.olf.workflowmgr.action.AvsScriptActionHandler">
       <scriptName>validate_reference_data</scriptName>
       </action>
      
       <transition name="2_WaitForCheckout" to="WaitForCheckout" />
      
       <event type="node-enter">
       <action name="2_node-enter" class="com.olf.workflowmgr.action.VariableToArgtActionHandler">
       <variableName>DocId</variableName>
       </action>
       </event>
      
       <event type="node-leave">
       <action name="2_node-leave" class="com.olf.workflowmgr.action.ReturntToVariableActionHandler">
       <variableName>ReferenceData</variableName>
       </action>
       </event>
       </node>
      
       <node name="CreatePrelimInvoice">
       <action class="com.olf.workflowmgr.action.AvsScriptActionHandler">
       <scriptName>produce_prelim_invoice</scriptName>
       </action>
      
       <transition name="3_WaitForCheckout" to="WaitForCheckout" />
      
       <event type="node-enter">
       <action name="3_node-enter" class="com.olf.workflowmgr.action.VariableToArgtActionHandler">
       <variableName>DocId</variableName>
       </action>
       </event>
      
       <event type="node-leave">
       <action name="3_node-leave" class="com.olf.workflowmgr.action.ReturntToVariableActionHandler">
       <variableName>TotalInvoiceAmount</variableName>
       </action>
       </event>
       </node>
      
       <task-node name="ManualCheckout">
       <task name="ManualCheckout_4" blocking="true">
       <assignment class="com.olf.workflowmgr.action.TaskAssignmentHandler">
       <assignee>ops</assignee>
       </assignment>
       </task>
      
       <transition name="4_WaitForCheckout" to="WaitForCheckout" />
       </task-node>
      
       <join name="WaitForCheckout">
       <transition name="5_ValidateCheckOut" to="ValidateCheckOut" />
       </join>
      
       <decision name="ValidateCheckout">
       <transition name="6_Stop" to="Stop">
       <condition>! "Valid".equals( (String)ReferenceData)</condition>
       </transition>
      
       <transition name="6_Stop" to="Stop">
       <condition>! "Confirmed".equals( (String)PaymentDateConfirmed)</condition>
       </transition>
      
       <transition name="6_Stop" to="Stop">
       <condition>! "Confirmed".equals( (String)AmountConfirmed)</condition>
       </transition>
      
       <transition name="6_Stop" to="Stop">
       <condition>! "Confirmed".equals( (String)InstructionsConfirmed)</condition>
       </transition>
      
       <transition name="6_Stop" to="Stop">
       <condition>! "No".equals( (String)Descrepency)</condition>
       </transition>
      
       <transition name="6_Stop" to="Stop">
       <condition>! ((String)TotalInvoiceAmount).equals( (String)CustomerAmount)</condition>
       </transition>
      
       <transition name="6_CheckPaymentAmount" to="CheckPaymentAmount" />
       </decision>
      
       <decision name="CheckPaymentAmount">
       <transition name="7_ManagementApproval" to="ManagementApproval">
       <condition>"Yes".equals( (String)CashAdjustment)</condition>
       </transition>
      
       <transition name="7_ManagementApproval" to="ManagementApproval">
       <condition>// "10000"GTTotalInvoiceAmount</condition>
       </transition>
      
       <transition name="7_InvoiceApproved" to="InvoiceApproved" />
       </decision>
      
       <task-node name="ManagementApproval">
       <task name="ManagementApproval_8" blocking="true">
       <assignment class="com.olf.workflowmgr.action.TaskAssignmentHandler">
       <assignee>manager</assignee>
       </assignment>
       </task>
      
       <transition name="8_InvoiceApproved" to="InvoiceApproved">
      <script>
      <expression>"Yes".equals( (String)ManagementApproval)
      
       </expression>
      </script>
       </transition>
      
       <transition name="8_Stop" to="Stop" />
       </task-node>
      
       <fork name="InvoiceApproved">
       <transition name="9_InvoiceToCounterParty" to="InvoiceToCounterParty" />
      
       <transition name="9_PaymentToPaymentSystem" to="PaymentToPaymentSystem" />
       </fork>
      
       <node name="SendInvoice">
       <action class="com.olf.workflowmgr.action.AvsScriptActionHandler">
       <scriptName>send_invoice</scriptName>
       </action>
      
       <transition name="10_CheckResult" to="CheckResult" />
      
       <event type="node-enter">
       <action name="10_node-enter" class="com.olf.workflowmgr.action.VariableToArgtActionHandler">
       <variableName>DocId</variableName>
       </action>
       </event>
       </node>
      
       <node name="SendDataToPaymentSystem">
       <action class="com.olf.workflowmgr.action.AvsScriptActionHandler">
       <scriptName>send_payment</scriptName>
       </action>
      
       <transition name="11_CheckResult" to="CheckResult" />
      
       <event type="node-enter">
       <action name="11_node-enter" class="com.olf.workflowmgr.action.VariableToArgtActionHandler">
       <variableName>DocId</variableName>
       </action>
       </event>
       </node>
      
       <join name="CheckResult">
       <transition name="12_Finished" to="Finished" />
       </join>
      
       <decision name="Finished">
       <transition name="13_Stop" to="Stop">
       <condition>! "FinalInvoiceSent".equals( (String)InvoiceDeliveryStage)</condition>
       </transition>
      
       <transition name="13_Stop" to="Stop">
       <condition>! "ToBePaid".equals( (String)PaymentDeliveryStage)</condition>
       </transition>
      
       <transition name="13_Stop" to="Stop" />
       </decision>
      </process-definition>
      


      Any suggestions. Thanx.