liyujun1993 / paoding-rose

Automatically exported from code.google.com/p/paoding-rose
0 stars 0 forks source link

关于url正则的配置问题 #21

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
ListController
1. 配置两个方法.
2. @Get("{category_([0-9]+)}")
3. @Get("{industry_([0-9]+)}")

java.lang.IllegalArgumentException: mapping conflicts: '{industry_([0-9]+)}' 
conflicts with '{category_([0-9]+)}' in '/list/'

明显这两个正则开头都不一样,如何会冲突?

Original issue reported on code.google.com by yang.zha...@gmail.com on 10 Sep 2012 at 5:11

GoogleCodeExporter commented 9 years ago
学艺不精,看懂了。
如下配置就对了。
2. @Get("category_{([0-9]+)}")
3. @Get("industry_{([0-9]+)}")

Original comment by yang.zha...@gmail.com on 10 Sep 2012 at 5:47