سؤال

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