public class AnalyticsDataIndexer extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
INDEX_ID_INTERNAL_FIELD |
static String |
INDEX_INTERNAL_TIMESTAMP_FIELD |
| Constructor and Description |
|---|
AnalyticsDataIndexer(org.wso2.carbon.analytics.datasource.core.AnalyticsFileSystem analyticsFileSystem) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearIndices(int tenantId,
String tableName) |
void |
close() |
void |
clusterNoficationReceived(int tenantId,
String tableName) |
void |
delete(int tenantId,
String tableName,
List<String> ids)
Deletes the given records in the index.
|
void |
delete(int tenantId,
String tableName,
long timeFrom,
long timeTo)
Deletes the records in the index with the given time range.
|
org.wso2.carbon.analytics.datasource.core.AnalyticsFileSystem |
getFileSystem() |
AnalyticsIndexDefinitionRepository |
getRepository() |
void |
insert(List<org.wso2.carbon.analytics.datasource.core.Record> records)
Adds the given records to the index if they are previously scheduled to be indexed.
|
Map<String,IndexType> |
lookupIndices(int tenantId,
String tableName) |
List<SearchResultEntry> |
search(int tenantId,
String tableName,
String language,
String query,
int start,
int count) |
int |
searchCount(int tenantId,
String tableName,
String language,
String query) |
void |
setIndices(int tenantId,
String tableName,
Map<String,IndexType> columns) |
void |
update(List<org.wso2.carbon.analytics.datasource.core.Record> records)
Updates the given records in the index.
|
public static final String INDEX_ID_INTERNAL_FIELD
public static final String INDEX_INTERNAL_TIMESTAMP_FIELD
public AnalyticsDataIndexer(org.wso2.carbon.analytics.datasource.core.AnalyticsFileSystem analyticsFileSystem)
public org.wso2.carbon.analytics.datasource.core.AnalyticsFileSystem getFileSystem()
public AnalyticsIndexDefinitionRepository getRepository()
public List<SearchResultEntry> search(int tenantId, String tableName, String language, String query, int start, int count) throws AnalyticsIndexException
AnalyticsIndexExceptionpublic int searchCount(int tenantId,
String tableName,
String language,
String query)
throws AnalyticsIndexException
AnalyticsIndexExceptionpublic void insert(List<org.wso2.carbon.analytics.datasource.core.Record> records) throws org.wso2.carbon.analytics.datasource.core.AnalyticsException
records - The records to be indexedorg.wso2.carbon.analytics.datasource.core.AnalyticsExceptionpublic void update(List<org.wso2.carbon.analytics.datasource.core.Record> records) throws org.wso2.carbon.analytics.datasource.core.AnalyticsException
records - The records to be indexedorg.wso2.carbon.analytics.datasource.core.AnalyticsExceptionpublic void delete(int tenantId,
String tableName,
List<String> ids)
throws org.wso2.carbon.analytics.datasource.core.AnalyticsException
tenantId - The tenant idtableName - The table nameThe - ids of the records to be deletedorg.wso2.carbon.analytics.datasource.core.AnalyticsExceptionpublic void delete(int tenantId,
String tableName,
long timeFrom,
long timeTo)
throws org.wso2.carbon.analytics.datasource.core.AnalyticsException
tenantId - The tenant idtableName - The table nametimeFrom - The from time of records, inclusivetimeTo - The to time of records, non-inclusiveorg.wso2.carbon.analytics.datasource.core.AnalyticsExceptionpublic void setIndices(int tenantId,
String tableName,
Map<String,IndexType> columns)
throws AnalyticsIndexException
AnalyticsIndexExceptionpublic Map<String,IndexType> lookupIndices(int tenantId, String tableName) throws AnalyticsIndexException
AnalyticsIndexExceptionpublic void clearIndices(int tenantId,
String tableName)
throws AnalyticsIndexException
AnalyticsIndexExceptionpublic void clusterNoficationReceived(int tenantId,
String tableName)
throws AnalyticsIndexException
AnalyticsIndexExceptionpublic void close()
throws AnalyticsIndexException
AnalyticsIndexExceptionCopyright © 2015 WSO2. All rights reserved.