You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "Abhitocode (via GitHub)" <gi...@apache.org> on 2025/04/04 13:37:28 UTC

[PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Abhitocode opened a new pull request, #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885

   The goal of this JIRA is to support the #{var_name} syntax in the Business Rules task handler for both DRL and DMN execution.
   During process instance execution, the defined process variables need to be set. When the Business Rules task handler is executed, it will find and execute the correct rule or decision based on the variable content.
   
   The variable is resolved within DecisionRuleTypeEngineImpl.java
   
   ![image](https://github.com/user-attachments/assets/641aa04f-d14f-4267-8c2f-b04bde6aa5a5)
   
   
   What I understood is if we get #var format in (inputModel), it can resolve exact value of that variable.
   
   In BusinessRuleTaskHandler when we assign a value we have to check if it has an expression or not "if(!fromDefinition.hasExpression())" If it doesn't have expression it will be variable. So kept value as variable format, then its going to be be resolved at evaluate method within DecisionRuleTypeEngineImpl.java.
   
   
   
   Tested the above implementation with testDMNBusinessRuleTask ith in ActivityTest.class 
   Changed the ![CDATA[0020-vacation-days]]> in the bpmn file to <![CDATA[#{modelName}]]> and tested.
   
   Closes: https://github.com/apache/incubator-kie-issues/issues/1913
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Posted by "elguardian (via GitHub)" <gi...@apache.org>.
elguardian commented on PR #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885#issuecomment-2782536023

   @Abhitocode what is the goal os changing the handler/parser ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Posted by "Abhitocode (via GitHub)" <gi...@apache.org>.
Abhitocode commented on PR #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885#issuecomment-2783531113

   The parser change is needed to keep the variable formats (e.g., #{modelName} unchanged during BPMN parsing so they can be resolved at runtime instead of being resolved early.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Posted by "martinweiler (via GitHub)" <gi...@apache.org>.
martinweiler commented on PR #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885#issuecomment-2847763030

   @Abhitocode thanks for the PR
   
   The issue is described as _to support the #{var_name} syntax in the Business Rules task handler for both DRL and DMN execution._
   
   Is your PR working for DRLs as well? Could you add another test for DRLs with ruleflow groups / rule units? Thanks!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Posted by "kie-ci3 (via GitHub)" <gi...@apache.org>.
kie-ci3 commented on PR #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885#issuecomment-2850001439

   
   **PR job** `#5` was: **UNSTABLE**
   Possible explanation: This should be test failures
   
   
   <details>
   <summary><b>Reproducer</b></summary>
   
   
   
   build-chain build full_downstream  -f 'https://raw.githubusercontent.com/${AUTHOR:apache}/incubator-kie-kogito-pipelines/${BRANCH:main}/.ci/buildchain-config-pr-cdb.yaml' -o 'bc' -p apache/incubator-kie-kogito-runtimes -u https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885 --skipParallelCheckout
   
   NOTE: To install the build-chain tool, please refer to https://github.com/kiegroup/github-action-build-chain#local-execution
   
   </details>
   
   
   Please look here: https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3885/5/display/redirect
   
   **Test results:**
   - PASSED: 3581
   - FAILED: 4
   
   Those are the test failures: 
   <details>
   <summary><a href="https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3885/5/testReport/io.quarkus.it.kogito.devmode/DevMojoIT/testDRLHotReload/">io.quarkus.it.kogito.devmode.DevMojoIT.testDRLHotReload</a></summary>
   1 expectation failed.<br/>Expected status code <200> but was <404>.<br/>
   </details>
   <details>
   <summary><a href="https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3885/5/testReport/io.quarkus.it.kogito.devmode/DevMojoIT/testDMNHotReload/">io.quarkus.it.kogito.devmode.DevMojoIT.testDMNHotReload</a></summary>
   1 expectation failed.<br/>Expected status code <200> but was <404>.<br/>
   </details>
   <details>
   <summary><a href="https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3885/5/testReport/io.quarkus.it.kogito.devmode/DevMojoIT/testStaticResource/">io.quarkus.it.kogito.devmode.DevMojoIT.testStaticResource</a></summary>
   1 expectation failed.<br/>Expected status code <200> but was <404>.<br/>
   </details>
   <details>
   <summary><a href="https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3885/5/testReport/io.quarkus.it.kogito.devmode/DevMojoIT/testBPMN2HotReload/">io.quarkus.it.kogito.devmode.DevMojoIT.testBPMN2HotReload</a></summary>
   1 expectation failed.<br/>Expected status code <201> but was <404>.<br/>
   </details>
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org


Re: [PR] [Incubator-kie-issues#1913] Ability to dynamically run a Decision based on process variables [incubator-kie-kogito-runtimes]

Posted by "Abhitocode (via GitHub)" <gi...@apache.org>.
Abhitocode commented on PR #3885:
URL: https://github.com/apache/incubator-kie-kogito-runtimes/pull/3885#issuecomment-2847767916

   @martinweile, sure will update the pr with a test for drl as well. Thank you.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org