org.apache.geronimo.timer.jdbc
Class JDBCWorkerPersistence

java.lang.Object
  extended by org.apache.geronimo.timer.jdbc.JDBCWorkerPersistence
All Implemented Interfaces:
WorkerPersistence

public class JDBCWorkerPersistence
extends Object
implements WorkerPersistence

TODO use an insert returning or stored procedure to insert.


Constructor Summary
protected JDBCWorkerPersistence(String serverUniqueId, DataSource datasource, boolean useSequence)
           
 
Method Summary
 void cancel(long id)
           
 void fixedRateWorkPerformed(long id)
           
 Collection getIdsByKey(String key, Object userId)
           
 void intervalWorkPerformed(long id, long period)
           
 void playback(String key, Playback playback)
           
 void save(WorkInfo workInfo)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDBCWorkerPersistence

protected JDBCWorkerPersistence(String serverUniqueId,
                                DataSource datasource,
                                boolean useSequence)
                         throws SQLException
Throws:
SQLException
Method Detail

save

public void save(WorkInfo workInfo)
          throws PersistenceException
Specified by:
save in interface WorkerPersistence
Throws:
PersistenceException

cancel

public void cancel(long id)
            throws PersistenceException
Specified by:
cancel in interface WorkerPersistence
Throws:
PersistenceException

playback

public void playback(String key,
                     Playback playback)
              throws PersistenceException
Specified by:
playback in interface WorkerPersistence
Throws:
PersistenceException

fixedRateWorkPerformed

public void fixedRateWorkPerformed(long id)
                            throws PersistenceException
Specified by:
fixedRateWorkPerformed in interface WorkerPersistence
Throws:
PersistenceException

intervalWorkPerformed

public void intervalWorkPerformed(long id,
                                  long period)
                           throws PersistenceException
Specified by:
intervalWorkPerformed in interface WorkerPersistence
Throws:
PersistenceException

getIdsByKey

public Collection getIdsByKey(String key,
                              Object userId)
                       throws PersistenceException
Specified by:
getIdsByKey in interface WorkerPersistence
Throws:
PersistenceException


Copyright © 2003-2007 Apache Software Foundation. All Rights Reserved.