更新保险库Postgres后端凭据

时间:2017-08-22 07:00:39

标签: spring-vault

如何使用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);

}

0 个答案:

没有答案