如何使用SecretLeaseContainer更新spring vault Postgres后端凭据?
@override public void afterPropertiesSet()抛出异常{
final RequestedSecret secret = RequestedSecret.renewable("postgres/creds/readonly");
leaseContainer.addLeaseListener(new LeaseListener() {
@Override
public void onLeaseEvent(SecretLeaseEvent secretLeaseEvent) {
if (secretLeaseEvent instanceof LeaseExpiredEvent) {
????
}
}
});
leaseContainer.addRequestedSecret(secret);
}