我想将 Spring 配置为将所有请求重定向到特定的控制器,而不考虑 URL(长度和参数)。我应该如何在 RequestMapping 注释中给出 URL 模式/正则表达式。我尝试使用下面的代码,但它不起作用。非常感谢这方面的任何帮助。
@Controller
@RequestMapping("/*")
public class ServiceController {
@RequestMapping( method = RequestMethod.GET, value = "*" )
public void getProjectList(HttpServletRequest httpServletRequest,Model model){
}
}