org.apache.james.mailrepository
Class JDBCSpoolRepository

java.lang.Object
  |
  +--org.apache.avalon.framework.logger.AbstractLoggable
        |
        +--org.apache.james.mailrepository.JDBCMailRepository
              |
              +--org.apache.james.mailrepository.JDBCSpoolRepository
All Implemented Interfaces:
org.apache.avalon.framework.component.Component, org.apache.avalon.framework.component.Composable, org.apache.avalon.framework.configuration.Configurable, org.apache.avalon.framework.context.Contextualizable, org.apache.avalon.framework.activity.Initializable, org.apache.avalon.framework.logger.Loggable, MailRepository, SpoolRepository

public class JDBCSpoolRepository
extends JDBCMailRepository
implements SpoolRepository

Implementation of a SpoolRepository on a database.

Requires a configuration element in the .conf.xml file of the form:
type="MAIL"
model="SYNCHRONOUS"/>
sun.jdbc.odbc.JdbcOdbcDriver
jdbc:odbc:LocalDB
Message

destinationURL specifies..(Serge??)
Type can be SPOOL or MAIL
Model is currently not used and may be dropped
conn is the location of the ...(Serge)
table is the name of the table in the Database to be used

Requires a logger called MailRepository.

Version:
1.0.0, 24/04/1999
Author:
Serge Knystautas

Fields inherited from class org.apache.james.mailrepository.JDBCMailRepository
context, datasource, datasourceName, datasources, destination, filestore, repositoryName, sqlFileName, sqlQueries, tableName
 
Fields inherited from interface org.apache.james.services.SpoolRepository
SPOOL
 
Fields inherited from interface org.apache.james.services.MailRepository
MAIL
 
Constructor Summary
JDBCSpoolRepository()
           
 
Method Summary
 java.lang.String accept()
          Return the key of a message to process.
 java.lang.String accept(long delay)
          Return the key of a message that's ready to process.
 
Methods inherited from class org.apache.james.mailrepository.JDBCMailRepository
compose, configure, contextualize, equals, getConnection, initialize, list, lock, remove, remove, retrieve, store, unlock
 
Methods inherited from class org.apache.avalon.framework.logger.AbstractLoggable
getLogger, setLogger, setupLogger, setupLogger, setupLogger
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.james.services.MailRepository
list, lock, remove, remove, retrieve, store, unlock
 

Constructor Detail

JDBCSpoolRepository

public JDBCSpoolRepository()
Method Detail

accept

public java.lang.String accept()
Return the key of a message to process. This is a message in the spool that is not locked.
Specified by:
accept in interface SpoolRepository

accept

public java.lang.String accept(long delay)
Return the key of a message that's ready to process. If a message is of type "error" then check the last updated time, and don't try it until the long 'delay' parameter milliseconds has passed.
Specified by:
accept in interface SpoolRepository


"Copyright © 2001 Apache Jakarta Project. All Rights Reserved."