Class OpenSearchAnySearchDAO
- java.lang.Object
-
- org.apache.syncope.core.persistence.jpa.dao.AbstractDAO<Any<?>>
-
- org.apache.syncope.core.persistence.jpa.dao.AbstractAnySearchDAO
-
- org.apache.syncope.core.persistence.jpa.dao.OpenSearchAnySearchDAO
-
- All Implemented Interfaces:
AnySearchDAO
,DAO<Any<?>>
public class OpenSearchAnySearchDAO extends AbstractAnySearchDAO
Search engine implementation for users, groups and any objects, based on OpenSearch.
-
-
Field Summary
Fields Modifier and Type Field Description protected org.opensearch.client.opensearch.OpenSearchClient
client
protected int
indexMaxResultWindow
-
Fields inherited from class org.apache.syncope.core.persistence.jpa.dao.AbstractAnySearchDAO
anyObjectDAO, anyUtilsFactory, dynRealmDAO, entityFactory, groupDAO, plainSchemaDAO, realmDAO, RELATIONSHIP_FIELDS, userDAO, validator
-
Fields inherited from class org.apache.syncope.core.persistence.jpa.dao.AbstractDAO
LOG
-
-
Constructor Summary
Constructors Constructor Description OpenSearchAnySearchDAO(RealmDAO realmDAO, DynRealmDAO dynRealmDAO, UserDAO userDAO, GroupDAO groupDAO, AnyObjectDAO anyObjectDAO, PlainSchemaDAO schemaDAO, EntityFactory entityFactory, AnyUtilsFactory anyUtilsFactory, PlainAttrValidationManager validator, org.opensearch.client.opensearch.OpenSearchClient client, int indexMaxResultWindow)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
doCount(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, AnyTypeKind kind)
protected <T extends Any<?>>
List<T>doSearch(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, int page, int itemsPerPage, List<OrderByClause> orderBy, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
fillAttrQuery(PlainSchema schema, PlainAttrValue attrValue, AttrCond cond)
protected Triple<Optional<org.opensearch.client.opensearch._types.query_dsl.Query>,Set<String>,Set<String>>
getAdminRealmsFilter(Realm base, boolean recursive, Set<String> adminRealms, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(AnyCond cond, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(AnyTypeCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(AttrCond cond, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(AuxClassCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(DynRealmCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(MemberCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(MembershipCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(PrivilegeCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(RelationshipCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(RelationshipTypeCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(ResourceCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(RoleCond cond)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(SearchCond cond, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQuery(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, AnyTypeKind kind)
protected org.opensearch.client.opensearch._types.query_dsl.Query
getQueryForCustomConds(SearchCond cond, AnyTypeKind kind)
protected List<org.opensearch.client.opensearch._types.SortOptions>
sortBuilders(AnyTypeKind kind, List<OrderByClause> orderBy)
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.dao.AbstractAnySearchDAO
buildEffectiveCond, buildResult, check, check, check, check, check, count, search, search, search
-
Methods inherited from class org.apache.syncope.core.persistence.jpa.dao.AbstractDAO
detach, entityManager, entityManagerFactory, isOracle, refresh
-
-
-
-
Constructor Detail
-
OpenSearchAnySearchDAO
public OpenSearchAnySearchDAO(RealmDAO realmDAO, DynRealmDAO dynRealmDAO, UserDAO userDAO, GroupDAO groupDAO, AnyObjectDAO anyObjectDAO, PlainSchemaDAO schemaDAO, EntityFactory entityFactory, AnyUtilsFactory anyUtilsFactory, PlainAttrValidationManager validator, org.opensearch.client.opensearch.OpenSearchClient client, int indexMaxResultWindow)
-
-
Method Detail
-
getAdminRealmsFilter
protected Triple<Optional<org.opensearch.client.opensearch._types.query_dsl.Query>,Set<String>,Set<String>> getAdminRealmsFilter(Realm base, boolean recursive, Set<String> adminRealms, AnyTypeKind kind)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, AnyTypeKind kind)
-
doCount
protected int doCount(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, AnyTypeKind kind)
- Specified by:
doCount
in classAbstractAnySearchDAO
-
sortBuilders
protected List<org.opensearch.client.opensearch._types.SortOptions> sortBuilders(AnyTypeKind kind, List<OrderByClause> orderBy)
-
doSearch
protected <T extends Any<?>> List<T> doSearch(Realm base, boolean recursive, Set<String> adminRealms, SearchCond cond, int page, int itemsPerPage, List<OrderByClause> orderBy, AnyTypeKind kind)
- Specified by:
doSearch
in classAbstractAnySearchDAO
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(SearchCond cond, AnyTypeKind kind)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(AnyTypeCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(RelationshipTypeCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(RelationshipCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(MembershipCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(RoleCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(PrivilegeCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(DynRealmCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(MemberCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(AuxClassCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(ResourceCond cond)
-
fillAttrQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query fillAttrQuery(PlainSchema schema, PlainAttrValue attrValue, AttrCond cond)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(AttrCond cond, AnyTypeKind kind)
-
getQuery
protected org.opensearch.client.opensearch._types.query_dsl.Query getQuery(AnyCond cond, AnyTypeKind kind)
-
getQueryForCustomConds
protected org.opensearch.client.opensearch._types.query_dsl.Query getQueryForCustomConds(SearchCond cond, AnyTypeKind kind)
-
-