zregvart commented on a change in pull request #534:
URL: https://github.com/apache/camel-website/pull/534#discussion_r567031414
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
Review comment:
```suggestion
From the Camel side, the `{{...}}` notation could be issued, for instance,
in a simple expression:
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
Review comment:
```suggestion
Notice how the property from the second line embeds the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
Review comment:
```suggestion
But there is more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
+For instance, some developers could end up defining a property like below:
+```properties
+date-expression = ${date:now}
+```
+And then using it in a Camel simple expression like that:
+```properties
+from(...).setBody(simple("{{escape-dollar-to-avoid-property-resolution}}")
+```
+But when the `setBody` statement is executed, the resulting body is... `null`
+
+It could sounds a bit strange at first, but let's review this situation with
what we have learned so far.
+On first pass, the `application.properties` file is parsed with respect to the
[Properties file
format](https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html).
No special characters are used, so the parsing outcome would be `${date:now}`
as expected.
+
+But in the second pass, it turns out that this property value is interpreted
as the expansion of an environment variable named `date` with a default value
`now`. As such, Camel is provided with the default value `now`. The expansion
algorithm is detailed in
[io.smallrye.common.expression.Expression.parseString(...)](https://github.com/smallrye/smallrye-common/blob/0b59733491ff936808cd26a4b300f11fe3f2a5f0/expression/src/main/java/io/smallrye/common/expression/Expression.java#L245).
+Paying a close attention, it appears that the environment value expansion
could be avoided using `$$`:
+```properties
+date-expression = $${date:now}
+```
+Exactly what we needed, Camel is now provided with the simple expression
`${date:now}` and set the body to a value like `Fri Jan 29 17:07:44 CET 2021`
on execution.
+
+## Summary
+
+At the end of the day, we had a refresher about `application.properties`,
property expressions and environment variables with default value.
+We have seen how to deal with a tricky situation and there must be even more
corner cases out there.
+
+The source code for this example could be found
[here](https://github.com/aldettinger/camel-quarkus-properties). Also, the
Quarkus configuration reference guide is located
[here](https://quarkus.io/guides/config-reference).
+
+We hope that this article brought some useful tips when dealing with
configuration in Camel Quarkus.
Review comment:
```suggestion
We hope that this article brought some useful tips when dealing with the
configuration in Camel Quarkus.
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
+For instance, some developers could end up defining a property like below:
+```properties
+date-expression = ${date:now}
+```
+And then using it in a Camel simple expression like that:
+```properties
+from(...).setBody(simple("{{escape-dollar-to-avoid-property-resolution}}")
+```
+But when the `setBody` statement is executed, the resulting body is... `null`
+
+It could sounds a bit strange at first, but let's review this situation with
what we have learned so far.
Review comment:
```suggestion
It could sound a bit strange at first, but let's review this situation with
what we have learned so far.
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
Review comment:
```suggestion
The previous syntax `${VAR:default}` may sound familiar for some Camel
users. Indeed, it reminds us of some parts of the [Camel simple
Language](/components/latest/languages/simple-language.html).
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
+For instance, some developers could end up defining a property like below:
+```properties
+date-expression = ${date:now}
+```
+And then using it in a Camel simple expression like that:
+```properties
+from(...).setBody(simple("{{escape-dollar-to-avoid-property-resolution}}")
+```
+But when the `setBody` statement is executed, the resulting body is... `null`
+
+It could sounds a bit strange at first, but let's review this situation with
what we have learned so far.
+On first pass, the `application.properties` file is parsed with respect to the
[Properties file
format](https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html).
No special characters are used, so the parsing outcome would be `${date:now}`
as expected.
Review comment:
```suggestion
On the first pass, the `application.properties` file is parsed with respect
to the [Properties file
format](https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html).
No special characters are used, so the parsing outcome would be `${date:now}`
as expected.
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
+For instance, some developers could end up defining a property like below:
+```properties
+date-expression = ${date:now}
+```
+And then using it in a Camel simple expression like that:
+```properties
+from(...).setBody(simple("{{escape-dollar-to-avoid-property-resolution}}")
+```
+But when the `setBody` statement is executed, the resulting body is... `null`
+
+It could sounds a bit strange at first, but let's review this situation with
what we have learned so far.
+On first pass, the `application.properties` file is parsed with respect to the
[Properties file
format](https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html).
No special characters are used, so the parsing outcome would be `${date:now}`
as expected.
+
+But in the second pass, it turns out that this property value is interpreted
as the expansion of an environment variable named `date` with a default value
`now`. As such, Camel is provided with the default value `now`. The expansion
algorithm is detailed in
[io.smallrye.common.expression.Expression.parseString(...)](https://github.com/smallrye/smallrye-common/blob/0b59733491ff936808cd26a4b300f11fe3f2a5f0/expression/src/main/java/io/smallrye/common/expression/Expression.java#L245).
+Paying a close attention, it appears that the environment value expansion
could be avoided using `$$`:
Review comment:
```suggestion
Paying close attention, it appears that the environment value expansion
could be avoided using `$$`:
```
##########
File path: content/blog/2021/01/camel-quarkus-configuration-tips/index.md
##########
@@ -0,0 +1,106 @@
+---
+title: "Camel Quarkus Configuration Tips"
+date: 2021-01-29
+authors: ["aldettinger"]
+categories: ["Camel Quarkus"]
+preview: "Camel Quarkus Configuration Tips"
+summary: "Some tips related to configuration in Camel Quarkus"
+---
+
+Lately, I have exchanged with a member of the Camel community around
configuration properties in Camel Quarkus.
+It's really interesting to hear about situations people are facing out there,
so please keep reaching out to the community.
+Thinking back about the case at hand, I think there is room for a refresher
about some configuration tips.
+
+## Configuration via application.properties file
+
+There are multiple ways to define configurations in Camel Quarkus.
+The more common way to define configurations must be the
`application.properties` file, as illustrated below:
+```properties
+basic=a-basic-value
+```
+
+There are few possibilities for a developer to use the defined configurations.
+One could use the `@ConfigProperty` annotation as beneath:
+```java
+@ConfigProperty(name = "basic")
+String basicPropertyFromAnnotation;
+```
+
+It's also possible to access the configuration values programmatically via the
following code:
+```java
+String basicPropertyFromConfigProvider =
ConfigProvider.getConfig().getValue("basic", String.class);
+```
+
+From the Camel side, the `{{...}}` notation could be issued, for instance in a
simple expression:
+```java
+from(...).setBody(simple("{{basic}}"))
+```
+
+It's worth noting that in a first pass the `application.properties` file is
parsed thanks to `java.util.Properties`.
+And as such, the corresponding character escaping rules applies, for instance
one could define a configuration using the mathematical square root sign
`\u221A` as beneath:
+```properties
+unicode = a-value-with-unicode-character-(\u221A9=3)
+```
+
+## Property expressions
+
+But there are more processing happening in a second pass thanks to
[smallrye-common](https://github.com/smallrye/smallrye-common) and it leads to
more features.
+For instance, with property expressions one could define a configuration as
below:
+```properties
+embedded = resolved-via-a
+property-expression = a-value-${embedded}-property-expression
+```
+
+Notice how the property from the second line embed the value from the first
line. The resulting value at the end would be
`a-value-resolved-via-a-property-expression`.
+
+## Environment variables
+
+Another topic of interest is environment variable expansion. Look at the
following property definition where the USERNAME environment variable is used:
+```properties
+environment-variable = a-value-with-environment-variable-${USERNAME}
+```
+
+So, it is possible to include environment variables in the mix. In case Camel
Quarkus runs in an environment where the variable is not defined,
+it is even possible to define a default value after the `:` character like
this:
+```properties
+environment-variable-or-default =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:by-a-default-value}
+```
+
+Last but not least, it's also possible to mix property expressions with
environment variables as in the following lines:
+```properties
+default-value = with-a-default-value-resolved-via-a-property-expression
+environment-variable-or-default-via-property-expression =
a-value-where-non-existing-environment-variable-is-replaced-${UNEXISTING_ENV_VAR:${default-value}}
+```
+The more meaningful part is `${UNEXISTING_ENV_VAR:${default-value}}`. If the
environment variable `UNEXISTING_ENV_VAR` is not defined, we end up embedding
the `default-value` configured one line above.
+
+## A tricky situation
+
+The previous syntax `${VAR:default}` may sound familiar for some Camel users.
Indeed, it remind us some part of the [Camel simple
Language](/components/latest/languages/simple-language.html).
+For instance, some developers could end up defining a property like below:
+```properties
+date-expression = ${date:now}
+```
+And then using it in a Camel simple expression like that:
+```properties
+from(...).setBody(simple("{{escape-dollar-to-avoid-property-resolution}}")
+```
+But when the `setBody` statement is executed, the resulting body is... `null`
+
+It could sounds a bit strange at first, but let's review this situation with
what we have learned so far.
+On first pass, the `application.properties` file is parsed with respect to the
[Properties file
format](https://docs.oracle.com/javase/7/docs/api/java/util/Properties.html).
No special characters are used, so the parsing outcome would be `${date:now}`
as expected.
+
+But in the second pass, it turns out that this property value is interpreted
as the expansion of an environment variable named `date` with a default value
`now`. As such, Camel is provided with the default value `now`. The expansion
algorithm is detailed in
[io.smallrye.common.expression.Expression.parseString(...)](https://github.com/smallrye/smallrye-common/blob/0b59733491ff936808cd26a4b300f11fe3f2a5f0/expression/src/main/java/io/smallrye/common/expression/Expression.java#L245).
+Paying a close attention, it appears that the environment value expansion
could be avoided using `$$`:
+```properties
+date-expression = $${date:now}
+```
+Exactly what we needed, Camel is now provided with the simple expression
`${date:now}` and set the body to a value like `Fri Jan 29 17:07:44 CET 2021`
on execution.
+
+## Summary
+
+At the end of the day, we had a refresher about `application.properties`,
property expressions and environment variables with default value.
Review comment:
```suggestion
At the end of the day, we had a refresher about `application.properties`,
property expressions, and environment variables with the default value.
```
----------------------------------------------------------------
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]