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

1.13.x blue merge #1689

Merged
merged 13 commits into from
Sep 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .ci/jenkins/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ pipeline {
echo '' > content_sets.yaml
sed -i 's|from: "registry.redhat.io/ubi8|from: "registry.access.redhat.com/ubi8|g' bamoe-kogito-*.yaml
sed -i 's/\\(| KOGITO_VERSION.* | .* |\\)/\\1\\n | QUARKUS_PLUGIN | io.quarkus:quarkus-maven-plugin |\\n | QUARKUS_PLATFORM_GROUP_ID | io.quarkus.platform |/g' tests/features/*.feature
sed -i 's|Using Quarkus com.redhat.quarkus.platform:quarkus-maven-plugin|Using Quarkus io.quarkus:quarkus-maven-plugin|g' tests/features/*.feature
git diff
"""
}
Expand Down
6 changes: 3 additions & 3 deletions .ci/jenkins/dsl/jobs.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ setupProdUpdateVersionJob()
void setupPrJob(boolean isProdCI = false, boolean isNextBranch = false) {
def jobParams = getDefaultJobParams()
jobParams.pr.putAll([
run_only_for_branches: [ Utils.getGitBranch(this) ],
disable_status_message_error: true,
disable_status_message_failure: true,
run_only_for_branches: [ Utils.getGitBranch(this) ],
disable_status_message_error: true,
disable_status_message_failure: true,
])
if (isProdCI) {
jobParams.job.name += '.prod'
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr-backporting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
steps:
- name: Set target branches
id: set-targets
uses: kiegroup/kogito-pipelines/.ci/actions/parse-labels@main
uses: kiegroup/kie-ci/.ci/actions/parse-labels@main
with:
labels: ${LABELS}

Expand All @@ -34,7 +34,7 @@ jobs:
REVIEWERS: ${{ toJSON(github.event.pull_request.requested_reviewers) }}
steps:
- name: Backporting
uses: kiegroup/kogito-pipelines/.ci/actions/backporting@main
uses: kiegroup/kie-ci/.ci/actions/backporting@main
with:
target-branch: ${{ matrix.target-branch }}
additional-reviewers: ${REVIEWERS}
2 changes: 1 addition & 1 deletion bamoe-kogito-builder-rhel8-overrides.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
schema_version: 1

name: "ibm-bamoe/bamoe-kogito-builder-rhel8"
version: "8.0.3"
version: "8.0.4"
from: "registry.redhat.io/ubi8/ubi-minimal:latest"
description: "IBM BAMOE Platform for building Kogito based on Quarkus or SpringBoot"

Expand Down
18 changes: 9 additions & 9 deletions bamoe-kogito-imagestream.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,18 @@ items:
openshift.io/provider-display-name: IBM, Inc.
spec:
tags:
- name: '8.0.3'
- name: '8.0.4'
annotations:
description: IBM BAMOE Runtime image for Kogito based on Quarkus or SpringBoot JVM image
iconClass: icon-jbpm
tags: ibm-bamoe-kogito,runtime,kogito,quarkus,springboot,jvm
supports: quarkus
version: '8.0.3'
version: '8.0.4'
referencePolicy:
type: Local
from:
kind: DockerImage
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-runtime-jvm-rhel8:8.0.3
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-runtime-jvm-rhel8:8.0.4
- kind: ImageStream
apiVersion: v1
metadata:
Expand All @@ -36,18 +36,18 @@ items:
openshift.io/provider-display-name: IBM, Inc.
spec:
tags:
- name: '8.0.3'
- name: '8.0.4'
annotations:
description: IBM BAMOE Runtime image for Kogito based on Quarkus native image
iconClass: icon-jbpm
tags: ibm-bamoe-kogito,runtime,kogito,quarkus,native
supports: quarkus
version: '8.0.3'
version: '8.0.4'
referencePolicy:
type: Local
from:
kind: DockerImage
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-runtime-native-rhel8:8.0.3
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-runtime-native-rhel8:8.0.4
- kind: ImageStream
apiVersion: v1
metadata:
Expand All @@ -57,15 +57,15 @@ items:
openshift.io/provider-display-name: IBM, Inc.
spec:
tags:
- name: '8.0.3'
- name: '8.0.4'
annotations:
description: IBM BAMOE Platform for building Kogito based on Quarkus or SpringBoot
iconClass: icon-jbpm
tags: ibm-bamoe-kogito,builder,kogito,quarkus,springboot
supports: quarkus
version: '8.0.3'
version: '8.0.4'
referencePolicy:
type: Local
from:
kind: DockerImage
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-builder-rhel8:8.0.3
name: registry.connect.redhat.com/ibm-bamoe/bamoe-kogito-builder-rhel8:8.0.4
2 changes: 1 addition & 1 deletion bamoe-kogito-runtime-jvm-rhel8-overrides.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
schema_version: 1

name: "ibm-bamoe/bamoe-kogito-runtime-jvm-rhel8"
version: "8.0.3"
version: "8.0.4"
from: "registry.redhat.io/ubi8/ubi-minimal:latest"
description: "IBM BAMOE Runtime image for Kogito based on Quarkus or SpringBoot JVM image"

Expand Down
2 changes: 1 addition & 1 deletion bamoe-kogito-runtime-native-rhel8-overrides.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
schema_version: 1

name: "ibm-bamoe/bamoe-kogito-runtime-native-rhel8"
version: "8.0.3"
version: "8.0.4"
from: "registry.redhat.io/ubi8/ubi-minimal:latest"
description: "IBM BAMOE Runtime image for Kogito based on Quarkus native image"

Expand Down
2 changes: 1 addition & 1 deletion modules/bamoe-kogito-profile/module.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
schema_version: 1
name: bamoe.prod.profile
version: '8.0.3'
version: '8.0.4'
description: Holds custom configurations for BAMOE Kogito images. Add as the last module as it can depend on other modules.

envs:
Expand Down
3 changes: 2 additions & 1 deletion modules/kogito-openjdk/11-headless/module.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ envs:

packages:
install:
- java-11-openjdk-headless
- tzdata-java # Fix for new openjdk installations. See https://bugzilla.redhat.com/show_bug.cgi?id=2224411
- java-11-openjdk-headless
3 changes: 2 additions & 1 deletion modules/kogito-openjdk/11/module.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,6 @@ execute:

packages:
install:
- java-11-openjdk-devel
- tzdata-java # Fix for new openjdk installations. See https://bugzilla.redhat.com/show_bug.cgi?id=2224411
- java-11-openjdk-devel

28 changes: 7 additions & 21 deletions tests/features/kogito-builder-native.feature
Original file line number Diff line number Diff line change
Expand Up @@ -83,32 +83,19 @@ Feature: kogito-builder image native build tests
# And s2i build log should contain '/home/kogito/bin/persons.proto' -> '/home/kogito/data/protobufs/persons.proto'
# And s2i build log should contain -J-Xmx5153960755

Scenario: Perform a incremental s2i build for native test
Given s2i build https://github.com/kiegroup/kogito-examples.git from rules-quarkus-helloworld with env and incremental using nightly-1.13.x-blue
Scenario: Perform an incremental s2i build for native test
Given s2i build https://github.com/kiegroup/kogito-examples.git from kogito-quarkus-examples/rules-quarkus-helloworld with env and incremental using nightly-main
| variable | value |
| RUNTIME_TYPE | quarkus |
| NATIVE | false |
Then s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
And file /home/kogito/bin/quarkus-run.jar should exist
And check that page is served
| property | value |
| port | 8080 |
| path | /hello |
| request_method | POST |
| content_type | application/json |
| request_body | {"strings":["hello"]} |
| wait | 80 |
| expected_phrase | ["hello","world"] |

# Since the same image is used we can do a subsequent incremental build and verify if it is working as expected.
Scenario:Perform a second incremental s2i build for native scenario, this time, with native enabled
Given s2i build https://github.com/kiegroup/kogito-examples.git from rules-quarkus-helloworld with env and incremental using nightly-1.13.x-blue
And s2i build https://github.com/kiegroup/kogito-examples.git from kogito-quarkus-examples/rules-quarkus-helloworld with env and incremental using nightly-main
| variable | value |
| RUNTIME_TYPE | quarkus |
| NATIVE | true |
| LIMIT_MEMORY | 6442450944 |
Then s2i build log should contain Expanding artifacts from incremental build...
And s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
Then s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
And s2i build log should contain Expanding artifacts from incremental build...
And s2i build log should contain -J-Xmx5153960755
And file /home/kogito/bin/rules-quarkus-helloworld-runner should exist
And check that page is served
| property | value |
Expand All @@ -118,8 +105,7 @@ Feature: kogito-builder image native build tests
| content_type | application/json |
| request_body | {"strings":["hello"]} |
| wait | 80 |
| expected_phrase | ["hello","world"] |
And s2i build log should contain -J-Xmx5153960755
| expected_phrase | ["hello","world"] |

Scenario: Verify that the Kogito Maven archetype is generating the project and compiling it correctly using native build
Given s2i build /tmp/kogito-examples from dmn-example using nightly-1.13.x-blue and runtime-image quay.io/kiegroup/kogito-runtime-native:latest
Expand Down
54 changes: 18 additions & 36 deletions tests/features/kogito-common-builder-jvm.feature
Original file line number Diff line number Diff line change
Expand Up @@ -86,31 +86,17 @@ Feature: kogito-builder image JVM build tests
| expected_phrase | ["hello","world"] |
And file /home/kogito/bin/quarkus-run.jar should exist

Scenario: Perform a incremental s2i build using quarkus runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from rules-quarkus-helloworld with env and incremental using nightly-1.13.x-blue
Scenario: Perform an incremental s2i build using quarkus runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from kogito-quarkus-examples/rules-quarkus-helloworld with env and incremental using nightly-main
| variable | value |
| RUNTIME_TYPE | quarkus |
| NATIVE | false |
Then s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
And file /home/kogito/bin/quarkus-run.jar should exist
And check that page is served
| property | value |
| port | 8080 |
| path | /hello |
| request_method | POST |
| content_type | application/json |
| request_body | {"strings":["hello"]} |
| wait | 80 |
| expected_phrase | ["hello","world"] |

# Since the same image is used we can do a subsequent incremental build and verify if it is working as expected.
Scenario: Perform a second incremental s2i build using quarkus runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from rules-quarkus-helloworld with env and incremental using nightly-1.13.x-blue
And s2i build https://github.com/kiegroup/kogito-examples.git from kogito-quarkus-examples/rules-quarkus-helloworld with env and incremental using nightly-main
| variable | value |
| RUNTIME_TYPE | quarkus |
| NATIVE | false |
Then s2i build log should contain Expanding artifacts from incremental build...
And s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
Then s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
And s2i build log should contain Expanding artifacts from incremental build...
And file /home/kogito/bin/quarkus-run.jar should exist
And check that page is served
| property | value |
Expand All @@ -122,7 +108,6 @@ Feature: kogito-builder image JVM build tests
| wait | 80 |
| expected_phrase | ["hello","world"] |


#### SpringBoot Scenarios

Scenario: Verify if the s2i build is finished as expected with debug enabled
Expand Down Expand Up @@ -199,30 +184,27 @@ Feature: kogito-builder image JVM build tests
And container log should contain Started KogitoSpringbootApplication
And run sh -c 'echo $JAVA_OPTIONS' in container and immediately check its output for -Ddebug=true

Scenario: Perform a incremental s2i build using springboot runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from ruleunit-springboot-example with env and incremental using nightly-1.13.x-blue
Scenario: Perform an incremental s2i build using springboot runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from kogito-springboot-examples/process-springboot-example with env and incremental using nightly-main
# Leave those here as placeholder for scripts adding variable to the test. No impact on tests if empty.
| variable | value |
| RUNTIME_TYPE | springboot |
Then check that page is served
| property | value |
| port | 8080 |
| path | /find-approved |
| wait | 80 |
| request_method | POST |
| request_body | {"maxAmount":5000,"loanApplications":[{"id":"ABC10001","amount":2000,"deposit":100,"applicant":{"age":45,"name":"John"}}]} |
| content_type | application/json |
| expected_status_code | 200 |
And file /home/kogito/bin/ruleunit-springboot-example.jar should exist

# Since the same image is used we can do a subsequent incremental build and verify if it is working as expected.
Scenario: Perform a second incremental s2i build using springboot runtime type
Given s2i build https://github.com/kiegroup/kogito-examples.git from ruleunit-springboot-example with env and incremental using nightly-1.13.x-blue
And s2i build https://github.com/kiegroup/kogito-examples.git from kogito-springboot-examples/process-springboot-example with env and incremental using nightly-main
# Leave those here as placeholder for scripts adding variable to the test. No impact on tests if empty.
| variable | value |
| RUNTIME_TYPE | springboot |
Then s2i build log should contain Expanding artifacts from incremental build...
And s2i build log should not contain WARNING: Clean build will be performed because of error saving previous build artifacts
And file /home/kogito/bin/process-springboot-example.jar should exist
And check that page is served
| property | value |
| port | 8080 |
| path | /orders |
| wait | 80 |
| request_method | POST |
| request_body | {"approver" : "john", "order" : {"orderNumber" : "12345", "shipped" : false}} |
| content_type | application/json |
| expected_status_code | 201 |

Scenario: Verify if the s2i build is finished as expected with uber-jar package type built
Given s2i build https://github.com/kiegroup/kogito-examples.git from ruleunit-quarkus-example using nightly-1.13.x-blue and runtime-image quay.io/kiegroup/kogito-runtime-jvm:latest
Expand Down
Loading