Interface DbSecrets
-
- All Superinterfaces:
Secrets
public interface DbSecrets extends Secrets
Database secrets engine API.All methods block the current thread. This implementation is not suitable for reactive programming. Use
DbSecretsRx
in reactive code.
-
-
Field Summary
Fields Modifier and Type Field Description static Engine<DbSecretsRx>
ENGINE
Database secrets engine.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description DbConfigure.Response
configure(DbConfigure.Request<?> request)
Configure a database.static DbSecrets
create(DbSecretsRx reactive)
Create blocking DB secrets from its reactive counterpart.DbCreateRole.Response
createRole(DbCreateRole.Request request)
Create or update a role definition.DbDelete.Response
delete(DbDelete.Request request)
Delete a database configuration.default DbDelete.Response
delete(String name)
Delete a database configuration.DbDeleteRole.Response
deleteRole(DbDeleteRole.Request request)
Delete a database role.default DbDeleteRole.Response
deleteRole(String name)
Delete a database role.VaultOptionalResponse<DbGet.Response>
get(DbGet.Request request)
Get credentials from the/creds
endpoint.default Optional<DbCredentials>
get(String name)
Get credentials from the/creds
endpoint.VaultOptionalResponse<ListSecrets.Response>
list(ListSecrets.Request request)
List database connections.
-
-
-
Field Detail
-
ENGINE
static final Engine<DbSecretsRx> ENGINE
Database secrets engine.Documentation: https://www.vaultproject.io/docs/secrets/databases
-
-
Method Detail
-
create
static DbSecrets create(DbSecretsRx reactive)
Create blocking DB secrets from its reactive counterpart.- Parameters:
reactive
- reactive DB secrets- Returns:
- blocking DB secrets
-
list
VaultOptionalResponse<ListSecrets.Response> list(ListSecrets.Request request)
List database connections.
-
get
default Optional<DbCredentials> get(String name)
Get credentials from the/creds
endpoint.- Parameters:
name
- name of the credentials- Returns:
- credentials
-
get
VaultOptionalResponse<DbGet.Response> get(DbGet.Request request)
Get credentials from the/creds
endpoint.- Parameters:
request
- request with at least the name- Returns:
- get DB response
-
createRole
DbCreateRole.Response createRole(DbCreateRole.Request request)
Create or update a role definition.- Parameters:
request
- role request- Returns:
- when the role is created
-
configure
DbConfigure.Response configure(DbConfigure.Request<?> request)
Configure a database.- Parameters:
request
- configuration options - see specific database types- Returns:
- when the database is configured
-
delete
default DbDelete.Response delete(String name)
Delete a database configuration.- Parameters:
name
- name of the database configuration- Returns:
- when the database configuration is deleted
-
delete
DbDelete.Response delete(DbDelete.Request request)
Delete a database configuration.- Parameters:
request
- delete request with at least name configured- Returns:
- delete database configuration response
-
deleteRole
default DbDeleteRole.Response deleteRole(String name)
Delete a database role.- Parameters:
name
- name of the role- Returns:
- when the role is deleted
-
deleteRole
DbDeleteRole.Response deleteRole(DbDeleteRole.Request request)
Delete a database role.- Parameters:
request
- request with at least the role name configured- Returns:
- delete database role response
-
-