title: Updating auto renewed DB password in JDBC connection - Spring Boot
body: <p>I have a strange use case running spring boot microservices, the services lives inside an openshift cluster and the problem I face is due to a database password renewal policy. 
  The app uses JDBC connection to access an oracle database and the DB password is retrieved during container startup from a homegrown vault. The issue is the password keeps change once every 90 days.</p>
  
  <p>The application uses JDBC connection pool to talk to the database and the service is expected to receive a high volume of traffic, therefore an increased number of sessions. I<strong>n the middle of a session if the password gets renewed how do we ensure we use the working password to run queries always in the jdbc connection pool</strong>.</p>
  
  <p>We tried a couple of things running a separate service that would retrieve the password momentarily and the consumer service which requires the password would simply use the last successful password from the database service, its kind of an ugly implementation.
  Tried multi-container pods with an Auxillary pod listening for database changes and that was a lame idea as well.</p>
  
  <p>The core problem is loading up JDBC connection pool which already has the auth to establish to connection and communicate with the database. So in the middle of a session how do we update the password? 
  Any ideas ?</p>