org.apache.synapse.config.xml
Class AbstractDBMediatorFactory

java.lang.Object
  extended by org.apache.synapse.config.xml.AbstractMediatorFactory
      extended by org.apache.synapse.config.xml.AbstractDBMediatorFactory
All Implemented Interfaces:
MediatorFactory
Direct Known Subclasses:
DBLookupMediatorFactory, DBReportMediatorFactory

public abstract class AbstractDBMediatorFactory
extends AbstractMediatorFactory

Base class for factories for database related mediators.

 <dbreport | dblookup | .. etc>
   <connection>
     <pool>
     (
       <driver/>
       <url/>
       <user/>
       <password/>
     | 
       <dsName/>
       <icClass/>
       <url/>
       <user/>
       <password/>
     )
       <property name="name" value="value"/>*
     </pool>
   </connection>
   <statement>
     <sql>insert into table values (?, ?, ..) OR select target from destinations where src = ?</sql>
     <parameter (value="const" | expression="xpath") type="INTEGER|VARCHAR|..."/>*
     <result name="propName" column="target | number"/>*
   </statement>+
 </dbreport | dblookup | .. etc>
 
Supported properties for custom DataSources autocommit = true | false isolation = Connection.TRANSACTION_NONE | Connection.TRANSACTION_READ_COMMITTED | Connection.TRANSACTION_READ_UNCOMMITTED | Connection.TRANSACTION_REPEATABLE_READ | Connection.TRANSACTION_SERIALIZABLE initialsize = int maxactive = int maxidle = int maxopenstatements = int maxwait = long minidle = int poolstatements = true | false testonborrow = true | false testonreturn = true | false testwhileidle = true | false validationquery = String


Field Summary
static QName URL_Q
           
 
Fields inherited from class org.apache.synapse.config.xml.AbstractMediatorFactory
ATT_EXPRN, ATT_KEY, ATT_NAME, ATT_ONERROR, ATT_REGEX, ATT_SEQUENCE, ATT_SOURCE, ATT_STATS, ATT_TARGET, ATT_VALUE, ATT_XPATH, FEATURE_Q, log, PROP_Q, TARGET_Q
 
Constructor Summary
AbstractDBMediatorFactory()
           
 
Method Summary
protected  void buildDataSource(OMElement elem, AbstractDBMediator mediator)
           
protected  String getAttribute(OMElement elt, QName qName)
           
protected  String getValue(OMElement elt, QName qName)
           
protected  void processStatements(OMElement elem, AbstractDBMediator mediator)
           
 
Methods inherited from class org.apache.synapse.config.xml.AbstractMediatorFactory
handleException, handleException, processTraceState
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.synapse.config.xml.MediatorFactory
createMediator, getTagQName
 

Field Detail

URL_Q

public static final QName URL_Q
Constructor Detail

AbstractDBMediatorFactory

public AbstractDBMediatorFactory()
Method Detail

buildDataSource

protected void buildDataSource(OMElement elem,
                               AbstractDBMediator mediator)

processStatements

protected void processStatements(OMElement elem,
                                 AbstractDBMediator mediator)

getValue

protected String getValue(OMElement elt,
                          QName qName)

getAttribute

protected String getAttribute(OMElement elt,
                              QName qName)


Copyright © 2005-2008 Apache Software Foundation. All Rights Reserved.