Could not resolve placeholder ' master.jdbc.url ' in string value ' ${master.jdbc.url} '

Source: Internet
Author: User
Org.springframework.beans.factory.BeanDefinitionStoreException:Invalid Bean definition with name ' Masterdatasource ' defined in file [C:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\xinghe-mycenter-web\ Web-inf\classes\spring\applicationcontext-dbpool-c3p0.xml]: Could not resolve placeholder ' master.jdbc.url ' in string Value "${master.jdbc.url}"; Nested exception is java.lang.IllegalArgumentException:Could isn't resolve placeholder ' master.jdbc.url ' in string value ' $ {Master.jdbc.url} "

Obviously, the C3P0 connection pool is used in the project. This error occurs because the configuration file is missing and, strictly speaking, c3p0 cannot find a configuration item named "Master.jdbc.url" from the configuration file. Workaround: As shown in the following illustration, this is a MAVEN Web project that is created if there is no corresponding directory or file.
Jdbc.properties file content: You can actually call another name, but the extension is immutable.
# DataSource related
jdbc.driver.class=com.mysql.jdbc.driver

master.jdbc.url=jdbc:mysql:// 192.168.1.127:3306/testcs_dn?useunicode=true&characterencoding=utf-8&zerodatetimebehavior= Converttonull&transformedbitisboolean=true&relaxautocommit=true&useserverpreparedstmts=true
MASTER.JDBC.USERNAME=ABCD
master.jdbc.password=**********
Re-release: It is best to clean,publish usually no problem, it is difficult to talk about the situation of bad character ...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.