public class DataSourceIngestMapper extends Object implements IngestMapper
A Ingest Mapper that indexes to an DataSource Database
Modifier and Type | Field and Description |
---|---|
protected DataSource |
dataSource |
Constructor and Description |
---|
DataSourceIngestMapper(String user,
String pass,
String driver,
String jdbcUrl) |
Modifier and Type | Method and Description |
---|---|
void |
deleteAllMappingsForCatalog(String catalogId) |
void |
deleteAllMappingsForCatalogServiceTransactionId(TransactionId<?> catalogServiceTransactionId) |
void |
deleteTransactionIdMapping(TransactionId<?> catalogTransactionId,
String catalogId) |
Set<String> |
getCatalogIds(TransactionId<?> catalogServiceTransactionId)
Get all the Catalog URNs for which the given TransactionId was mapped
|
CatalogReceipt |
getCatalogReceipt(TransactionId<?> catalogServiceTransactionId,
String catalogId) |
TransactionId<?> |
getCatalogServiceTransactionId(TransactionId<?> catalogTransactionId,
String catalogId)
Get the CatalogService TransactionId that was mapped to the given Catalog
URN and Catalog TransactionId
|
TransactionId<?> |
getCatalogTransactionId(TransactionId<?> catalogServiceTransactionId,
String catalogId)
Get the Catalog TransactionId that was mapped to the given Catalog ID
and CatalogService TransactionId
|
Set<TransactionId<?>> |
getPageOfCatalogTransactionIds(IndexPager indexPager,
String catalogId) |
boolean |
hasCatalogServiceTransactionId(TransactionId<?> catalogServiceTransactionId)
Verify if the given CatalogService TransactionId has been stored in a
mapping
storeTransactionIdMapping(String, TransactionId>,
TransactionId>) |
void |
storeTransactionIdMapping(TransactionId<?> catalogServiceTransactionId,
TransactionIdFactory catalogServiceTransactionIdFactory,
CatalogReceipt catalogReceipt,
TransactionIdFactory catalogTransactionIdFactory)
Maps the three arguments to each other so any of the others can be
retrieved via one of the other arguments
|
protected DataSource dataSource
public DataSourceIngestMapper(String user, String pass, String driver, String jdbcUrl) throws InstantiationException
InstantiationException
public void deleteAllMappingsForCatalog(String catalogId) throws CatalogRepositoryException
deleteAllMappingsForCatalog
in interface IngestMapper
CatalogRepositoryException
public void deleteAllMappingsForCatalogServiceTransactionId(TransactionId<?> catalogServiceTransactionId) throws CatalogRepositoryException
deleteAllMappingsForCatalogServiceTransactionId
in interface IngestMapper
CatalogRepositoryException
public void deleteTransactionIdMapping(TransactionId<?> catalogTransactionId, String catalogId) throws CatalogRepositoryException
deleteTransactionIdMapping
in interface IngestMapper
CatalogRepositoryException
public TransactionId<?> getCatalogServiceTransactionId(TransactionId<?> catalogTransactionId, String catalogId) throws CatalogRepositoryException
IngestMapper
getCatalogServiceTransactionId
in interface IngestMapper
catalogTransactionId
- A Catalog TransactionIdcatalogId
- A unique Catalog ID when the Catalog TransactionId was usedCatalogRepositoryException
- Any Errorpublic TransactionId<?> getCatalogTransactionId(TransactionId<?> catalogServiceTransactionId, String catalogId) throws CatalogRepositoryException
IngestMapper
getCatalogTransactionId
in interface IngestMapper
catalogServiceTransactionId
- A Catalog TransactionIdcatalogId
- A unique Catalog ID when the Catalog TransactionId was usedCatalogRepositoryException
- Any Errorpublic Set<String> getCatalogIds(TransactionId<?> catalogServiceTransactionId) throws CatalogRepositoryException
IngestMapper
getCatalogIds
in interface IngestMapper
catalogServiceTransactionId
- A CatalogService TransactionIdCatalogRepositoryException
- Any Errorpublic Set<TransactionId<?>> getPageOfCatalogTransactionIds(IndexPager indexPager, String catalogId) throws CatalogRepositoryException
getPageOfCatalogTransactionIds
in interface IngestMapper
CatalogRepositoryException
public boolean hasCatalogServiceTransactionId(TransactionId<?> catalogServiceTransactionId) throws CatalogRepositoryException
IngestMapper
storeTransactionIdMapping(String, TransactionId>,
TransactionId>)
hasCatalogServiceTransactionId
in interface IngestMapper
catalogServiceTransactionId
- The CatalogService TransactionId in questionCatalogRepositoryException
- Any errorpublic void storeTransactionIdMapping(TransactionId<?> catalogServiceTransactionId, TransactionIdFactory catalogServiceTransactionIdFactory, CatalogReceipt catalogReceipt, TransactionIdFactory catalogTransactionIdFactory) throws CatalogRepositoryException
IngestMapper
storeTransactionIdMapping
in interface IngestMapper
catalogServiceTransactionId
- TransactionId generated by the CatalogServiceCatalogRepositoryException
- Any errorpublic CatalogReceipt getCatalogReceipt(TransactionId<?> catalogServiceTransactionId, String catalogId) throws CatalogRepositoryException
getCatalogReceipt
in interface IngestMapper
CatalogRepositoryException
Copyright © 1999-2014 Apache OODT. All Rights Reserved.