apache / camel-k-runtime

Apache Camel K runtime
https://camel.apache.org
Apache License 2.0
62 stars 50 forks source link

feat(catalog): leverage placeholders #1192

Closed squakez closed 3 months ago

squakez commented 3 months ago

This may help reaching a higher degree of cross compatibility between runtimes.

Resulting catalog change will be like the following:

      master:
        dependencies:
        - groupId: org.apache.camel.k
          artifactId: camel-k-master
        runtimeProperties:
        - key: "quarkus.camel.cluster.kubernetes.labels.\"${camel.k.master.labelKey}\""
          value: "${camel.k.master.labelValue}"
        - key: quarkus.camel.cluster.kubernetes.resource-name
          value: "${camel.k.master.resourceName}"
        - key: quarkus.camel.cluster.kubernetes.resource-type
          value: "${camel.k.master.resourceType}"
        buildTimeProperties:
        - key: quarkus.camel.cluster.kubernetes.enabled
          value: "${camel.k.master.enabled}"

Release Note

NONE
lburgazzoli commented 3 months ago

The only note I have is about the build time property:

buildTimeProperties:
        - key: quarkus.camel.cluster.kubernetes.enabled
          value: "${camel.k.master.enabled}"

Is there any case where we set it to false ? I guess that when the master trait is not enabled, then none of the properties are added to the configmap or pom

squakez commented 3 months ago

The only note I have is about the build time property:

buildTimeProperties:
        - key: quarkus.camel.cluster.kubernetes.enabled
          value: "${camel.k.master.enabled}"

Is there any case where we set it to false ? I guess that when the master trait is not enabled, then none of the properties are added to the configmap or pom

I included the same for consistency reasons. Also, imagine the hypothetical situation in which we expect this parameter to accept anything else beside true or false. Then, this would be prepared to handle that as well.