[KOGITO-3296] - Upgrading Infinispan CRD and fixing custom credential… #555
Conversation
…s bug Signed-off-by: Ricardo Zanini <zanini@redhat.com>
Codecov Report
@@ Coverage Diff @@
## master #555 +/- ##
==========================================
- Coverage 42.01% 37.43% -4.58%
==========================================
Files 169 160 -9
Lines 9012 7915 -1097
==========================================
- Hits 3786 2963 -823
+ Misses 4812 4606 -206
+ Partials 414 346 -68
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
@@ -105,44 +82,33 @@ func CreateRequiredResources(kogitoInfra *v1alpha1.KogitoInfra, cli *client.Clie | |||
} | |||
|
|||
func newInfinispanResource(kogitoInfra *v1alpha1.KogitoInfra) *infinispan.Infinispan { | |||
infinispanRes := &infinispan.Infinispan{ | |||
return &infinispan.Infinispan{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Kindly verify if this function make more sence in infrastucture/infinispan
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just to create the custom k8s resource (as we create a Deployment for example), it's not a role of the shared infrasctructure
package. It meant to have shared functions among the controllers only. This package will be refactored soon and the Infinispan CR creation dropped.
/jenkins test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
@sutaakar do you mind verifying this manually as well? :( |
sure, will try |
@ricardozanini Checked using external credentials and generated credentials for both Infinispan operator 1.1.x and 2.0.x - both works ok (for Infinispan 2.0.x the Data index crash as it is not yet compatible, which is expected). Credentials are passed from Infinispan secret to Kogito one. |
MANY THANKS for this super verification, @sutaakar . I'm pushing @vaibhavjainwiz suggestions, and as soon as we merge #558 I think we can run this CI again. |
Signed-off-by: Ricardo Zanini <zanini@redhat.com>
Change detected in the PR, requesting reviews and running pipeline(if required) again |
/jenkins test |
Keycloak only failure, merging. |
* add explainability service * fix tests * add command for explainability * add operator expl * add explainability BDD * fix tests * update yaml example * fix crds, rebase * inject kogitoruntime route into kogitoexplainability, implement integration test * fix getJSON error * remove env var injection in expl service * fix bats * Update kogitoruntime_controller.go * add explainability service remove operation * Update kogitoexplainability.go * Update pkg/apis/app/v1alpha1/kogitoexplainability_types.go Co-authored-by: Ricardo Zanini <1538000+ricardozanini@users.noreply.github.com> * rebase * Update cmd/kogito/command/shared/install_services.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update cmd/kogito/command/shared/install_services.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update app.kiegroup.org_v1alpha1_kogitoexplainability_cr.yaml * Update cmd/kogito/command/shared/install_services.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update pkg/controller/kogitoexplainability/kogitoexplainability_controller.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update test/features/install_explainability.feature Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update install_explainability.feature * Update test/steps/kogitoexplainability.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * set kogito runtime external uri in explaination bdd test * Update test/features/install_explainability.feature Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update kogitoexplainability.go * Update cr_to_cli.go * Update cr_to_cli.go * Update deployer.go * Update install_explainability.feature * Update create_kogito_service.go * make test * Update kogitoexplainability.go * Update deployer.go * Update deployer.go * revert deployer changes * fix response content explainability * [KOGITO-3323] Tests: Update scenario description to be unique for every run (#554) Signed-off-by: Karel Suta <ksuta@redhat.com> * KOGITO-3176 - disable standalone trusty test due to kafka change (#558) * Update install_trusty.feature * disable test * [KOGITO-3335] Tests: Split current tests to operator and integration (#562) Signed-off-by: Karel Suta <ksuta@redhat.com> * Update explainability.go * [KOGITO-3296] - Upgrading Infinispan CRD and fixing custom credential… (#555) * [KOGITO-3296] - Upgrading Infinispan CRD and fixing custom credentials bug Signed-off-by: Ricardo Zanini <zanini@redhat.com> * Applied peer review changes (secret/comparator) Signed-off-by: Ricardo Zanini <zanini@redhat.com> * KOGITO-3332: Check whether jobs service is ready before deploying service (#556) * KOGITO-3181 - add trusty ui scorecard/controller/tests (#537) * add trusty ui controller and tests * add trusty and trusty-ui remove operation * inject trusty route * Update pkg/apis/app/v1alpha1/kogitotrustyui_types.go Co-authored-by: Ricardo Zanini <1538000+ricardozanini@users.noreply.github.com> * remove routes, fix typos * make vet * add bats tests * add tests * fix typo in bdd test * fix * Update test/steps/kogitotrustyui.go Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update test/features/install_trustyui.feature Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update test/features/install_trustyui.feature Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update test/features/install_trustyui.feature Co-authored-by: Karel Suta <krlsuta@gmail.com> * Update kogitotrusty_ui_controller.go * update comments * update comments Co-authored-by: Ricardo Zanini <1538000+ricardozanini@users.noreply.github.com> Co-authored-by: Karel Suta <krlsuta@gmail.com> * KOGITO-3340: Cucumber Tests: Projects that use Keycloak remains as Terminating (#564) * rebase * rebase * Revert "KOGITO-3340: Cucumber Tests: Projects that use Keycloak remains as Terminating (#564)" This reverts commit 3fa1d80. * Revert "KOGITO-3332: Check whether jobs service is ready before deploying service (#556)" This reverts commit 1438671. * Revert "[KOGITO-3323] Tests: Update scenario description to be unique for every run (#554)" This reverts commit f94946e. * Revert "[KOGITO-3335] Tests: Split current tests to operator and integration (#562)" This reverts commit 745f8d7. * add logs Co-authored-by: Ricardo Zanini <1538000+ricardozanini@users.noreply.github.com> Co-authored-by: Karel Suta <krlsuta@gmail.com> Co-authored-by: Karel Suta <ksuta@redhat.com> Co-authored-by: Jose Carvajal <josecarvajalhilario@gmail.com>
…s bug
See: https://issues.redhat.com/browse/KOGITO-3296
In this PR we upgrade the Infinispan CRDs, so now users can use the 2.x channel from the OLM installation. Also, the generated secret from Infinispan is now attached to our secret, which will be injected into the KogitoService.
I made a clean up in the KogitoInfra controller package, which will help KOGITO-3039 as well.
@r00ta please review your reproducer, the identities.yaml file had the wrong name. To add a custom credential to a KogitoService, you only have to create a custom Infinispan credential secret, add it to the Infinispan CR and make your KogitoService to use the infra provided by us. If you would create your own Infinispan CR, just add the custom credentials there the same way you did, create a new secret for the KogitoService with the same credentials but with different format and add everything manually to the KogitoService. Is not the ideal, but KOGITO-3039 will fix that. You would create your own Infinispan and tell the Kogito Operator that you would like to use that reference, every thing will be done for you.
cc @vaibhavjainwiz
@sutaakar I didn't make great changes in this PR, I think would be a nice addition to 0.15 so people won't have problems with the Infinispan CRD any more.
Signed-off-by: Ricardo Zanini zanini@redhat.com
Many thanks for submiting your Pull Request ❤️!
Please make sure that your PR meets the following requirements:
[KOGITO-XYZ] Subject