Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[incubator-kie-issues#847] Include generated-resources to quarkus artifact #3427

Merged
merged 9 commits into from
Mar 8, 2024

Conversation

gitgabrio
Copy link
Contributor

@gitgabrio gitgabrio commented Mar 5, 2024

Fixes apache/incubator-kie-issues#847
Requires apache/incubator-kie-drools#5765
Required by apache/incubator-kie-kogito-examples#1889

This PR add the "target/generated-resources" to the collection of scanned directory for resource discovery.
This is needed to allow inclusion of models from external artifacts.
Original discussion may be found here

How to replicate CI configuration locally?

Build Chain tool does "simple" maven build(s), the builds are just Maven commands, but because the repositories relates and depends on each other and any change in API or class method could affect several of those repositories there is a need to use build-chain tool to handle cross repository builds and be sure that we always use latest version of the code for each repository.

build-chain tool is a build tool which can be used on command line locally or in Github Actions workflow(s), in case you need to change multiple repositories and send multiple dependent pull requests related with a change you can easily reproduce the same build by executing it on Github hosted environment or locally in your development environment. See local execution details to get more information about it.

How to retest this PR or trigger a specific build:
  • for pull request checks
    Please add comment: Jenkins retest this

  • for a specific pull request check
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] tests

  • for quarkus branch checks
    Run checks against Quarkus current used branch
    Please add comment: Jenkins run quarkus-branch

  • for a quarkus branch specific check
    Run checks against Quarkus current used branch
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] quarkus-branch

  • for quarkus main checks
    Run checks against Quarkus main branch
    Please add comment: Jenkins run quarkus-main

  • for a specific quarkus main check
    Run checks against Quarkus main branch
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] quarkus-main

  • for quarkus lts checks
    Run checks against Quarkus lts branch
    Please add comment: Jenkins run quarkus-lts

  • for a specific quarkus lts check
    Run checks against Quarkus lts branch
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] quarkus-lts

  • for native checks
    Run native checks
    Please add comment: Jenkins run native

  • for a specific native check
    Run native checks
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] native

  • for native lts checks
    Run native checks against quarkus lts branch
    Please add comment: Jenkins run native-lts

  • for a specific native lts check
    Run native checks against quarkus lts branch
    Please add comment: Jenkins (re)run [kogito-runtimes|kogito-apps|kogito-examples] native-lts

How to backport a pull request to a different branch?

In order to automatically create a backporting pull request please add one or more labels having the following format backport-<branch-name>, where <branch-name> is the name of the branch where the pull request must be backported to (e.g., backport-7.67.x to backport the original PR to the 7.67.x branch).

NOTE: backporting is an action aiming to move a change (usually a commit) from a branch (usually the main one) to another one, which is generally referring to a still maintained release branch. Keeping it simple: it is about to move a specific change or a set of them from one branch to another.

Once the original pull request is successfully merged, the automated action will create one backporting pull request per each label (with the previous format) that has been added.

If something goes wrong, the author will be notified and at this point a manual backporting is needed.

NOTE: this automated backporting is triggered whenever a pull request on main branch is labeled or closed, but both conditions must be satisfied to get the new PR created.

Quarkus-3 PR check is failing ... what to do ? The Quarkus 3 check is applying patches from the `.ci/environments/quarkus-3/patches`.

The first patch, called 0001_before_sh.patch, is generated from Openrewrite .ci/environments/quarkus-3/quarkus3.yml recipe. The patch is created to speed up the check. But it may be that some changes in the PR broke this patch.
No panic, there is an easy way to regenerate it. You just need to comment on the PR:

jenkins rewrite quarkus-3

and it should, after some minutes (~20/30min) apply a commit on the PR with the patch regenerated.

Other patches were generated manually. If any of it fails, you will need to manually update it... and push your changes.

@gitgabrio gitgabrio requested a review from mariofusco March 7, 2024 07:57
@gitgabrio
Copy link
Contributor Author

Kogito -apps failure unrelated
continuous-integration failure unrelated -> [2024-03-06T10:51:01.539Z] Cannot contact jenkins-shared-ubuntu-2: java.lang.InterruptedException

@kie-ci3
Copy link
Contributor

kie-ci3 commented Mar 7, 2024

Copy link
Member

@porcelli porcelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would be possible to introduce some test for the changes? so we'd be able to make sure we won't have a regression in the future?

@kie-ci3
Copy link
Contributor

kie-ci3 commented Mar 8, 2024

@gitgabrio
Copy link
Contributor Author

gitgabrio commented Mar 8, 2024

@porcelli

would be possible to introduce some test for the changes? so we'd be able to make sure we won't have a regression in the future?

Just done
Note:

  1. I had to slightly refactor my modification for easy of testing
  2. that module has never been tested at all, so I made a very single, focalized test only for my modification

@gitgabrio
Copy link
Contributor Author

kogito-runtimes failure unrelated

2024-03-08T11:48:59.1873546Z ##[group]🚀 Publish results
2024-03-08T11:48:59.1875279Z ℹ️ - JUnit Test Report - 3305 tests run, 3246 passed, 52 skipped, 7 failed.
2024-03-08T11:48:59.1877149Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/rules/PublishEventBusinessRuleIT.java | expected: "2"
2024-03-08T11:48:59.1879759Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/tests/PublishEventIT.java | No value present
2024-03-08T11:48:59.1882231Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/tests/PublishEventIT.java | No value present
2024-03-08T11:48:59.1884687Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/tests/PublishEventIT.java | expected: 5
2024-03-08T11:48:59.1887112Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/tests/PublishEventIT.java | expected: "2"
2024-03-08T11:48:59.1889068Z    🧪 - apache_incubator-kie-kogito-runtimes/kogito-codegen-modules/kogito-codegen-processes-integration-tests/src/test/java/org/kie/kogito/codegen/tests/PublishEventIT.java | No value present
2024-03-08T11:48:59.1891914Z    🧪 - apache_incubator-kie-kogito-runtimes/quarkus/extensions/kogito-quarkus-serverless-workflow-extension/kogito-quarkus-serverless-workflow-integration-test/src/test/java/org/kie/kogito/quarkus/workflows/WorkflowEventIT.java | org.opentest4j.AssertionFailedError: expected: <ProcessInstanceStateEvent> but was: <ProcessInstanceStateDataEvent>
2024-03-08T11:48:59.1955106Z ##[error]expected: "2"
 but was: "0"
2024-03-08T11:48:59.1957097Z ##[error]No value present
2024-03-08T11:48:59.1958096Z ##[error]No value present
2024-03-08T11:48:59.1959043Z ##[error]expected: 5
 but was: 0
2024-03-08T11:48:59.1960232Z ##[error]expected: "2"
 but was: "0"
2024-03-08T11:48:59.1961179Z ##[error]No value present
2024-03-08T11:48:59.1962881Z ##[error]org.opentest4j.AssertionFailedError: expected: <ProcessInstanceStateEvent> but was: <ProcessInstanceStateDataEvent>
2024-03-08T11:48:59.1963749Z ##[endgroup]

@gitgabrio
Copy link
Contributor Author

Kogito-apps failure unrelated

##[group]🚀 Publish results
2024-03-08T12:28:42.4520450Z ℹ️ - JUnit Test Report - 1693 tests run, 1673 passed, 10 skipped, 10 failed.
2024-03-08T12:28:42.4524914Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/infinispan/ProcessDataIndexInfinispanHttpIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4530268Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/infinispan/ProcessDataIndexInfinispanKafkaIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4534119Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/inmemory/ProcessDataIndexInMemoryIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4537590Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/mongodb/ProcessDataIndexMongoDBHttpIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4541068Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/mongodb/ProcessDataIndexMongoDBKafkaIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4544585Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/postgresql/ProcessDataIndexPostgreSqlHttpIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4548131Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-quarkus/src/test/java/org/kie/kogito/index/postgresql/ProcessDataIndexPostgreSqlKafkaIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4551903Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexInfinispanIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4555406Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexMongoDBIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4558932Z    🧪 - apache_incubator-kie-kogito-apps/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexPostgreSqlIT.java | Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
2024-03-08T12:28:42.4598892Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4603175Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4606760Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.ProcessInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4610560Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4614217Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4617717Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.ProcessInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4621096Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.ProcessInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4624702Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4628335Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.Approvals[0].metadata.processInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4632159Z ##[error]Assertion condition defined as a org.kie.kogito.index.AbstractProcessDataIndexIT 1 expectation failed.
JSON path data.ProcessInstances[0].state doesn't match.
Expected: is "ACTIVE"
  Actual: PENDING
 within 30 seconds.
2024-03-08T12:28:42.4633481Z ##[endgroup]

@kie-ci3
Copy link
Contributor

kie-ci3 commented Mar 8, 2024

PR job #7 was: UNSTABLE
Possible explanation: This should be test failures

Reproducer

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 #3427 --skipParallelCheckout

NOTE: To install the build-chain tool, please refer to https://github.com/kiegroup/github-action-build-chain#local-execution

Please look here: https://ci-builds.apache.org/job/KIE/job/kogito/job/main/job/pullrequest_jobs/job/kogito-runtimes-pr/job/PR-3427/7/display/redirect

Test results:

  • PASSED: 2270
  • FAILED: 8

Those are the test failures:

org.jbpm.bpmn2.IntermediateEventTest.testEventSubprocessWithEmbeddedSignals testEventSubprocessWithEmbeddedSignals() timed out after 3000 seconds
org.jbpm.bpmn2.StartEventTest.testTimerStartCycleLegacy testTimerStartCycleLegacy() timed out after 3000 seconds
org.kie.kogito.codegen.rules.PublishEventBusinessRuleIT.testBusinessRuleProcessStartToEnd
expected: "2"
but was: "0"
org.kie.kogito.codegen.tests.PublishEventIT.testBasicUserTaskProcessAbort No value present
org.kie.kogito.codegen.tests.PublishEventIT.testBasicUserTaskProcessWithSecurityRoles No value present
org.kie.kogito.codegen.tests.PublishEventIT.testServiceTaskProcessWithError
expected: 5
but was: 0
org.kie.kogito.codegen.tests.PublishEventIT.testExclusiveGatewayStartToEnd
expected: "2"
but was: "0"
org.kie.kogito.codegen.tests.PublishEventIT.testBasicUserTaskProcess No value present

Copy link
Member

@porcelli porcelli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd love to see if we could adjust some of the code to use NIO2 api and not manipulate strings to check file extensions. but can be done in different PR.

@gitgabrio gitgabrio merged commit d994d02 into apache:main Mar 8, 2024
3 of 6 checks passed
@gitgabrio gitgabrio deleted the incubator-kie-issues#847 branch March 8, 2024 15:00
rgdoliveira pushed a commit to rgdoliveira/kogito-runtimes that referenced this pull request Mar 11, 2024
…ifact (apache#3427)

* [incubator-kie-issues#847] WIP

* [incubator-kie-issues#847] Fix for execution during test

* [incubator-kie-issues#847] Fix for execution during test

* [incubator-kie-issues#847] Small refactoring for test. Add KogitoAssetsProcessorTest

---------

Co-authored-by: Gabriele-Cardosi <gabriele.cardosi@ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Quarkus + Kogito extension Maven project with generated DMN resources from another Maven dependency
7 participants