Package org.springframework.vault.core
Class ReactiveVaultVersionedKeyValueTemplate
java.lang.Object
org.springframework.vault.core.ReactiveVaultVersionedKeyValueTemplate
- All Implemented Interfaces:
ReactiveVaultKeyValueOperationsSupport
,ReactiveVaultVersionedKeyValueOperations
public class ReactiveVaultVersionedKeyValueTemplate
extends Object
implements ReactiveVaultVersionedKeyValueOperations
Default implementation of
ReactiveVaultVersionedKeyValueOperations
.- Since:
- 3.1
- Author:
- Timothy R. Weiand
-
Field Summary
-
Constructor Summary
ConstructorDescriptionReactiveVaultVersionedKeyValueTemplate
(ReactiveVaultOperations reactiveVaultOperations, String path) Create a newReactiveVaultVersionedKeyValueTemplate
givenReactiveVaultOperations
and the mountpath
. -
Method Summary
Modifier and TypeMethodDescriptionDelete the secret atpath
.delete
(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
.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
.Enumerate keys from a Vault path.Write theversioned secret
atpath
.undelete
(String path, Versioned.Version... versionsToDelete) Undelete (restore) one or moreversions
of the secret atpath
.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.vault.core.ReactiveVaultKeyValueOperationsSupport
delete, getApiVersion, list
Methods inherited from interface org.springframework.vault.core.ReactiveVaultVersionedKeyValueOperations
get, get
-
Field Details
-
reactiveVaultOperations
-
-
Constructor Details
-
ReactiveVaultVersionedKeyValueTemplate
public ReactiveVaultVersionedKeyValueTemplate(ReactiveVaultOperations reactiveVaultOperations, String path) Create a newReactiveVaultVersionedKeyValueTemplate
givenReactiveVaultOperations
and the mountpath
.- Parameters:
reactiveVaultOperations
- must not be null.path
- must not be empty or null.
-
-
Method Details
-
get
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Read the requestedVersioned.Version
of the secret atpath
.- Specified by:
get
in interfaceReactiveVaultVersionedKeyValueOperations
- Parameters:
path
- must not be null.version
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
get
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Read the requestedVersioned.Version
of the secret atpath
and deserialize the secret to the givenresponseType
.- Specified by:
get
in interfaceReactiveVaultVersionedKeyValueOperations
- 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
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Write theversioned secret
atpath
.body
may be either plain secrets (e.g. map) orVersioned
objects. UsingVersioned
will apply versioning for Compare-and-Set (CAS).- Specified by:
put
in interfaceReactiveVaultVersionedKeyValueOperations
- Parameters:
path
- must not be null.body
- must not be null.- Returns:
- the resulting
Versioned.Metadata
.
-
delete
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Delete one or moreversions
of the secret atpath
.- Specified by:
delete
in interfaceReactiveVaultVersionedKeyValueOperations
- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
undelete
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Undelete (restore) one or moreversions
of the secret atpath
.- Specified by:
undelete
in interfaceReactiveVaultVersionedKeyValueOperations
- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
destroy
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
Permanently remove the specifiedversions
of the secret atpath
.- Specified by:
destroy
in interfaceReactiveVaultVersionedKeyValueOperations
- Parameters:
path
- must not be null.versionsToDelete
- must not be null or empty.
-
opsForKeyValueMetadata
Description copied from interface:ReactiveVaultVersionedKeyValueOperations
- Specified by:
opsForKeyValueMetadata
in interfaceReactiveVaultVersionedKeyValueOperations
- Returns:
- the operations interface to interact with the Vault Key/Value metadata backend
-
list
Description copied from interface:ReactiveVaultKeyValueOperationsSupport
Enumerate keys from a Vault path.- Parameters:
path
- must not be null.- Returns:
- the data. May be null if the path does not exist.
-
getApiVersion
- Returns:
- the used API version.
-
delete
Description copied from interface:ReactiveVaultKeyValueOperationsSupport
Delete the secret atpath
.- Specified by:
delete
in interfaceReactiveVaultKeyValueOperationsSupport
- Parameters:
path
- must not be null.
-