geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jb...@apache.org
Subject svn commit: r667127 - in /geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main: java/org/apache/geronimo/samples/inventory/web/ webapp/WEB-INF/
Date Thu, 12 Jun 2008 15:12:09 GMT
Author: jbohn
Date: Thu Jun 12 08:12:09 2008
New Revision: 667127

URL: http://svn.apache.org/viewvc?rev=667127&view=rev
Log:
correct ReceivingServlet name and fix some build problems

Added:
    geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/ReceivingServlet.java
      - copied, changed from r666868, geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/RecievingServlet.java
Removed:
    geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/RecievingServlet.java
Modified:
    geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/webapp/WEB-INF/web.xml

Copied: geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/ReceivingServlet.java
(from r666868, geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/RecievingServlet.java)
URL: http://svn.apache.org/viewvc/geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/ReceivingServlet.java?p2=geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/ReceivingServlet.java&p1=geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/RecievingServlet.java&r1=666868&r2=667127&rev=667127&view=diff
==============================================================================
--- geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/RecievingServlet.java
(original)
+++ geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/java/org/apache/geronimo/samples/inventory/web/ReceivingServlet.java
Thu Jun 12 08:12:09 2008
@@ -25,9 +25,10 @@
 import javax.servlet.http.HttpServletResponse;
 
 import org.apache.geronimo.samples.inventory.services.InventoryManager;
+import org.apache.geronimo.samples.inventory.exception.ItemException;
 
 
-public class RecievingServlet extends HttpServlet {
+public class ReceivingServlet extends HttpServlet {
 
 
     protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException,
IOException {
@@ -52,6 +53,9 @@
             e.printStackTrace();
             req.setAttribute("error", "Invalid Number Format for Quantity");
             getServletContext().getRequestDispatcher("/jsp/error.jsp").forward(req, res);
+        } catch (ItemException e) {
+            req.setAttribute("Internal error", e.getCause().getMessage());
+            getServletContext().getRequestDispatcher("/jsp/error.jsp").forward(req, res);
         }
 
     }

Modified: geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/webapp/WEB-INF/web.xml
URL: http://svn.apache.org/viewvc/geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/webapp/WEB-INF/web.xml?rev=667127&r1=667126&r2=667127&view=diff
==============================================================================
--- geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/webapp/WEB-INF/web.xml
(original)
+++ geronimo/samples/branches/2.1/samples/inventory/inventory-war/src/main/webapp/WEB-INF/web.xml
Thu Jun 12 08:12:09 2008
@@ -38,9 +38,9 @@
         <servlet-class>org.apache.geronimo.samples.inventory.web.IssueingServlet</servlet-class>
     </servlet>
     <servlet>
-        <display-name>RecievingServlet</display-name>
-        <servlet-name>RecievingServlet</servlet-name>
-        <servlet-class>org.apache.geronimo.samples.inventory.web.RecievingServlet</servlet-class>
+        <display-name>ReceivingServlet</display-name>
+        <servlet-name>ReceivingServlet</servlet-name>
+        <servlet-class>org.apache.geronimo.samples.inventory.web.ReceivingServlet</servlet-class>
     </servlet>
 
     <servlet-mapping>
@@ -52,7 +52,7 @@
         <url-pattern>/issue</url-pattern>
     </servlet-mapping>
     <servlet-mapping>
-        <servlet-name>RecievingServlet</servlet-name>
+        <servlet-name>ReceivingServlet</servlet-name>
         <url-pattern>/recv</url-pattern>
     </servlet-mapping>
 



Mime
View raw message