java.lang.IllegalArgumentException: Could not resolve placeholder 'foo' in string value "${foo}"

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
Expert tip

Check if you don't have more than one instance of PropertySourcesPlaceholderConfigurer in your code, this might cause conflict.

Solutions on the web

via Stack Overflow by VladislavLysov
, 1 year ago
Could not resolve placeholder 'foo' in string value "${foo}"
via egovernments.org by Unknown author, 1 year ago
Could not resolve placeholder 'maven.build.timestamp' in string value "${maven.build.timestamp}"
via Stack Overflow by user1107753
, 2 years ago
Could not resolve placeholder 'very-so-much' in string value "${very-so-much}"
via codegur.com by Unknown author, 1 year ago
Could not resolve placeholder 'very-so-much' in string value "${very-so-much}"
via GitHub by zacwolfe
, 1 year ago
Could not resolve placeholder 'readSql' in string value "${readSql}"
via Stack Overflow by Srini V
, 2 years ago
Could not resolve placeholder 'mongodb.name' in string value "${mongodb.name}"
java.lang.IllegalArgumentException: Could not resolve placeholder 'foo' in string value "${foo}"
at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:174)
at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:126)
at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:219)

Users with the same issue

Once, 10 months ago
Once, 4 months ago
2 times, 5 months ago
Once, 1 year ago
2 times, 1 year ago
55 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.