From: Artur Signell Date: Fri, 5 Oct 2012 10:38:32 +0000 (+0300) Subject: Allow servletInitialized,portletInitialized to throw exception (#9848) X-Git-Tag: 7.0.0.beta6~94 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=bc19cb58d22ad18284e7095d72f45ef040298943;p=vaadin-framework.git Allow servletInitialized,portletInitialized to throw exception (#9848) Change-Id: Ib0fd2524ba82998063b21d6c3b56897270c24b2c --- diff --git a/server/src/com/vaadin/server/VaadinPortlet.java b/server/src/com/vaadin/server/VaadinPortlet.java index b0cc92b85e..231a463222 100644 --- a/server/src/com/vaadin/server/VaadinPortlet.java +++ b/server/src/com/vaadin/server/VaadinPortlet.java @@ -256,7 +256,7 @@ public class VaadinPortlet extends GenericPortlet implements Constants { CurrentInstance.clearAll(); } - protected void portletInitialized() { + protected void portletInitialized() throws PortletException { } diff --git a/server/src/com/vaadin/server/VaadinServlet.java b/server/src/com/vaadin/server/VaadinServlet.java index 0620035274..eb375e0b92 100644 --- a/server/src/com/vaadin/server/VaadinServlet.java +++ b/server/src/com/vaadin/server/VaadinServlet.java @@ -85,13 +85,13 @@ public class VaadinServlet extends HttpServlet implements Constants { * @param servletConfig * the object containing the servlet's configuration and * initialization parameters - * @throws javax.servlet.ServletException + * @throws ServletException * if an exception has occurred that interferes with the * servlet's normal operation. */ @Override public void init(javax.servlet.ServletConfig servletConfig) - throws javax.servlet.ServletException { + throws ServletException { CurrentInstance.clearAll(); setCurrent(this); super.init(servletConfig); @@ -126,7 +126,7 @@ public class VaadinServlet extends HttpServlet implements Constants { CurrentInstance.clearAll(); } - protected void servletInitialized() { + protected void servletInitialized() throws ServletException { // Empty by default } diff --git a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java index f6f1add940..12d1cb2c38 100644 --- a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java +++ b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java @@ -74,7 +74,7 @@ public class ApplicationRunnerServlet extends LegacyVaadinServlet { } @Override - protected void servletInitialized() { + protected void servletInitialized() throws ServletException { super.servletInitialized(); getService().addSessionInitListener(new SessionInitListener() { @Override