-
Notifications
You must be signed in to change notification settings - Fork 524
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
refactor (jkube-kit/config) : Move OpenShift S2I Build configuration fields from BuildServiceConfig to Image's BuildConfiguration #2378
Conversation
Eclipse JKube CI ReportStarted new GH workflow run for #2378 (2024-04-25T13:41:36Z) ⚙️ JKube E2E Tests (8833496308)
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2378 +/- ##
=============================================
+ Coverage 59.36% 70.58% +11.22%
- Complexity 4586 5027 +441
=============================================
Files 500 487 -13
Lines 21211 19471 -1740
Branches 2830 2511 -319
=============================================
+ Hits 12591 13743 +1152
+ Misses 7370 4504 -2866
+ Partials 1250 1224 -26 ☔ View full report in Codecov by Sentry. |
dc07393
to
743d426
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs 82.5% Coverage The version of Java (11.0.18) you have used to run this analysis is deprecated and we will stop accepting it soon. Please update to at least Java 17. |
0806a0e
to
9a2f15d
Compare
String
/boolean
fields from BuildServiceConfig to Image's BuildConfiguration
9a2f15d
to
e953f56
Compare
String
/boolean
fields from BuildServiceConfig to Image's BuildConfiguration41e14c6
to
5a52803
Compare
473330c
to
9329701
Compare
@@ -220,6 +221,8 @@ protected File getManifest(KubernetesClient kc) { | |||
return manifest; | |||
} | |||
|
|||
protected void postProcessResolvedImages() { } |
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.
we'll need to discuss this again, the idea we discussed was not to post-process the resulting images, but to make sure that the configuration was stable (and hopefully immutable) before propagating it downstream.
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.
Actually, I had added this before the ConfigHelper.initImageConfiguration
but I noticed that generators are invoked inside this call and resolveImages get populated after this invocation (for zero configuration scenarios).
Reminder.
|
4f2416f
to
3922834
Compare
11ad2b1
to
55c82e1
Compare
Quality Gate passedIssues Measures |
55c82e1
to
b9e2c23
Compare
1713230
to
48fad50
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2378 +/- ##
=============================================
+ Coverage 59.36% 70.72% +11.36%
- Complexity 4586 5073 +487
=============================================
Files 500 489 -11
Lines 21211 19574 -1637
Branches 2830 2526 -304
=============================================
+ Hits 12591 13844 +1253
+ Misses 7370 4501 -2869
+ Partials 1250 1229 -21 ☔ View full report in Codecov by Sentry. |
48fad50
to
782eb44
Compare
* <p> | ||
* This field is applicable in case of OpenShift <code>s2i</code> build strategy | ||
*/ | ||
private String openshiftBuildRecreateMode; |
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.
Why is this a string here instead of an enum as it was before?
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.
enum
BuildRecreateMode is in jkube-kit/config/resource
, it's not available in jkube-kit/config/image
module.
Shall I move this enum to jkube-kit/common
?
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.
I'd say so, yes
…Config to Image's BuildConfiguration Signed-off-by: Rohan Kumar <[email protected]>
Signed-off-by: Rohan Kumar <[email protected]>
782eb44
to
9998085
Compare
BuildConfiguration updatedBuildConfig = mergeGlobalConfigParamsWithSingleImageBuildConfig(imageConfiguration.getBuild()); | ||
imageConfiguration.setBuild(updatedBuildConfig); |
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.
In a future iteration we'll need to see if we can refactor ImageConfiguration.initAndValidate method to take care of this.
Signed-off-by: Marc Nuri <[email protected]>
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.
LGTM, thx!
Quality Gate failedFailed conditions |
Description
ConfigHelper.initImageConfiguration
to a dedicated generator #2802 refactor (jkube-kit) : MoveConfigHelper.initImageConfiguration
toGeneratorManager.generateAndMerge
#2818 to be merged firstbuildRecreateMode
->openshiftBuildRecreateMode
forcePull
->openshiftForcePull
s2iBuildNameSuffix
->openshiftS2iBuildNameSuffix
s2iImageStreamLookupPolicyLocal
->openshiftS2iImageStreamLookupPolicyLocal
openshiftPullSecret
->openshiftPullSecret
openshiftPushSecret
->openshiftPushSecret
buildOutputKind
->openshiftBuildOutputKind
These fields are for configuring the OpenShift S2I build process. These fields make more sense to be in BuildConfiguration as we want our BuildConfiguration to accommodate fields for build strategies other than docker.
With this change, we're exposing the abovementioned configuration fields from these sources:
If both configuration options are provided, priority would be given to options provided inside
image
>build
configurationType of change
test, version modification, documentation, etc.)
Checklist