astefanutti commented on code in PR #3427:
URL: https://github.com/apache/camel-k/pull/3427#discussion_r918917396
##########
pkg/util/maven/maven_command.go:
##########
@@ -48,13 +49,21 @@ func (c *Command) Do(ctx context.Context) error {
return err
}
- mvnCmd := "mvn"
+ mvnCmd := ""
+ switch c.context.Strategy {
+ case "default":
Review Comment:
`case "default:` -> `default:`
##########
pkg/apis/camel/v1/common_types.go:
##########
@@ -48,12 +47,17 @@ const (
// BuildStrategyPod performs the build in a `Pod` (will schedule a new
builder ephemeral `Pod` which will take care of the build action).
// This strategy has the limitation that every build will have to
download all the dependencies required by the Maven build.
BuildStrategyPod BuildStrategy = "pod"
+ // BuildStrategyType is the type of strategy that should be used to
perform the build.
Review Comment:
"BuildStrategyMvnd performs the build using Apache Maven Daemon, that's
started in the operator Pod."
##########
pkg/apis/camel/v1/common_types.go:
##########
@@ -37,7 +37,6 @@ const (
// BuildStrategy specifies how the Build should be executed.
// It will trigger a Maven process that will take care of producing the
expected Camel/Camel-Quarkus runtime.
-// +kubebuilder:validation:Enum=routine;pod
Review Comment:
It should be `+kubebuilder:validation:Enum=routine;pod;mvnd`
##########
pkg/apis/camel/v1/common_types.go:
##########
@@ -37,7 +37,6 @@ const (
// BuildStrategy specifies how the Build should be executed.
// It will trigger a Maven process that will take care of producing the
expected Camel/Camel-Quarkus runtime.
-// +kubebuilder:validation:Enum=routine;pod
Review Comment:
Also the CRDs must be regenerated to take into account the new value.
##########
pkg/apis/camel/v1/build_types.go:
##########
@@ -38,7 +38,6 @@ type BuildSpec struct {
// +kubebuilder:validation:Format=duration
Timeout metav1.Duration `json:"timeout,omitempty"`
}
-
Review Comment:
Should be reverted.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]