Package org.openmetadata.service.search
Interface SearchClient
- All Known Implementing Classes:
ElasticSearchClient,OpenSearchClient
public interface SearchClient
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.Responsejavax.json.JsonObjectdefault es.org.elasticsearch.action.bulk.BulkResponsebulk(es.org.elasticsearch.action.bulk.BulkRequest data, es.org.elasticsearch.client.RequestOptions options) default os.org.opensearch.action.bulk.BulkResponsebulk(os.org.opensearch.action.bulk.BulkRequest data, os.org.opensearch.client.RequestOptions options) voidclose()voidcreateAliases(IndexMapping indexMapping) default SSLContextcreateElasticSearchSSLContext(ElasticSearchConfiguration elasticSearchConfiguration) voidcreateEntity(String indexName, String docId, String doc) voidcreateIndex(IndexMapping indexMapping, String indexMappingContent) voidcreateTimeSeriesEntity(String indexName, String docId, String doc) voidvoiddeleteEntity(String indexName, String docId) voiddeleteEntityByFields(String indexName, List<org.apache.commons.lang3.tuple.Pair<String, String>> fieldAndValue) voiddeleteIndex(IndexMapping indexMapping) getSortedDate(String team, Long scheduleTime, Long currentTime, DataInsightChartResult.DataInsightChartType chartType, String indexName) default intgetSuccessFromBulkResponse(es.org.elasticsearch.action.bulk.BulkResponse response) default intgetSuccessFromBulkResponse(os.org.opensearch.action.bulk.BulkResponse response) booleanindexExists(String indexName) booleanjavax.ws.rs.core.ResponselistDataInsightChartResult(Long startTs, Long endTs, String tier, String team, DataInsightChartResult.DataInsightChartType dataInsightChartName, Integer size, Integer from, String queryFilter, String dataReportIndex) javax.ws.rs.core.Responsesearch(SearchRequest request) javax.ws.rs.core.ResponsesearchByField(String fieldName, String fieldValue, String index) javax.ws.rs.core.ResponsesearchBySourceUrl(String sourceUrl) javax.ws.rs.core.ResponsesearchLineage(String fqn, int upstreamDepth, int downstreamDepth, String queryFilter, boolean deleted, String entityType) voidsoftDeleteOrRestoreChildren(String indexName, String scriptTxt, List<org.apache.commons.lang3.tuple.Pair<String, String>> fieldAndValue) voidsoftDeleteOrRestoreEntity(String indexName, String docId, String scriptTxt) javax.ws.rs.core.Responsesuggest(SearchRequest request) voidupdateChildren(String indexName, org.apache.commons.lang3.tuple.Pair<String, String> fieldAndValue, org.apache.commons.lang3.tuple.Pair<String, Map<String, Object>> updates) voidvoidupdateIndex(IndexMapping indexMapping, String indexMappingContent) voidupdateLineage(String indexName, org.apache.commons.lang3.tuple.Pair<String, String> fieldAndValue, Map<String, Object> lineagaData)
-
Field Details
-
UPDATE
- See Also:
-
ADD
- See Also:
-
DELETE
- See Also:
-
GLOBAL_SEARCH_ALIAS
- See Also:
-
DEFAULT_UPDATE_SCRIPT
- See Also:
-
REMOVE_DOMAINS_CHILDREN_SCRIPT
- See Also:
-
PROPAGATE_ENTITY_REFERENCE_FIELD_SCRIPT
- See Also:
-
PROPAGATE_FIELD_SCRIPT
- See Also:
-
REMOVE_PROPAGATED_ENTITY_REFERENCE_FIELD_SCRIPT
- See Also:
-
REMOVE_PROPAGATED_FIELD_SCRIPT
- See Also:
-
UPDATE_PROPAGATED_ENTITY_REFERENCE_FIELD_SCRIPT
- See Also:
-
SOFT_DELETE_RESTORE_SCRIPT
- See Also:
-
REMOVE_TAGS_CHILDREN_SCRIPT
- See Also:
-
REMOVE_LINEAGE_SCRIPT
- See Also:
-
ADD_UPDATE_LINEAGE
- See Also:
-
UPDATE_ADDED_DELETE_GLOSSARY_TAGS
- See Also:
-
REMOVE_TEST_SUITE_CHILDREN_SCRIPT
- See Also:
-
NOT_IMPLEMENTED_ERROR_TYPE
- See Also:
-
-
Method Details
-
isClientAvailable
boolean isClientAvailable() -
getSearchType
ElasticSearchConfiguration.SearchType getSearchType() -
indexExists
-
createIndex
-
updateIndex
-
deleteIndex
-
createAliases
-
search
- Throws:
IOException
-
searchBySourceUrl
- Throws:
IOException
-
searchLineage
javax.ws.rs.core.Response searchLineage(String fqn, int upstreamDepth, int downstreamDepth, String queryFilter, boolean deleted, String entityType) throws IOException - Throws:
IOException
-
searchByField
javax.ws.rs.core.Response searchByField(String fieldName, String fieldValue, String index) throws IOException - Throws:
IOException
-
aggregate
javax.ws.rs.core.Response aggregate(String index, String fieldName, String value, String query) throws IOException - Throws:
IOException
-
aggregate
javax.json.JsonObject aggregate(String query, String index, javax.json.JsonObject aggregationJson) throws IOException - Throws:
IOException
-
suggest
- Throws:
IOException
-
createEntity
-
createTimeSeriesEntity
-
updateEntity
-
deleteByScript
-
deleteEntity
-
deleteEntityByFields
-
softDeleteOrRestoreEntity
-
softDeleteOrRestoreChildren
-
updateChildren
-
updateLineage
-
getSortedDate
TreeMap<Long,List<Object>> getSortedDate(String team, Long scheduleTime, Long currentTime, DataInsightChartResult.DataInsightChartType chartType, String indexName) throws IOException, ParseException - Throws:
IOExceptionParseException
-
listDataInsightChartResult
javax.ws.rs.core.Response listDataInsightChartResult(Long startTs, Long endTs, String tier, String team, DataInsightChartResult.DataInsightChartType dataInsightChartName, Integer size, Integer from, String queryFilter, String dataReportIndex) throws IOException, ParseException - Throws:
IOExceptionParseException
-
bulk
default os.org.opensearch.action.bulk.BulkResponse bulk(os.org.opensearch.action.bulk.BulkRequest data, os.org.opensearch.client.RequestOptions options) throws IOException - Throws:
IOException
-
bulk
default es.org.elasticsearch.action.bulk.BulkResponse bulk(es.org.elasticsearch.action.bulk.BulkRequest data, es.org.elasticsearch.client.RequestOptions options) throws IOException - Throws:
IOException
-
getSuccessFromBulkResponse
default int getSuccessFromBulkResponse(os.org.opensearch.action.bulk.BulkResponse response) -
getSuccessFromBulkResponse
default int getSuccessFromBulkResponse(es.org.elasticsearch.action.bulk.BulkResponse response) -
close
void close() -
createElasticSearchSSLContext
default SSLContext createElasticSearchSSLContext(ElasticSearchConfiguration elasticSearchConfiguration) throws KeyStoreException - Throws:
KeyStoreException
-