Class SimpleReactiveCosmosRepository<T,K extends Serializable>
java.lang.Object
com.azure.spring.data.cosmos.repository.support.SimpleReactiveCosmosRepository<T,K>
- All Implemented Interfaces:
ReactiveCosmosRepository<T,
,K> org.springframework.data.repository.reactive.ReactiveCrudRepository<T,
,K> org.springframework.data.repository.reactive.ReactiveSortingRepository<T,
,K> org.springframework.data.repository.Repository<T,
K>
public class SimpleReactiveCosmosRepository<T,K extends Serializable>
extends Object
implements ReactiveCosmosRepository<T,K>
Repository class for simple reactive Cosmos operation
-
Constructor Summary
ConstructorDescriptionSimpleReactiveCosmosRepository
(CosmosEntityInformation<T, K> metadata, ReactiveCosmosOperations reactiveCosmosOperations) Initialization with metadata and reactiveCosmosOperations -
Method Summary
Modifier and TypeMethodDescriptioncount()
deleteAllById
(Iterable<? extends K> ids) deleteById
(K id) deleteById
(K id, PartitionKey partitionKey) Deletes an entity by its id and partition key.deleteById
(org.reactivestreams.Publisher<K> publisher) existsById
(K id) existsById
(org.reactivestreams.Publisher<K> publisher) findAll()
findAll
(PartitionKey partitionKey) Returns Flux of items in a specific partitionfindAll
(org.springframework.data.domain.Sort sort) findAllById
(Iterable<K> ids) findAllById
(org.reactivestreams.Publisher<K> ids) findById
(K id, PartitionKey partitionKey) Retrieves an entity by its id and partition key.save
(S entity) saveAll
(org.reactivestreams.Publisher<S> entityStream)
-
Constructor Details
-
SimpleReactiveCosmosRepository
public SimpleReactiveCosmosRepository(CosmosEntityInformation<T, K> metadata, ReactiveCosmosOperations reactiveCosmosOperations) Initialization with metadata and reactiveCosmosOperations- Parameters:
metadata
- for entityInformationreactiveCosmosOperations
- for cosmosOperations
-
-
Method Details
-
findAll
- Specified by:
findAll
in interfaceorg.springframework.data.repository.reactive.ReactiveSortingRepository<T,
K extends Serializable>
-
findAll
Description copied from interface:ReactiveCosmosRepository
Returns Flux of items in a specific partition- Specified by:
findAll
in interfaceReactiveCosmosRepository<T,
K extends Serializable> - Parameters:
partitionKey
- partition key value- Returns:
Flux
of items with partition key value
-
save
- Specified by:
save
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
saveAll
- Specified by:
saveAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
saveAll
- Specified by:
saveAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findById
- Specified by:
findById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findById
- Specified by:
findById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findById
Description copied from interface:ReactiveCosmosRepository
Retrieves an entity by its id and partition key.- Specified by:
findById
in interfaceReactiveCosmosRepository<T,
K extends Serializable> - Parameters:
id
- must not be null.partitionKey
- partition key value of the entity, must not be null.- Returns:
Mono
emitting the entity with the given id orMono.empty()
if none found.
-
existsById
- Specified by:
existsById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
existsById
- Specified by:
existsById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findAll
- Specified by:
findAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findAllById
- Specified by:
findAllById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
findAllById
- Specified by:
findAllById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
count
- Specified by:
count
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteById
- Specified by:
deleteById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteById
- Specified by:
deleteById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteById
Description copied from interface:ReactiveCosmosRepository
Deletes an entity by its id and partition key.- Specified by:
deleteById
in interfaceReactiveCosmosRepository<T,
K extends Serializable> - Parameters:
id
- must not be null.partitionKey
- partition key value of the entity, must not be null.- Returns:
Mono
emitting the void Mono.
-
delete
- Specified by:
delete
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteAllById
- Specified by:
deleteAllById
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteAll
- Specified by:
deleteAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteAll
- Specified by:
deleteAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-
deleteAll
- Specified by:
deleteAll
in interfaceorg.springframework.data.repository.reactive.ReactiveCrudRepository<T,
K extends Serializable>
-