Trying to automatically post properties to a bean in Spring 3.0.5.RELEASE, I use:
As a result, the username is literally set to "${username}" , so the expression does not receive parsing. My other auto-connect relationship with this class is established, and Spring does not raise any exceptions. I also tried adding @Autowired , but that didn't help.
If I parse the properties for a single bean and then use @Autowired + @Qualifier , it works:
<bean id="username" class="java.lang.String"> <constructor-arg value="${username}"/> </bean>
Any ideas on how to use @Value only? Maybe I need to include some Spring dependency that I don't have? Thanks you
spring properties frameworks autowired
Alex Yarmula Mar 11 2018-11-11T00: 00Z
source share