Could not resolve placeholder ‘app.name‘ in value “${app.name}“

Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Invalid bean definition with name ‘hlb’ defined in class path resource [applicationContext.xml]: Could not resolve placeholder ‘app.name’ in value “ a p p . n a m e " ; n e s t e d e x c e p t i o n i s j a v a . l a n g . I l l e g a l A r g u m e n t E x c e p t i o n : C o u l d n o t r e s o l v e p l a c e h o l d e r ′ a p p . n a m e ′ i n v a l u e " {app.name}"; nested exception is java.lang.IllegalArgumentException: Could not resolve placeholder 'app.name' in value " app.name";nestedexceptionisjava.lang.IllegalArgumentException:Couldnotresolveplaceholderapp.nameinvalue"{app.name}”
2020-12-07 16:50:10,161 [main] INFO (AutoConfigurationReportLoggingInitializer:101) -
代码报错,前一天还可以运行,第二天怎么都不好用了,maven没有问题,代码也没有问题,配置什么的都ok,后来找了好久,是不小心把模块重置成文件夹了。。。
正常的模块:在这里插入图片描述
我不小心改成了没有蓝色小方块的。。。
解决办法 :右键 在这里插入图片描述
点击reload project 重新加载进来就可以了✌️

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
Could not resolve placeholder 'app.name' in value "${app.name}"是一个报错信息,它表示在Spring配置文件中找不到占位符'${app.name}'对应的值。 这可能是因为在属性文件中没有定义或配置了错误的占位符。 根据引用和引用中的报错信息,可能有两个原因导致这个问题。一个是在属性文件中没有定义'info.name'或'app.name'这些属性的值,另一个是在配置文件中使用了错误的占位符。 解决这个问题的方法是,首先检查属性文件中是否正确定义了占位符对应的属性值。 确保属性文件中包含了'info.name'或'app.name'这些属性,并且它们有正确的值。 如果属性文件中没有定义这些属性,可以手动添加它们并设置相应的值。 另外,还需要检查配置文件中是否使用了正确的占位符。 确保在配置文件中使用的占位符与属性文件中定义的占位符名称一致。 如果使用了错误的占位符,需要将其更正为正确的占位符名称。 总结起来,解决Could not resolve placeholder 'app.name' in value "${app.name}"的问题,需要确保属性文件中定义了正确的占位符对应的属性值,并且配置文件中使用了正确的占位符名称。<span class="em">1</span><span class="em">2</span><span class="em">3</span> #### 引用[.reference_title] - *1* [nacos config:Could not resolve placeholder ‘info.name‘ in value “${info.name}](https://blog.csdn.net/qq_42224683/article/details/114918992)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_1"}}] [.reference_item style="max-width: 33.333333333333336%"] - *2* [若依报:Could not resolve placeholder ‘shiro.session.expireTime‘ in value “${shiro.session....](https://blog.csdn.net/qq_53127029/article/details/131370538)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_1"}}] [.reference_item style="max-width: 33.333333333333336%"] - *3* [解决Unable to access 'https://gitee.com/自己的项目/': Could not resolve host: gitee.com问题](https://download.csdn.net/download/weixin_38742520/12923630)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_1"}}] [.reference_item style="max-width: 33.333333333333336%"] [ .reference_list ]

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值