Class ReactiveAerospikeTemplate

java.lang.Object
org.springframework.data.aerospike.core.ReactiveAerospikeTemplate
All Implemented Interfaces:
ReactiveAerospikeOperations, IndexesCacheRefresher

public class ReactiveAerospikeTemplate extends Object implements ReactiveAerospikeOperations, IndexesCacheRefresher
Primary implementation of ReactiveAerospikeOperations.
Author:
Igor Ermolenko, Volodymyr Shpynta, Yevhen Tsyba
  • Constructor Summary

    Constructors
    Constructor
    Description
    ReactiveAerospikeTemplate(com.aerospike.client.reactor.IAerospikeReactorClient reactorClient, String namespace, MappingAerospikeConverter converter, AerospikeMappingContext mappingContext, AerospikeExceptionTranslator exceptionTranslator, ReactorQueryEngine queryEngine, ReactorIndexRefresher reactorIndexRefresher, ServerVersionSupport serverVersionSupport)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    <T> reactor.core.publisher.Mono<T>
    add(T document, String binName, long value)
    Find an existing record matching the document's class and id, add specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    add(T document, String setName, String binName, long value)
    Find an existing record matching the document's id and the given set name, add specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    add(T document, String setName, Map<String,Long> values)
    Find an existing record matching the document's id and the given set name, add map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    add(T document, Map<String,Long> values)
    Find an existing record matching the document's class and id, add map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    append(T document, String binName, String value)
    Find an existing record matching the document's class and id, append specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    append(T document, String setName, String binName, String value)
    Find an existing record matching the document's id and the given set name, append specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    append(T document, String setName, Map<String,String> values)
    Find an existing record matching the document's id and the given set name, append map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    append(T document, Map<String,String> values)
    Find an existing record matching the document's class and id, append map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<Long>
    count(Class<T> entityClass)
    Reactively return the amount of records in the set determined by the given entityClass.
    reactor.core.publisher.Mono<Long>
    count(String setName)
    Reactively return the amount of records in the given Aerospike set.
    <T> reactor.core.publisher.Mono<Long>
    count(Query query, Class<T> entityClass)
    Reactively return the amount of records in query results.
    reactor.core.publisher.Mono<Long>
    count(Query query, String setName)
    Reactively return the amount of records in query results within the given set.
    <T> reactor.core.publisher.Mono<Void>
    createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType)
    Reactively create an index with the specified name in Aerospike.
    <T> reactor.core.publisher.Mono<Void>
    createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType)
    Reactively create an index with the specified name in Aerospike.
    <T> reactor.core.publisher.Mono<Void>
    createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType, com.aerospike.client.cdt.CTX... ctx)
    Reactively create an index with the specified name in Aerospike.
    reactor.core.publisher.Mono<Void>
    createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType)
    Reactively create an index with the specified name in Aerospike.
    reactor.core.publisher.Mono<Void>
    createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType)
    Reactively create an index with the specified name in Aerospike.
    reactor.core.publisher.Mono<Void>
    createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType, com.aerospike.client.cdt.CTX... ctx)
    Reactively create an index with the specified name in Aerospike.
    <T> reactor.core.publisher.Mono<Void>
    delete(Class<T> entityClass)
    Deprecated, for removal: This API element is subject to removal in a future version.
    <T> reactor.core.publisher.Mono<Boolean>
    delete(Object id, Class<T> entityClass)
    Deprecated, for removal: This API element is subject to removal in a future version.
    <T> reactor.core.publisher.Mono<Boolean>
    delete(T document)
    Reactively delete a record using the document's id.
    <T> reactor.core.publisher.Mono<Boolean>
    delete(T document, String setName)
    Reactively delete a record within the given set using the document's id.
    <T> reactor.core.publisher.Mono<Void>
    deleteAll(Class<T> entityClass)
    Reactively truncate/delete all records in the set determined by the given entity class.
    <T> reactor.core.publisher.Mono<Void>
    deleteAll(Class<T> entityClass, Instant beforeLastUpdate)
    Reactively truncate/delete all records in the set determined by the given entity class.
    <T> reactor.core.publisher.Mono<Void>
    deleteAll(Iterable<T> documents)
    Reactively delete multiple records in one batch request.
    <T> reactor.core.publisher.Mono<Void>
    deleteAll(Iterable<T> documents, String setName)
    Reactively delete multiple records within the given set (overrides the default set associated with the documents) in one batch request.
    reactor.core.publisher.Mono<Void>
    deleteAll(String setName)
    Reactively truncate/delete all the documents in the given set.
    reactor.core.publisher.Mono<Void>
    deleteAll(String setName, Instant beforeLastUpdate)
    Reactively truncate/delete all documents in the given set.
    <T> reactor.core.publisher.Mono<Boolean>
    deleteById(Object id, Class<T> entityClass)
    Reactively delete a record by id, set name will be determined by the given entity class.
    reactor.core.publisher.Mono<Boolean>
    deleteById(Object id, String setName)
    Reactively delete a record by id within the given set.
    <T> reactor.core.publisher.Mono<Void>
    deleteByIds(Iterable<?> ids, Class<T> entityClass)
    Reactively delete records using a single batch delete operation, set name will be determined by the given entity class.
    reactor.core.publisher.Mono<Void>
    deleteByIds(Iterable<?> ids, String setName)
    Reactively delete records within the given set using a single batch delete operation.
    reactor.core.publisher.Mono<Void>
    deleteByIds(GroupedKeys groupedKeys)
    Reactively delete records from different sets in a single request.
    <T> reactor.core.publisher.Mono<Void>
    deleteIndex(Class<T> entityClass, String indexName)
    Reactively delete an index with the specified name in Aerospike.
    reactor.core.publisher.Mono<Void>
    deleteIndex(String setName, String indexName)
    Reactively delete an index with the specified name within the given set in Aerospike.
    <T> reactor.core.publisher.Mono<T>
    execute(Supplier<T> supplier)
    Reactively execute operation against underlying store.
    <T> reactor.core.publisher.Mono<Boolean>
    exists(Object id, Class<T> entityClass)
    Reactively check by id if a record exists within the set associated with the given entityClass.
    reactor.core.publisher.Mono<Boolean>
    exists(Object id, String setName)
    Reactively check by id if a record exists within the given set name.
    <T> reactor.core.publisher.Mono<Boolean>
    existsByQuery(Query query, Class<T> entityClass)
    Reactively check using a query if any matching records exist within the set determined by the given entityClass.
    <T> reactor.core.publisher.Mono<Boolean>
    existsByQuery(Query query, Class<T> entityClass, String setName)
    Reactively check using a query if any matching records exist within the given set.
    <T> reactor.core.publisher.Flux<T>
    find(Query query, Class<T> entityClass)
    Reactively find records in the given entityClass's set using a query and map them to the given class type.
    <T, S> reactor.core.publisher.Flux<S>
    find(Query query, Class<T> entityClass, Class<S> targetClass)
    Reactively find records in the given entityClass's set using a query and map them to the given target class type.
    <T> reactor.core.publisher.Flux<T>
    find(Query query, Class<T> targetClass, String setName)
    Reactively find records in the given set using a query and map them to the given target class type.
    <T> reactor.core.publisher.Flux<T>
    findAll(Class<T> entityClass)
    Reactively find all records in the given entityClass's set and map them to the given class type.
    <T, S> reactor.core.publisher.Flux<S>
    findAll(Class<T> entityClass, Class<S> targetClass)
    Reactively find all records in the given entityClass's set and map them to the given target class type.
    <T> reactor.core.publisher.Flux<T>
    findAll(Class<T> targetClass, String setName)
    Reactively find all records in the given set and map them to the given class type.
    <T> reactor.core.publisher.Flux<T>
    findAll(Sort sort, long offset, long limit, Class<T> entityClass)
    Reactively find all records in the given entityClass's set using a provided sort and map them to the given class type.
    <T, S> reactor.core.publisher.Flux<S>
    findAll(Sort sort, long offset, long limit, Class<T> entityClass, Class<S> targetClass)
    Reactively find all records in the given entityClass's set using a provided sort and map them to the given target class type.
    <T> reactor.core.publisher.Flux<T>
    findAll(Sort sort, long offset, long limit, Class<T> targetClass, String setName)
    Reactively find all records in the given entityClass's set using a provided sort and map them to the given target class type.
    <T> reactor.core.publisher.Mono<T>
    findById(Object id, Class<T> entityClass)
    Reactively find a record by id, set name will be determined by the given entityClass.
    <T, S> reactor.core.publisher.Mono<S>
    findById(Object id, Class<T> entityClass, Class<S> targetClass)
    Reactively find a record by id, set name will be determined by the given entityClass.
    <T, S> reactor.core.publisher.Mono<S>
    findById(Object id, Class<T> entityClass, Class<S> targetClass, String setName)
    Reactively find a record by id within the given set.
    <T> reactor.core.publisher.Mono<T>
    findById(Object id, Class<T> entityClass, String setName)
    Reactively find a record by id within the given set.
    <T> reactor.core.publisher.Flux<T>
    findByIds(Iterable<?> ids, Class<T> entityClass)
    Reactively find records by ids using a single batch read operation, set name will be determined by the given entityClass.
    <T, S> reactor.core.publisher.Flux<S>
    findByIds(Iterable<?> ids, Class<T> entityClass, Class<S> targetClass)
    Reactively find records by ids using a single batch read operation, set name will be determined by the given entityClass.
    <T> reactor.core.publisher.Flux<T>
    findByIds(Iterable<?> ids, Class<T> targetClass, String setName)
    Reactively find records by ids within the given set using a single batch read operation.
    reactor.core.publisher.Mono<GroupedEntities>
    findByIds(GroupedKeys groupedKeys)
    Reactively execute a single batch request to find several records, possibly from different sets.
    <T, S> reactor.core.publisher.Flux<?>
    findByIdsUsingQuery(Collection<?> ids, Class<T> entityClass, Class<S> targetClass, String setName, Query query)
    Find records by ids within the given set name.
    <T, S> reactor.core.publisher.Flux<?>
    findByIdsUsingQuery(Collection<?> ids, Class<T> entityClass, Class<S> targetClass, Query query)
    Find records by ids, set name will be determined by the given entityClass.
    <T, S> reactor.core.publisher.Mono<?>
    findByIdUsingQuery(Object id, Class<T> entityClass, Class<S> targetClass, String setName, Query query)
    Find a record by id within the given set using a query.
    <T, S> reactor.core.publisher.Mono<?>
    findByIdUsingQuery(Object id, Class<T> entityClass, Class<S> targetClass, Query query)
    Find a record by id using a query, set name will be determined by the given entityClass.
    <T> reactor.core.publisher.Flux<T>
    findInRange(long offset, long limit, Sort sort, Class<T> entityClass)
    Reactively find records in the given entityClass's set using a range (offset, limit) and a sort and map them to the given class type.
    <T, S> reactor.core.publisher.Flux<S>
    findInRange(long offset, long limit, Sort sort, Class<T> entityClass, Class<S> targetClass)
    Reactively find records in the given entityClass's set using a range (offset, limit) and a sort and map them to the given target class type.
    <T> reactor.core.publisher.Flux<T>
    findInRange(long offset, long limit, Sort sort, Class<T> targetClass, String setName)
    Reactively find records in the given set using a range (offset, limit) and a sort and map them to the given class type.
    <T, S> reactor.core.publisher.Flux<S>
    findUsingQueryWithoutPostProcessing(Class<T> entityClass, Class<S> targetClass, Query query)
    Reactively find records in the given entityClass's set using a query and map them to the given target class type.
     
    com.aerospike.client.reactor.IAerospikeReactorClient
     
    <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T>
    getBatchWriteForDelete(T document, String setName)
     
    <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T>
    getBatchWriteForInsert(T document, String setName)
     
    <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T>
    getBatchWriteForSave(T document, String setName)
     
    <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T>
    getBatchWriteForUpdate(T document, String setName)
     
     
     
    long
     
    <T> String
    getSetName(Class<T> entityClass)
     
    <T> String
    getSetName(T document)
     
    reactor.core.publisher.Mono<Boolean>
    indexExists(String indexName)
    Check whether an index with the specified name exists in Aerospike.
    <T> reactor.core.publisher.Mono<T>
    insert(T document)
    Reactively insert a document using RecordExistsAction.CREATE_ONLY policy.
    <T> reactor.core.publisher.Mono<T>
    insert(T document, String setName)
    Reactively insert a document within the given set using RecordExistsAction.CREATE_ONLY policy.
    <T> reactor.core.publisher.Flux<T>
    insertAll(Iterable<? extends T> documents)
    Reactively insert documents using one batch request.
    <T> reactor.core.publisher.Flux<T>
    insertAll(Iterable<? extends T> documents, String setName)
    Reactively insert documents within the given set using one batch request.
    <T> reactor.core.publisher.Mono<T>
    persist(T document, com.aerospike.client.policy.WritePolicy policy)
    Reactively persist a document using specified WritePolicy.
    <T> reactor.core.publisher.Mono<T>
    persist(T document, com.aerospike.client.policy.WritePolicy policy, String setName)
    Reactively persist a document within the given set (overrides the default set associated with the document) using specified WritePolicy.
    <T> reactor.core.publisher.Mono<T>
    prepend(T document, String binName, String value)
    Find an existing record matching the document's class and id, prepend specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    prepend(T document, String setName, String binName, String value)
    Find an existing record matching the document's id and the given set name, prepend specified value to the record's bin and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    prepend(T document, String setName, Map<String,String> values)
    Find an existing record matching the document's id and the given set name, prepend map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    <T> reactor.core.publisher.Mono<T>
    prepend(T document, Map<String,String> values)
    Find an existing record matching the document's class and id, prepend map values to the corresponding bins of the record and return the modified record mapped to the document's class.
    void
     
    <T> reactor.core.publisher.Mono<T>
    save(T document)
    Reactively save a document.
    <T> reactor.core.publisher.Mono<T>
    save(T document, String setName)
    Reactively save a document within the given set.
    <T> reactor.core.publisher.Flux<T>
    saveAll(Iterable<T> documents)
    Reactively save documents using one batch request.
    <T> reactor.core.publisher.Flux<T>
    saveAll(Iterable<T> documents, String setName)
    Reactively save documents within the given set using one batch request.
    <T> reactor.core.publisher.Mono<T>
    update(T document)
    Reactively update a record using RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document if it is present.
    <T> reactor.core.publisher.Mono<T>
    update(T document, String setName)
    Reactively update a record within the given set using RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document if it is present.
    <T> reactor.core.publisher.Mono<T>
    update(T document, String setName, Collection<String> fields)
    Reactively update specific fields of a record based on the given collection of fields within the given set using RecordExistsAction.UPDATE_ONLY policy.
    <T> reactor.core.publisher.Mono<T>
    update(T document, Collection<String> fields)
    Reactively update specific bins of a record based on the given collection of fields using RecordExistsAction.UPDATE_ONLY policy.
    <T> reactor.core.publisher.Flux<T>
    updateAll(Iterable<? extends T> documents)
    Reactively update records using one batch request.
    <T> reactor.core.publisher.Flux<T>
    updateAll(Iterable<? extends T> documents, String setName)
    Reactively update records within the given set using one batch request.

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.springframework.data.aerospike.core.ReactiveAerospikeOperations

    getAerospikeConverter, getMappingContext
  • Constructor Details

  • Method Details

    • refreshIndexesCache

      public void refreshIndexesCache()
      Specified by:
      refreshIndexesCache in interface IndexesCacheRefresher
    • save

      public <T> reactor.core.publisher.Mono<T> save(T document)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively save a document.

      If the document has version property, CAS algorithm is used for updating record. Version property is used for deciding whether to create new record or update existing. If the version is set to zero, a new record will be created, creation will fail if such record already exists. If version is greater than zero, existing record will be updated with RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document. Version property will be updated with the server's version after successful operation.

      If the document does not have version property, the record is updated with RecordExistsAction.UPDATE policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE). This means that when such record does not exist it will be created, otherwise updated (an "upsert").

      Specified by:
      save in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be saved. Must not be null.
      Returns:
      A Mono of the new saved document.
    • save

      public <T> reactor.core.publisher.Mono<T> save(T document, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively save a document within the given set.

      If the document has version property, CAS algorithm is used for updating record. Version property is used for deciding whether to create new record or update existing. If the version is set to zero, a new record will be created, creation will fail if such record already exists. If version is greater than zero, existing record will be updated with RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document. Version property will be updated with the server's version after successful operation.

      If the document does not have version property, the record is updated with RecordExistsAction.UPDATE policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE). This means that when such record does not exist it will be created, otherwise updated (an "upsert").

      Specified by:
      save in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be saved. Must not be null.
      setName - The set name to save the document.
      Returns:
      A Mono of the new saved document.
    • saveAll

      public <T> reactor.core.publisher.Flux<T> saveAll(Iterable<T> documents)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively save documents using one batch request. The policies are analogous to ReactiveAerospikeOperations.save(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      saveAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents to be saved. Must not be null.
      Returns:
      A Flux of the saved documents
    • saveAll

      public <T> reactor.core.publisher.Flux<T> saveAll(Iterable<T> documents, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively save documents within the given set using one batch request. The policies are analogous to ReactiveAerospikeOperations.save(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      saveAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents to be saved. Must not be null.
      setName - The set name to save to documents.
      Returns:
      A Flux of the saved documents
    • insert

      public <T> reactor.core.publisher.Mono<T> insert(T document)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively insert a document using RecordExistsAction.CREATE_ONLY policy.

      If the document has version property it will be updated with the server's version after successful operation.

      Specified by:
      insert in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be inserted. Must not be null.
      Returns:
      A Mono of the new inserted document.
    • insert

      public <T> reactor.core.publisher.Mono<T> insert(T document, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively insert a document within the given set using RecordExistsAction.CREATE_ONLY policy.

      If the document has version property it will be updated with the server's version after successful operation.

      Specified by:
      insert in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be inserted. Must not be null.
      setName - The set name to insert the document.
      Returns:
      A Mono of the new inserted document.
    • insertAll

      public <T> reactor.core.publisher.Flux<T> insertAll(Iterable<? extends T> documents)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively insert documents using one batch request. The policies are analogous to ReactiveAerospikeOperations.insert(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      insertAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - Documents to insert. Must not be null.
      Returns:
      A Flux of the inserted documents
    • insertAll

      public <T> reactor.core.publisher.Flux<T> insertAll(Iterable<? extends T> documents, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively insert documents within the given set using one batch request. The policies are analogous to ReactiveAerospikeOperations.insert(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      insertAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - Documents to insert. Must not be null.
      setName - The set name to insert the documents.
      Returns:
      A Flux of the inserted documents
    • persist

      public <T> reactor.core.publisher.Mono<T> persist(T document, com.aerospike.client.policy.WritePolicy policy)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively persist a document using specified WritePolicy.
      Specified by:
      persist in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be persisted. Must not be null.
      policy - The Aerospike write policy for the inner Aerospike put operation. Must not be null.
      Returns:
      A Mono of the new persisted document.
    • persist

      public <T> reactor.core.publisher.Mono<T> persist(T document, com.aerospike.client.policy.WritePolicy policy, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively persist a document within the given set (overrides the default set associated with the document) using specified WritePolicy.
      Specified by:
      persist in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to be persisted. Must not be null.
      policy - The Aerospike write policy for the inner Aerospike put operation. Must not be null.
      setName - Set name to override the set associated with the document.
      Returns:
      A Mono of the new persisted document.
    • update

      public <T> reactor.core.publisher.Mono<T> update(T document)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update a record using RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document if it is present.

      If the document has version property it will be updated with the server's version after successful operation.

      Specified by:
      update in interface ReactiveAerospikeOperations
      Parameters:
      document - The document that identifies the record to be updated. Must not be null.
      Returns:
      A Mono of the new updated document.
    • update

      public <T> reactor.core.publisher.Mono<T> update(T document, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update a record within the given set using RecordExistsAction.UPDATE_ONLY policy combined with removing bins at first (analogous to RecordExistsAction.REPLACE_ONLY) taking into consideration the version property of the document if it is present.

      If document has version property it will be updated with the server's version after successful operation.

      Specified by:
      update in interface ReactiveAerospikeOperations
      Parameters:
      document - The document that identifies the record to be updated. Must not be null.
      setName - The set name to update the document.
      Returns:
      A Mono of the new updated document.
    • update

      public <T> reactor.core.publisher.Mono<T> update(T document, Collection<String> fields)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update specific bins of a record based on the given collection of fields using RecordExistsAction.UPDATE_ONLY policy. You can instantiate the document with only relevant fields and specify the list of fields that you want to update, taking into consideration the version property of the document if it is present.

      If document has version property it will be updated with the server's version after successful operation.

      Specified by:
      update in interface ReactiveAerospikeOperations
      Parameters:
      document - The document that identifies the record to be updated. Must not be null.
      Returns:
      A Mono of the new updated document.
    • update

      public <T> reactor.core.publisher.Mono<T> update(T document, String setName, Collection<String> fields)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update specific fields of a record based on the given collection of fields within the given set using RecordExistsAction.UPDATE_ONLY policy. You can instantiate the document with only relevant fields and specify the list of fields that you want to update, taking into consideration the version property of the document if it is present.

      If document has version property it will be updated with the server's version after successful operation.

      Specified by:
      update in interface ReactiveAerospikeOperations
      Parameters:
      document - The document that identifies the record to be updated. Must not be null.
      setName - The set name to update the document.
      Returns:
      A Mono of the new updated document.
    • updateAll

      public <T> reactor.core.publisher.Flux<T> updateAll(Iterable<? extends T> documents)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update records using one batch request. The policies are analogous to ReactiveAerospikeOperations.update(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      updateAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents that identify the records to be updated. Must not be null.
      Returns:
      A Flux of the updated documents
    • updateAll

      public <T> reactor.core.publisher.Flux<T> updateAll(Iterable<? extends T> documents, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively update records within the given set using one batch request. The policies are analogous to ReactiveAerospikeOperations.update(Object).

      The order of returned results is preserved. The execution order is NOT preserved.

      Requires Server version 6.0+.

      Specified by:
      updateAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents that identify the records to be updated. Must not be null.
      setName - The set name to update the documents.
      Returns:
      A Flux of the updated documents
    • delete

      @Deprecated(since="4.6.0", forRemoval=true) public <T> reactor.core.publisher.Mono<Void> delete(Class<T> entityClass)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: ReactiveAerospikeOperations
      Reactively truncate/delete all records from the set determined by the given entityClass.
      Specified by:
      delete in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract the Aerospike set name from. Must not be null.
    • delete

      @Deprecated(since="4.6.0", forRemoval=true) public <T> reactor.core.publisher.Mono<Boolean> delete(Object id, Class<T> entityClass)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete a record by id, set name will be determined by the given entity class.
      Specified by:
      delete in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of a record to be deleted. Must not be null.
      entityClass - The class to extract the Aerospike set name from. Must not be null.
      Returns:
      A Mono of whether the document existed on server before deletion.
    • delete

      public <T> reactor.core.publisher.Mono<Boolean> delete(T document)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete a record using the document's id.

      If the document has version property it will be compared with the corresponding record's version on server.

      Specified by:
      delete in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from. Must not be null.
      Returns:
      A Mono of whether the record existed on server before deletion.
    • delete

      public <T> reactor.core.publisher.Mono<Boolean> delete(T document, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete a record within the given set using the document's id.
      Specified by:
      delete in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from. Must not be null.
      setName - Set name to use.
      Returns:
      A Mono of whether the record existed on server before deletion.
    • deleteById

      public <T> reactor.core.publisher.Mono<Boolean> deleteById(Object id, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete a record by id, set name will be determined by the given entity class.

      If the document has version property it is not compared with the corresponding record's version on server.

      Specified by:
      deleteById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to be deleted. Must not be null.
      entityClass - The class to extract the Aerospike set name from. Must not be null.
      Returns:
      A Mono of whether the record existed on server before deletion.
    • deleteById

      public reactor.core.publisher.Mono<Boolean> deleteById(Object id, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete a record by id within the given set.

      If the document has version property it is not compared with the corresponding record's version on server.

      Specified by:
      deleteById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to be deleted. Must not be null.
      setName - Set name to use.
      Returns:
      A Mono of whether the record existed on server before deletion.
    • deleteAll

      public <T> reactor.core.publisher.Mono<Void> deleteAll(Iterable<T> documents)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete multiple records in one batch request. The policies are analogous to ReactiveAerospikeOperations.delete(Object).

      The execution order is NOT preserved.

      This operation requires Server version 6.0+.

      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents to be deleted. Must not be null.
    • deleteAll

      public <T> reactor.core.publisher.Mono<Void> deleteAll(Iterable<T> documents, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete multiple records within the given set (overrides the default set associated with the documents) in one batch request. The policies are analogous to ReactiveAerospikeOperations.delete(Object).

      The execution order is NOT preserved.

      This operation requires Server version 6.0+.

      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      documents - The documents to be deleted. Must not be null.
      setName - Set name to override the default set associated with the documents.
    • deleteByIds

      public <T> reactor.core.publisher.Mono<Void> deleteByIds(Iterable<?> ids, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete records using a single batch delete operation, set name will be determined by the given entity class. The policies are analogous to ReactiveAerospikeOperations.deleteById(Object, Class).

      This operation requires Server version 6.0+.

      Specified by:
      deleteByIds in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the records to find. Must not be null.
      entityClass - The class to extract the Aerospike set name from and to map the results to. Must not be null.
    • deleteByIds

      public reactor.core.publisher.Mono<Void> deleteByIds(Iterable<?> ids, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete records within the given set using a single batch delete operation. The policies are analogous to ReactiveAerospikeOperations.deleteById(Object, String).

      This operation requires Server version 6.0+.

      Specified by:
      deleteByIds in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      setName - Set name to use.
    • deleteByIds

      public reactor.core.publisher.Mono<Void> deleteByIds(GroupedKeys groupedKeys)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete records from different sets in a single request.

      Records' versions on server are not checked.

      This operation requires Server version 6.0+.

      Specified by:
      deleteByIds in interface ReactiveAerospikeOperations
      Parameters:
      groupedKeys - Keys grouped by document type. Must not be null, groupedKeys.getEntitiesKeys() must not be null.
    • deleteAll

      public <T> reactor.core.publisher.Mono<Void> deleteAll(Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively truncate/delete all records in the set determined by the given entity class.
      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
    • deleteAll

      public <T> reactor.core.publisher.Mono<Void> deleteAll(Class<T> entityClass, Instant beforeLastUpdate)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively truncate/delete all records in the set determined by the given entity class.
      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      beforeLastUpdate - Delete records before the specified time (must be earlier than the current time at millisecond resolution).
    • deleteAll

      public reactor.core.publisher.Mono<Void> deleteAll(String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively truncate/delete all the documents in the given set.
      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to use.
    • deleteAll

      public reactor.core.publisher.Mono<Void> deleteAll(String setName, Instant beforeLastUpdate)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively truncate/delete all documents in the given set.
      Specified by:
      deleteAll in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to truncate/delete all records in.
      beforeLastUpdate - Delete records before the specified time (must be earlier than the current time at millisecond resolution).
    • add

      public <T> reactor.core.publisher.Mono<T> add(T document, Map<String,Long> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, add map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      add in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      values - The Map of bin names and values to add. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • add

      public <T> reactor.core.publisher.Mono<T> add(T document, String setName, Map<String,Long> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, add map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      add in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      values - The Map of bin names and values to add. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • add

      public <T> reactor.core.publisher.Mono<T> add(T document, String binName, long value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, add specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      add in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      binName - Bin name to use add operation on. Must not be null.
      value - The value to add.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • add

      public <T> reactor.core.publisher.Mono<T> add(T document, String setName, String binName, long value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, add specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      add in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      binName - Bin name to use add operation on. Must not be null.
      value - The value to add.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • append

      public <T> reactor.core.publisher.Mono<T> append(T document, Map<String,String> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, append map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      append in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      values - The Map of bin names and values to append. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • append

      public <T> reactor.core.publisher.Mono<T> append(T document, String setName, Map<String,String> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, append map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      append in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      values - The Map of bin names and values to append. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • append

      public <T> reactor.core.publisher.Mono<T> append(T document, String binName, String value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, append specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      append in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      binName - Bin name to use append operation on.
      value - The value to append.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • append

      public <T> reactor.core.publisher.Mono<T> append(T document, String setName, String binName, String value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, append specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      append in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      binName - Bin name to use append operation on.
      value - The value to append.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • prepend

      public <T> reactor.core.publisher.Mono<T> prepend(T document, Map<String,String> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, prepend map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      prepend in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      values - The Map of bin names and values to prepend. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • prepend

      public <T> reactor.core.publisher.Mono<T> prepend(T document, String setName, Map<String,String> values)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, prepend map values to the corresponding bins of the record and return the modified record mapped to the document's class.
      Specified by:
      prepend in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      values - The Map of bin names and values to prepend. Must not be null.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • prepend

      public <T> reactor.core.publisher.Mono<T> prepend(T document, String binName, String value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's class and id, prepend specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      prepend in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get set name and id from and to map the result to. Must not be null.
      binName - Bin name to use prepend operation on.
      value - The value to prepend.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • prepend

      public <T> reactor.core.publisher.Mono<T> prepend(T document, String setName, String binName, String value)
      Description copied from interface: ReactiveAerospikeOperations
      Find an existing record matching the document's id and the given set name, prepend specified value to the record's bin and return the modified record mapped to the document's class.
      Specified by:
      prepend in interface ReactiveAerospikeOperations
      Parameters:
      document - The document to get id from and to map the result to. Must not be null.
      setName - Set name to use.
      binName - Bin name to use prepend operation on.
      value - The value to prepend.
      Returns:
      A Mono of the modified record mapped to the document's class.
    • execute

      public <T> reactor.core.publisher.Mono<T> execute(Supplier<T> supplier)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively execute operation against underlying store.
      Specified by:
      execute in interface ReactiveAerospikeOperations
      Parameters:
      supplier - must not be null.
      Returns:
      A Mono of the execution result.
    • findById

      public <T> reactor.core.publisher.Mono<T> findById(Object id, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find a record by id, set name will be determined by the given entityClass.

      The matching record will be mapped to the given entityClass.

      Specified by:
      findById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to extract set name from and to map the document to. Must not be null.
      Returns:
      A Mono of the matching record mapped to entityClass type.
    • findById

      public <T> reactor.core.publisher.Mono<T> findById(Object id, Class<T> entityClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find a record by id within the given set.

      The matching record will be mapped to the given entityClass.

      Specified by:
      findById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to map the record to and to get entity properties from (such expiration). Must not be null.
      setName - Set name to use.
      Returns:
      A Mono of the matching record mapped to entityClass type.
    • findById

      public <T, S> reactor.core.publisher.Mono<S> findById(Object id, Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find a record by id, set name will be determined by the given entityClass.

      The matching record will be mapped to the given targetClass.

      Specified by:
      findById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to. Must not be null.
      Returns:
      A Mono of the matching record mapped to targetClass type.
    • findById

      public <T, S> reactor.core.publisher.Mono<S> findById(Object id, Class<T> entityClass, Class<S> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find a record by id within the given set.

      The matching record will be mapped to the given targetClass.

      Specified by:
      findById in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to map the record to and to get entity properties from (such expiration). Must not be null.
      targetClass - The class to map the record to. Must not be null.
      setName - Set name to use.
      Returns:
      A Mono of the matching record mapped to targetClass type.
    • findByIds

      public <T> reactor.core.publisher.Flux<T> findByIds(Iterable<?> ids, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records by ids using a single batch read operation, set name will be determined by the given entityClass.

      The records will be mapped to the given entityClass.

      Specified by:
      findByIds in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      entityClass - The class to extract set name from and to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findByIds

      public <T, S> reactor.core.publisher.Flux<S> findByIds(Iterable<?> ids, Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records by ids using a single batch read operation, set name will be determined by the given entityClass.

      The records will be mapped to the given targetClass.

      Specified by:
      findByIds in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findByIds

      public <T> reactor.core.publisher.Flux<T> findByIds(Iterable<?> ids, Class<T> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records by ids within the given set using a single batch read operation.

      The records will be mapped to the given entityClass.

      Specified by:
      findByIds in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      targetClass - The class to map the documents to. Must not be null.
      setName - Set name to use.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findByIds

      public reactor.core.publisher.Mono<GroupedEntities> findByIds(GroupedKeys groupedKeys)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively execute a single batch request to find several records, possibly from different sets.

      Aerospike provides functionality to get records from different sets in 1 batch request. This method receives keys grouped by document type as a parameter and returns Aerospike records mapped to documents grouped by type.

      Specified by:
      findByIds in interface ReactiveAerospikeOperations
      Parameters:
      groupedKeys - Keys grouped by document type. Must not be null, groupedKeys.getEntitiesKeys() must not be null.
      Returns:
      Mono of grouped documents.
    • findByIdUsingQuery

      public <T, S> reactor.core.publisher.Mono<?> findByIdUsingQuery(Object id, Class<T> entityClass, Class<S> targetClass, Query query)
      Description copied from interface: ReactiveAerospikeOperations
      Find a record by id using a query, set name will be determined by the given entityClass.

      The records will be mapped to the given targetClass.

      Specified by:
      findByIdUsingQuery in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to.
      query - The Query to filter results. Optional argument (null if no filtering required).
      Returns:
      The matching record mapped to targetClass's type.
    • findByIdUsingQuery

      public <T, S> reactor.core.publisher.Mono<?> findByIdUsingQuery(Object id, Class<T> entityClass, Class<S> targetClass, String setName, Query query)
      Description copied from interface: ReactiveAerospikeOperations
      Find a record by id within the given set using a query.

      The records will be mapped to the given targetClass.

      Specified by:
      findByIdUsingQuery in interface ReactiveAerospikeOperations
      Parameters:
      id - The id of the record to find. Must not be null.
      entityClass - The class to get the entity properties from (such as expiration). Must not be null.
      targetClass - The class to map the record to.
      setName - Set name to use.
      query - The Query to filter results. Optional argument (null if no filtering required).
      Returns:
      The matching record mapped to targetClass's type.
    • findByIdsUsingQuery

      public <T, S> reactor.core.publisher.Flux<?> findByIdsUsingQuery(Collection<?> ids, Class<T> entityClass, Class<S> targetClass, Query query)
      Description copied from interface: ReactiveAerospikeOperations
      Find records by ids, set name will be determined by the given entityClass.

      The records will be mapped to the given targetClass.

      Specified by:
      findByIdsUsingQuery in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to.
      query - The Query to filter results. Optional argument (null if no filtering required).
      Returns:
      The documents from Aerospike, returned documents will be mapped to targetClass's type if provided (otherwise to entityClass's type), if no document exists, an empty list is returned.
    • findByIdsUsingQuery

      public <T, S> reactor.core.publisher.Flux<?> findByIdsUsingQuery(Collection<?> ids, Class<T> entityClass, Class<S> targetClass, String setName, Query query)
      Description copied from interface: ReactiveAerospikeOperations
      Find records by ids within the given set name.

      The records will be mapped to the given targetClass.

      Specified by:
      findByIdsUsingQuery in interface ReactiveAerospikeOperations
      Parameters:
      ids - The ids of the documents to find. Must not be null.
      entityClass - The class to get the entity properties from (such as expiration). Must not be null.
      targetClass - The class to map the record to.
      setName - Set name to use.
      query - The Query to filter results. Optional argument (null if no filtering required).
      Returns:
      The documents from Aerospike, returned documents will be mapped to targetClass's type if provided (otherwise to entityClass's type), if no document exists, an empty list is returned.
    • find

      public <T> reactor.core.publisher.Flux<T> find(Query query, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given entityClass's set using a query and map them to the given class type.
      Specified by:
      find in interface ReactiveAerospikeOperations
      Parameters:
      query - The Query to filter results. Must not be null.
      entityClass - The class to extract set name from and to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • find

      public <T, S> reactor.core.publisher.Flux<S> find(Query query, Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given entityClass's set using a query and map them to the given target class type.
      Specified by:
      find in interface ReactiveAerospikeOperations
      Parameters:
      query - The Query to filter results. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to. Must not be null.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • find

      public <T> reactor.core.publisher.Flux<T> find(Query query, Class<T> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given set using a query and map them to the given target class type.
      Specified by:
      find in interface ReactiveAerospikeOperations
      Parameters:
      query - The Query to filter results. Must not be null.
      targetClass - The class to map the record to. Must not be null.
      setName - Set name to use.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findAll

      public <T> reactor.core.publisher.Flux<T> findAll(Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given entityClass's set and map them to the given class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from and to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findAll

      public <T, S> reactor.core.publisher.Flux<S> findAll(Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given entityClass's set and map them to the given target class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to. Must not be null.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findAll

      public <T> reactor.core.publisher.Flux<T> findAll(Class<T> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given set and map them to the given class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      targetClass - The class to map the documents to. Must not be null.
      setName - The set name to find the document.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findAll

      public <T> reactor.core.publisher.Flux<T> findAll(Sort sort, long offset, long limit, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given entityClass's set using a provided sort and map them to the given class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      sort - The sort to affect the returned iterable documents order.
      offset - The offset to start the range from.
      limit - The limit of the range.
      entityClass - The class to extract set name from and to map the documents to.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findAll

      public <T, S> reactor.core.publisher.Flux<S> findAll(Sort sort, long offset, long limit, Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given entityClass's set using a provided sort and map them to the given target class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      sort - The sort to affect the returned iterable documents order.
      offset - The offset to start the range from.
      limit - The limit of the range.
      entityClass - The class to extract set name from.
      targetClass - The class to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findAll

      public <T> reactor.core.publisher.Flux<T> findAll(Sort sort, long offset, long limit, Class<T> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find all records in the given entityClass's set using a provided sort and map them to the given target class type.
      Specified by:
      findAll in interface ReactiveAerospikeOperations
      Parameters:
      sort - The sort to affect the returned iterable documents order.
      offset - The offset to start the range from.
      limit - The limit of the range.
      targetClass - The class to map the documents to. Must not be null.
      setName - The set name to find the documents.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findInRange

      public <T> reactor.core.publisher.Flux<T> findInRange(long offset, long limit, Sort sort, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given entityClass's set using a range (offset, limit) and a sort and map them to the given class type.
      Specified by:
      findInRange in interface ReactiveAerospikeOperations
      Parameters:
      offset - The offset to start the range from.
      limit - The limit of the range.
      sort - The sort to affect the order of the returned Stream of documents.
      entityClass - The class to extract set name from and to map the documents to. Must not be null.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • findInRange

      public <T, S> reactor.core.publisher.Flux<S> findInRange(long offset, long limit, Sort sort, Class<T> entityClass, Class<S> targetClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given entityClass's set using a range (offset, limit) and a sort and map them to the given target class type.
      Specified by:
      findInRange in interface ReactiveAerospikeOperations
      Parameters:
      offset - The offset to start the range from.
      limit - The limit of the range.
      sort - The sort to affect the returned Stream of documents order.
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to. Must not be null.
      Returns:
      A Flux of matching records mapped to targetClass type.
    • findInRange

      public <T> reactor.core.publisher.Flux<T> findInRange(long offset, long limit, Sort sort, Class<T> targetClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given set using a range (offset, limit) and a sort and map them to the given class type.
      Specified by:
      findInRange in interface ReactiveAerospikeOperations
      Parameters:
      offset - The offset to start the range from.
      limit - The limit of the range.
      sort - The sort to affect the order of the returned Stream of documents.
      targetClass - The class to map the record to. Must not be null.
      setName - Set name to use.
      Returns:
      A Flux of matching records mapped to entityClass type.
    • exists

      public <T> reactor.core.publisher.Mono<Boolean> exists(Object id, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively check by id if a record exists within the set associated with the given entityClass.
      Specified by:
      exists in interface ReactiveAerospikeOperations
      Parameters:
      id - The id to check for record existence. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      Returns:
      A Mono of whether the record exists.
    • exists

      public reactor.core.publisher.Mono<Boolean> exists(Object id, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively check by id if a record exists within the given set name.
      Specified by:
      exists in interface ReactiveAerospikeOperations
      Parameters:
      id - The id to check for record existence. Must not be null.
      setName - Set name to use.
      Returns:
      A Mono of whether the record exists.
    • existsByQuery

      public <T> reactor.core.publisher.Mono<Boolean> existsByQuery(Query query, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively check using a query if any matching records exist within the set determined by the given entityClass.
      Specified by:
      existsByQuery in interface ReactiveAerospikeOperations
      Parameters:
      query - The query to check if any returned document exists. Must not be null.
      entityClass - The class to extract set name from. Must not be null.
      Returns:
      A Mono of whether matching records exist.
    • existsByQuery

      public <T> reactor.core.publisher.Mono<Boolean> existsByQuery(Query query, Class<T> entityClass, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively check using a query if any matching records exist within the given set.
      Specified by:
      existsByQuery in interface ReactiveAerospikeOperations
      Parameters:
      query - The query to check if any matching records exist. Must not be null.
      entityClass - The class to translate to returned records into. Must not be null.
      setName - Set name to use. Must not be null.
      Returns:
      A Mono of whether matching records exist.
    • count

      public <T> reactor.core.publisher.Mono<Long> count(Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively return the amount of records in the set determined by the given entityClass.
      Specified by:
      count in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      Returns:
      A Mono of the amount of records in the set (of the given entityClass).
    • count

      public reactor.core.publisher.Mono<Long> count(String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively return the amount of records in the given Aerospike set.
      Specified by:
      count in interface ReactiveAerospikeOperations
      Parameters:
      setName - The name of the set to count. Must not be null.
      Returns:
      A Mono of the amount of records in the given set.
    • count

      public <T> reactor.core.publisher.Mono<Long> count(Query query, Class<T> entityClass)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively return the amount of records in query results. Set name will be determined by the given entityClass.
      Specified by:
      count in interface ReactiveAerospikeOperations
      Parameters:
      query - The query that provides the result set for count.
      entityClass - entityClass to extract set name from. Must not be null.
      Returns:
      A Mono of the amount of records matching the given query and entity class.
    • count

      public reactor.core.publisher.Mono<Long> count(Query query, String setName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively return the amount of records in query results within the given set.
      Specified by:
      count in interface ReactiveAerospikeOperations
      Parameters:
      query - The query that provides the result set for count.
      setName - The name of the set to count. Must not be null.
      Returns:
      A Mono of the amount of records matching the given query and set name.
    • createIndex

      public <T> reactor.core.publisher.Mono<Void> createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
    • createIndex

      public <T> reactor.core.publisher.Mono<Void> createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
      indexCollectionType - The collection type of the index. Must not be null.
    • createIndex

      public <T> reactor.core.publisher.Mono<Void> createIndex(Class<T> entityClass, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType, com.aerospike.client.cdt.CTX... ctx)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
      indexCollectionType - The collection type of the index. Must not be null.
      ctx - optional context to index on elements within a CDT.
    • createIndex

      public reactor.core.publisher.Mono<Void> createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to use.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
    • createIndex

      public reactor.core.publisher.Mono<Void> createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to use.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
      indexCollectionType - The collection type of the index. Must not be null.
    • createIndex

      public reactor.core.publisher.Mono<Void> createIndex(String setName, String indexName, String binName, com.aerospike.client.query.IndexType indexType, com.aerospike.client.query.IndexCollectionType indexCollectionType, com.aerospike.client.cdt.CTX... ctx)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively create an index with the specified name in Aerospike.
      Specified by:
      createIndex in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to use.
      indexName - The index name. Must not be null.
      binName - The bin name to create the index on. Must not be null.
      indexType - The type of the index. Must not be null.
      indexCollectionType - The collection type of the index. Must not be null.
      ctx - Optional context to index elements within a CDT.
    • deleteIndex

      public <T> reactor.core.publisher.Mono<Void> deleteIndex(Class<T> entityClass, String indexName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete an index with the specified name in Aerospike.
      Specified by:
      deleteIndex in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      indexName - The index name. Must not be null.
    • deleteIndex

      public reactor.core.publisher.Mono<Void> deleteIndex(String setName, String indexName)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively delete an index with the specified name within the given set in Aerospike.
      Specified by:
      deleteIndex in interface ReactiveAerospikeOperations
      Parameters:
      setName - Set name to use.
      indexName - The index name. Must not be null.
    • indexExists

      public reactor.core.publisher.Mono<Boolean> indexExists(String indexName)
      Description copied from interface: ReactiveAerospikeOperations
      Check whether an index with the specified name exists in Aerospike.
      Specified by:
      indexExists in interface ReactiveAerospikeOperations
      Parameters:
      indexName - The Aerospike index name. Must not be null.
      Returns:
      Mono of true if exists.
    • getAerospikeReactorClient

      public com.aerospike.client.reactor.IAerospikeReactorClient getAerospikeReactorClient()
      Specified by:
      getAerospikeReactorClient in interface ReactiveAerospikeOperations
      Returns:
      Aerospike reactive client in use.
    • getQueryMaxRecords

      public long getQueryMaxRecords()
      Specified by:
      getQueryMaxRecords in interface ReactiveAerospikeOperations
      Returns:
      Value of configuration parameter
      invalid reference
      AerospikeDataSettings#getQueryMaxRecords()
      .
    • findUsingQueryWithoutPostProcessing

      public <T, S> reactor.core.publisher.Flux<S> findUsingQueryWithoutPostProcessing(Class<T> entityClass, Class<S> targetClass, Query query)
      Description copied from interface: ReactiveAerospikeOperations
      Reactively find records in the given entityClass's set using a query and map them to the given target class type. If the query has pagination and/or sorting, post-processing must be applied separately.
      Specified by:
      findUsingQueryWithoutPostProcessing in interface ReactiveAerospikeOperations
      Parameters:
      entityClass - The class to extract set name from. Must not be null.
      targetClass - The class to map the record to.
      query - The Query to filter results.
      Returns:
      A Flux of all matching records mapped to targetClass type (regardless of pagination/sorting).
    • getSetName

      public <T> String getSetName(Class<T> entityClass)
    • getSetName

      public <T> String getSetName(T document)
    • getMappingContext

      public MappingContext<?,?> getMappingContext()
    • getAerospikeConverter

      public MappingAerospikeConverter getAerospikeConverter()
    • getNamespace

      public String getNamespace()
    • getBatchWriteForSave

      public <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T> getBatchWriteForSave(T document, String setName)
    • getBatchWriteForInsert

      public <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T> getBatchWriteForInsert(T document, String setName)
    • getBatchWriteForUpdate

      public <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T> getBatchWriteForUpdate(T document, String setName)
    • getBatchWriteForDelete

      public <T> org.springframework.data.aerospike.core.BaseAerospikeTemplate.BatchWriteData<T> getBatchWriteForDelete(T document, String setName)