Java Ambiguous mapping. Cannot map ‘xxx‘ method问题解决
程序员文章站
2022-03-08 16:24:10
...
问题描述:
Caused by: java.lang.IllegalStateException: Ambiguous mapping. Cannot map 'UserController' method
问题分析:
1、Controller的@RequestMapping注解的path属性重复。
@RequestMapping("/test")
@RequestMapping("/test")
2、方法的@RequestMapping、@GetMapping、@PostMapping、@PutMapping、@DeleteMapping注解的path属性重复。
@GetMapping("/test")
@PostMapping("/test")
推荐阅读
-
Ambiguous mapping found. Cannot map 'xxx' bean method
-
java.langIllegalStateException: Ambiguous mapping found. Cannot map 'outAppliController' bean method
-
java报错大全java.lang.IllegalStateException: Ambiguous mapping Cannot map xxx
-
解决“Ambiguous mapping. Cannot map ‘indexController‘ method”报错,其实很简单,只是不够细心
-
Java Ambiguous mapping. Cannot map ‘xxx‘ method问题解决
-
SpringCloud 整合hystrix使用继承feign调用微服务 IllegalStateException: Ambiguous mapping. Cannot map XXX method
-
BeanCreationException和IllegalStateException: Ambiguous mapping. Cannot map 'brandController' method
-
Caused by: java.lang.IllegalStateException: Ambiguous mapping. Cannot map 'xxx' method
-
Ambiguous mapping. Cannot map 'XXXXXController' method
-
异常java.lang.IllegalStateException: Ambiguous mapping. Cannot map 'xxx' method