question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

fetch new secrets by spring-cloud-gcp-secretmanager after secrets updated in google-secret-manager.

See original GitHub issue

Can spring-cloud-gcp-secretmanager fetch secrets in real time if a secret is changed? Or, secrets are only fetched during application start? If it can fetch real time secrets update, then how is the cache configured? e.g. in case of a network issue etc., apps would continue to use values from cache? Thanks.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
elefeintcommented, Jul 25, 2022

Yeah, it’s a great workaround when you have a reasonable number of secrets, but if you have hundreds, having @RefreshScope configuration properties is more scalable. So ideally, we should make it work.

It’s also been a couple of Spring Cloud versions already since bootstrap method became legacy. We need to switch to supporting config.import before the legacy way becomes legend…

2reactions
JoeWang1127commented, Jul 22, 2022

I found a workaround while we are implementing #149 in here. You can also integrate GCP pub/sub to refresh the secret automatically when a new version of secret is created, please check the docs here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Retrieving Credentials/Secrets from Secret Manager with ...
In this codelab, you will build simple Spring Boot microservices and retrieve secrets / configuration values stored in Secret Manager.
Read more >
Managing secret versions - Documentation - Google Cloud
A secret version can be in one of the following states at any given time: Enabled - In this state, ... This is...
Read more >
Fetch secrets from Secret Manager to GKE - Issue Tracker
The app is expecting the DB instances username and password as environment variables. We have the credentials stored as secrets in Google Secret...
Read more >
Secret Management - Spring Boot on GCP
Secret Manager is a secure and convenient storage system for API keys, passwords, certificates, ... Add the Spring Cloud GCP Secret Manager starter:....
Read more >
Programmatically Access Google Cloud's Secret Manager
Once that works, we will refactor the python program to pull the authentication secret from Google Cloud Secret Manager.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found