Author: jfrederic.clere(a)jboss.com
Date: 2011-01-06 08:24:52 -0500 (Thu, 06 Jan 2011)
New Revision: 1635
Modified:
sandbox/webapps/src/TestServlet.java
Log:
Arrange the wait on start logic.
Modified: sandbox/webapps/src/TestServlet.java
===================================================================
--- sandbox/webapps/src/TestServlet.java 2011-01-05 22:46:57 UTC (rev 1634)
+++ sandbox/webapps/src/TestServlet.java 2011-01-06 13:24:52 UTC (rev 1635)
@@ -45,8 +45,11 @@
public void init(ServletConfig config) throws ServletException {
String swait = config.getInitParameter("wait");
- Integer iwait = new Integer(swait);
- int wait = iwait.intValue();
+ int wait = 10;
+ if (swait != null) {
+ Integer iwait = new Integer(swait);
+ wait = iwait.intValue();
+ }
Thread me = Thread.currentThread();
try {
me.sleep(wait);
Show replies by date