|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.transaction.util.xa.AbstractXAResource
org.apache.slide.common.AbstractXAServiceBase
org.apache.slide.common.XAServiceBase
org.apache.slide.store.DefaultIndexer
DefaultIndexer is loaded, when no Indexer was explicitly configured for a store (content or properties). Initilializes with the store specific indexer if store implements IBasicExpressionFactoryProvider, else with null, which means, no search possible on store (unless generic search). Fakes two phase commit.
Nested Class Summary |
Nested classes inherited from class org.apache.slide.common.XAServiceBase |
XAServiceBase.DummyTxResource |
Field Summary |
Fields inherited from class org.apache.slide.common.AbstractXAServiceBase |
LOG_CHANNEL, loggerFacade, namespace, scope |
Fields inherited from interface javax.transaction.xa.XAResource |
TMENDRSCAN, TMFAIL, TMJOIN, TMNOFLAGS, TMONEPHASE, TMRESUME, TMSTARTRSCAN, TMSUCCESS, TMSUSPEND, XA_OK, XA_RDONLY |
Fields inherited from interface javax.transaction.Status |
STATUS_ACTIVE, STATUS_COMMITTED, STATUS_COMMITTING, STATUS_MARKED_ROLLBACK, STATUS_NO_TRANSACTION, STATUS_PREPARED, STATUS_PREPARING, STATUS_ROLLEDBACK, STATUS_ROLLING_BACK, STATUS_UNKNOWN |
Constructor Summary | |
DefaultIndexer(java.lang.Object associatedStore)
Uses the ExpressionFactory of associated store (if applicable) |
Method Summary | |
void |
connect()
Connects to the underlying data source (if any is needed). |
void |
createIndex(Uri uri,
NodeRevisionDescriptor revisionDescriptor,
NodeRevisionContent revisionContent)
Index an object content. |
void |
disconnect()
Disconnects from the underlying data source. |
void |
dropIndex(Uri uri,
NodeRevisionNumber number)
Drop an object revision from the index. |
IBasicExpressionFactory |
getBasicExpressionFactory()
As defined in IBasicExpressionFactoryProvider |
boolean |
isConnected()
This function tells whether or not the service is connected. |
void |
reset()
Deletes service underlying data source, if possible (and meaningful). |
void |
setParameters(java.util.Hashtable parameters)
Initializes the service with a set of parameters. |
void |
updateIndex(Uri uri,
NodeRevisionDescriptor revisionDescriptor,
NodeRevisionContent revisionContent)
updates an index for a resource |
Methods inherited from class org.apache.slide.common.XAServiceBase |
createTransactionResource, getTransactionTimeout, includeBranchInXid, isSameRM, recover, setTransactionTimeout |
Methods inherited from class org.apache.slide.common.AbstractXAServiceBase |
cacheResults, connect, connectIfNeeded, connectIfNeeded, getLogger, getLoggerFacade, initialize, setNamespace, setScope |
Methods inherited from class org.apache.commons.transaction.util.xa.AbstractXAResource |
addAcitveTransactionalResource, addSuspendedTransactionalResource, commit, end, forget, getActiveTransactionalResource, getCurrentlyActiveTransactionalResource, getSuspendedTransactionalResource, getTransactionalResource, prepare, removeActiveTransactionalResource, removeSuspendedTransactionalResource, rollback, setCurrentlyActiveTransactionalResource, start |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.slide.common.Service |
cacheResults, connect, connectIfNeeded, connectIfNeeded, getLogger, initialize, setNamespace, setScope |
Methods inherited from interface javax.transaction.xa.XAResource |
commit, end, forget, getTransactionTimeout, isSameRM, prepare, recover, rollback, setTransactionTimeout, start |
Constructor Detail |
public DefaultIndexer(java.lang.Object associatedStore)
associatedStore
- a properties- or content storeMethod Detail |
public IBasicExpressionFactory getBasicExpressionFactory()
getBasicExpressionFactory
in interface IBasicExpressionFactoryProvider
public void createIndex(Uri uri, NodeRevisionDescriptor revisionDescriptor, NodeRevisionContent revisionContent) throws IndexException
createIndex
in interface Indexer
uri
- UrirevisionContent
- the content of the resource
IndexException
- Error accessing the Data Sourcepublic void updateIndex(Uri uri, NodeRevisionDescriptor revisionDescriptor, NodeRevisionContent revisionContent) throws IndexException
updateIndex
in interface Indexer
uri
- uri of the resourcerevisionContent
- the content of the resource
IndexException
public void dropIndex(Uri uri, NodeRevisionNumber number) throws IndexException
dropIndex
in interface Indexer
uri
- Urinumber
- nodeRevisionNumber of the resource
IndexException
- Error accessing the Data Sourcepublic void connect() throws ServiceConnectionFailedException
connect
in interface Service
connect
in class XAServiceBase
ServiceConnectionFailedException
- Connection failedpublic boolean isConnected() throws ServiceAccessException
isConnected
in interface Service
isConnected
in class XAServiceBase
ServiceAccessException
- Service access errorpublic void setParameters(java.util.Hashtable parameters) throws ServiceParameterErrorException, ServiceParameterMissingException
setParameters
in interface Service
setParameters
in class XAServiceBase
parameters
- Hashtable containing the parameters' names
and associated values
ServiceParameterErrorException
- Incorrect service parameter
ServiceParameterMissingException
- Service parameter missingpublic void disconnect() throws ServiceDisconnectionFailedException
disconnect
in interface Service
disconnect
in class XAServiceBase
ServiceDisconnectionFailedException
- Disconnection failedpublic void reset() throws ServiceResetFailedException
reset
in interface Service
reset
in class XAServiceBase
ServiceResetFailedException
- Reset failed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |