Package org.springframework.vault.core
Interface ReactiveVaultVersionedKeyValueOperations
- All Superinterfaces:
ReactiveVaultKeyValueOperationsSupport
- All Known Implementing Classes:
ReactiveVaultVersionedKeyValueTemplate
public interface ReactiveVaultVersionedKeyValueOperations
extends ReactiveVaultKeyValueOperationsSupport
Interface that specifies a basic set of Vault operations using Vault's versioned
Key/Value (kv version 2) secret backend. Paths used in this operations interface are
relative and outgoing requests prepend paths with the according operation-specific
prefix.
Clients using versioned Key/Value must be aware they are reading from a versioned
backend as the versioned Key/Value API (kv version 2) is different from the unversioned
Key/Value API (kv version 1). TODO: Update JavaDocs
- Since:
- 3.1
- Author:
- Timothy R. Weiand
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondelete
(String path, Versioned.Version... versionsToDelete) Delete one or moreversions
of the secret atpath
.destroy
(String path, Versioned.Version... versionsToDelete) Permanently remove the specifiedversions
of the secret atpath
.Read the most recent secret atpath
.Read the most recent secret atpath
and deserialize the secret to the givenresponseType
.get
(String path, Versioned.Version version) Read the requestedVersioned.Version
of the secret atpath
.get
(String path, Versioned.Version version, Class<T> responseType) Read the requestedVersioned.Version
of the secret atpath
and deserialize the secret to the givenresponseType
.Write theversioned secret
atpath
.undelete
(String path, Versioned.Version... versionsToDelete) Undelete (restore) one or moreversions
of the secret atpath
.Methods inherited from interface org.springframework.vault.core.ReactiveVaultKeyValueOperationsSupport
delete, getApiVersion, list
-
Method Details
-
get
Read the most recent secret atpath
.- Specified by:
get
in interfaceReactiveVaultKeyValueOperationsSupport
- Parameters:
path
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
get
Read the requestedVersioned.Version
of the secret atpath
.- Parameters:
path
- must not be null.version
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
get
Read the most recent secret atpath
and deserialize the secret to the givenresponseType
.- Parameters:
path
- must not be null.responseType
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
get
Read the requestedVersioned.Version
of the secret atpath
and deserialize the secret to the givenresponseType
.- Parameters:
path
- must not be null.version
- must not be null.responseType
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
put
Write theversioned secret
atpath
.body
may be either plain secrets (e.g. map) orVersioned
objects. UsingVersioned
will apply versioning for Compare-and-Set (CAS).- Parameters:
path
- must not be null.body
- must not be null.- Returns:
- the resulting
Versioned.Metadata
.
-
delete
Delete one or moreversions
of the secret atpath
.- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
undelete
Undelete (restore) one or moreversions
of the secret atpath
.- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
destroy
Permanently remove the specifiedversions
of the secret atpath
.- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
opsForKeyValueMetadata
ReactiveVaultKeyValueMetadataOperations opsForKeyValueMetadata()- Returns:
- the operations interface to interact with the Vault Key/Value metadata backend
-