What characters should be escaped in application.properties in Spring? [closed]
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}
While ago I found a problem which appears to be connected to application.properties in my java spring app. On local dev machines we use simple application.yml files which are compiled into app (I guess?), but when we deploy on production we use more secure properties. It seems that some of them are read wrong. So my question is what kind of characters are prohibited in application.properties file? How can I escape these characters?
java spring
closed as off-topic by Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho Nov 23 '18 at 16:50
This question appears to be off-topic. The users who voted to close gave this specific reason:
- "Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Questions without a clear problem statement are not useful to other readers. See: How to create a Minimal, Complete, and Verifiable example." – Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho
If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment |
While ago I found a problem which appears to be connected to application.properties in my java spring app. On local dev machines we use simple application.yml files which are compiled into app (I guess?), but when we deploy on production we use more secure properties. It seems that some of them are read wrong. So my question is what kind of characters are prohibited in application.properties file? How can I escape these characters?
java spring
closed as off-topic by Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho Nov 23 '18 at 16:50
This question appears to be off-topic. The users who voted to close gave this specific reason:
- "Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Questions without a clear problem statement are not useful to other readers. See: How to create a Minimal, Complete, and Verifiable example." – Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho
If this question can be reworded to fit the rules in the help center, please edit the question.
1
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47
add a comment |
While ago I found a problem which appears to be connected to application.properties in my java spring app. On local dev machines we use simple application.yml files which are compiled into app (I guess?), but when we deploy on production we use more secure properties. It seems that some of them are read wrong. So my question is what kind of characters are prohibited in application.properties file? How can I escape these characters?
java spring
While ago I found a problem which appears to be connected to application.properties in my java spring app. On local dev machines we use simple application.yml files which are compiled into app (I guess?), but when we deploy on production we use more secure properties. It seems that some of them are read wrong. So my question is what kind of characters are prohibited in application.properties file? How can I escape these characters?
java spring
java spring
asked Nov 23 '18 at 8:10
mkubackimkubacki
41929
41929
closed as off-topic by Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho Nov 23 '18 at 16:50
This question appears to be off-topic. The users who voted to close gave this specific reason:
- "Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Questions without a clear problem statement are not useful to other readers. See: How to create a Minimal, Complete, and Verifiable example." – Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho
If this question can be reworded to fit the rules in the help center, please edit the question.
closed as off-topic by Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho Nov 23 '18 at 16:50
This question appears to be off-topic. The users who voted to close gave this specific reason:
- "Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. Questions without a clear problem statement are not useful to other readers. See: How to create a Minimal, Complete, and Verifiable example." – Seelenvirtuose, rkosegi, DanielBarbarian, Rob, pirho
If this question can be reworded to fit the rules in the help center, please edit the question.
1
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47
add a comment |
1
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47
1
1
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47
add a comment |
1 Answer
1
active
oldest
votes
The YAML format supports UTF-8 by default, whereas properties files must be encoded and are read in the ISO-8859-1 encoding by definition. So any non-ISO-8859-1 character is going to cause you issues unless you escape them in the .properties files.
You escape the Unicode characters in properties files by using their hex code prefixed with "u". For example, "ä" would be encoded as u00E4
, and the snowman, ☃, would be encoded as u2603
. You can find the escape codes, for example, here.
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
The YAML format supports UTF-8 by default, whereas properties files must be encoded and are read in the ISO-8859-1 encoding by definition. So any non-ISO-8859-1 character is going to cause you issues unless you escape them in the .properties files.
You escape the Unicode characters in properties files by using their hex code prefixed with "u". For example, "ä" would be encoded as u00E4
, and the snowman, ☃, would be encoded as u2603
. You can find the escape codes, for example, here.
add a comment |
The YAML format supports UTF-8 by default, whereas properties files must be encoded and are read in the ISO-8859-1 encoding by definition. So any non-ISO-8859-1 character is going to cause you issues unless you escape them in the .properties files.
You escape the Unicode characters in properties files by using their hex code prefixed with "u". For example, "ä" would be encoded as u00E4
, and the snowman, ☃, would be encoded as u2603
. You can find the escape codes, for example, here.
add a comment |
The YAML format supports UTF-8 by default, whereas properties files must be encoded and are read in the ISO-8859-1 encoding by definition. So any non-ISO-8859-1 character is going to cause you issues unless you escape them in the .properties files.
You escape the Unicode characters in properties files by using their hex code prefixed with "u". For example, "ä" would be encoded as u00E4
, and the snowman, ☃, would be encoded as u2603
. You can find the escape codes, for example, here.
The YAML format supports UTF-8 by default, whereas properties files must be encoded and are read in the ISO-8859-1 encoding by definition. So any non-ISO-8859-1 character is going to cause you issues unless you escape them in the .properties files.
You escape the Unicode characters in properties files by using their hex code prefixed with "u". For example, "ä" would be encoded as u00E4
, and the snowman, ☃, would be encoded as u2603
. You can find the escape codes, for example, here.
answered Nov 23 '18 at 9:08
ZeroOneZeroOne
1,89311845
1,89311845
add a comment |
add a comment |
1
If the problematic characters are accented vowels (áéíóú etc) then this question may be of relevance.
– jsheeran
Nov 23 '18 at 8:20
Sadly, that is not the case - I have few @!# characters but I was wondering what kind of characters except accented ones are not read correctly
– mkubacki
Nov 23 '18 at 8:47