How to set two Url patterns in Servlets 3.0 through annotation as:

@WebServlet(urlPatterns = "/flow", asyncSupported = true)
public class FlowService extends HttpServlet

This example is for one url pattern but I want to set it for two urls.

有帮助吗?

解决方案

urlPatterns = {"/flow", "/low"}
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top