squakez commented on a change in pull request #2114:
URL: https://github.com/apache/camel-k/pull/2114#discussion_r593099695
##########
File path: pkg/util/kubernetes/util.go
##########
@@ -228,3 +232,37 @@ func ResolveValueSource(ctx context.Context, client
k8sclient.Reader, namespace
return "", nil
}
+
+// GetTolerations build an array of Tolerations from an array of string
+func GetTolerations(taints []string) ([]corev1.Toleration, error) {
Review comment:
I think it is appropriate keeping as it is. I'll explain why. You can
see that such utility unit is bundling different methods treating `corev1`
structs. I tried to be as much cohesive as possible. If I use another utility
unit I feel I break that cohesion just for the purpose of reducing the size.
Finally I preferred to have better cohesion versus the lenght of the `util`.
Did I convince you?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]