In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly explains "how to solve the emergence of Failed to load property source from location 'classpath:/application.yml in Spring boot". The content of the explanation in the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "how to solve the problem of Failed to load property source from location' classpath:/application.yml when Spring boot appears".
Recently, when I was working on a project based on Spring boot, I changed the application.yml, which caused the IDEA to start with an error:
Java.lang.IllegalStateException: Failed to load property source from location 'classpath:/application.yml
So there are three reasons for finding all kinds of solutions online:
The contents of the application.yml file are not indented in the correct format.
The comment on the yml file is "#", not "/ /".
The application.yml file code is inconsistent with the project code.
The first and second reasons are easy to rule out. The coding problems that afflict the vast number of programmers in China are the most difficult to deal with, and setting- > editor- > file encodings does not help.
But there is the ultimate solution:
Copy out the contents of the file and put it in np.
Delete the original application.yml.
Create a new application.yml and copy the contents of the file back.
Thank you for your reading, the above is the content of "Spring boot appears Failed to load property source from location 'classpath:/application.yml how to solve", after the study of this article, I believe you have a deeper understanding of Spring boot Failed to load property source from location' classpath:/application.yml how to solve this problem, the specific use of the situation also needs to be verified by practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.