roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agillil...@apache.org
Subject svn commit: r497923 - /incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java
Date Fri, 19 Jan 2007 19:46:10 GMT
Author: agilliland
Date: Fri Jan 19 11:46:09 2007
New Revision: 497923

URL: http://svn.apache.org/viewvc?view=rev&rev=497923
Log:
ping queue task should have a main() method like all the other tasks.


Modified:
    incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java

Modified: incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java
URL: http://svn.apache.org/viewvc/incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java?view=diff&rev=497923&r1=497922&r2=497923
==============================================================================
--- incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java (original)
+++ incubator/roller/trunk/src/org/apache/roller/business/pings/PingQueueTask.java Fri Jan
19 11:46:09 2007
@@ -142,4 +142,20 @@
         
     }
     
+    
+    /**
+     * Main method so that this task may be run from outside the webapp.
+     */
+    public static void main(String[] args) throws Exception {
+        try {
+            PingQueueTask task = new PingQueueTask();
+            task.init();
+            task.run();
+            System.exit(0);
+        } catch (RollerException ex) {
+            ex.printStackTrace();
+            System.exit(-1);
+        }
+    }
+    
 }



Mime
View raw message