您的位置:首页 > 编程语言 > Java开发

springboot Environment注入异常

2017-04-17 00:00 253 查看
##error

***************************
APPLICATION FAILED TO START
***************************

Description:

Field environment in com.xxx.Environment required a bean of type 'org.springframework.core.env.Environment' that could not be found.

Action:

Consider defining a bean of type 'org.springframework.core.env.Environment' in your configuration.

##fix
原因是有bean命名为environment跟spring的重复了,需要改一下

##doc

Consider defining a bean of type 'org.springframework.core.env.Environment' in your configuration
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  Spring Boot