Ambiguous mapping. Cannot map ‘informationController’ method
com.shenger.dev.demo2.doctor.Expert.information.controller.InformationController#findOneId(Integer)
to {POST /content/findOneId}: There is already ‘contentController’ bean method
翻译
:
不明确的映射。无法映射“informationController”方法
com.shenger.dev.demo2.doctor.Expert.information.controller.InformationController(整数)
到{POST/content/findOneId}:已经有“contentController”bean方法
解决办法是:
控制层里的@RequestMapping("/information")这有重复的名字
本文详细解析了在SpringBoot项目中遇到的“informationController”方法映射到特定路径时出现的重复映射错误。该错误源于控制层RequestMapping注解的命名冲突。文章提供了具体的解决方案,包括调整控制器命名和请求映射,以避免此类问题。
421

被折叠的 条评论
为什么被折叠?



