, , :
https://vaadin.com/forum/#!/thread/344236/376324
, -:
@WebServlet(urlPatterns = {"", "/VAADIN/*", "/UIDL"}, asyncSupported = true)
( jsp)
. vaadin 4.8.5.
( "/UIDL/" http://dev.vaadin.com/ticket/7386
"/UIDL" - " URL... . 12.1 12.2 " )
- :(
http://.../r/...
( ), :
, , url, "/info/a", "/info", "/*", ( * = = "info/a" ). "/" "/info/", , , .
Vaadin , URL REST . - /ui REST. , , , / . , , - , . , , /* Vaadin, /login.jsp JSP, .
Java EE 6, Vaadin , . web.xml:
@WebServlet(urlPatterns = {"/ui/*", "/VAADIN/*"})
public static class MyServlet extends AbstractApplicationServlet {
}
web.xml :
<servlet>
<servlet-name>index</servlet-name>
<jsp-file>index.jsp</jsp-file>
</servlet>
<servlet>
<servlet-name>ServletAdaptor</servlet-name>
<servlet-class>com.sun.jersey.spi.container.servlet.ServletContainer</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>index</servlet-name>
<url-pattern>/</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>ServletAdaptor</servlet-name>
<url-pattern>/*</url-pattern>
</servlet-mapping>
So, I have established that / * will match any REST resource that I add if it is not / ui / *. When a user first visits the site, he / she is sent to index.jsp, which is simple:
This is probably a lot more than you want to know, but maybe it will help someone. If the user interface is a secondary part of the web application, I like it if it sits at a specific URL rather than using / * for it.