Skip to content

refactor: replace config.Secret with commoncfg.Secret#4898

Merged
SoloJacobs merged 1 commit intoprometheus:mainfrom
TheMeier:commoncfg_secret
Feb 8, 2026
Merged

refactor: replace config.Secret with commoncfg.Secret#4898
SoloJacobs merged 1 commit intoprometheus:mainfrom
TheMeier:commoncfg_secret

Conversation

@TheMeier
Copy link
Contributor

@TheMeier TheMeier commented Jan 18, 2026

To be able to move notifier specific code out of the config and notify packages,
some shared code needs to be moved to other/new packages. Since commoncfg.Secret
already does what config.Secret does, this replaces all usages of config.Secret.

This requires external users of the config package to change their code if they used
config.MarshalSecretValue. This exported variable was added in
#4158

@TheMeier
Copy link
Contributor Author

TheMeier commented Jan 18, 2026

Sadly there is no SecretURL type in the common/config package. Since prometheus itself doesn't need it I think it is unlikely we cam move that type there.

@TheMeier TheMeier force-pushed the commoncfg_secret branch 3 times, most recently from eeef65c to 02449f8 Compare January 18, 2026 14:08
Copy link
Member

@waltherlee waltherlee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! It looks good to me ✅

@TheMeier TheMeier self-assigned this Feb 5, 2026
To be able to move notifier specific code out of the config and notify packages,
some shared code needs to be moved to other/new packages. Since commoncfg.Secret
already does what config.Secret does, this replaces all usages of config.Secret.

Signed-off-by: Christoph Maser <christoph.maser+github@gmail.com>
@SoloJacobs SoloJacobs merged commit 11f933f into prometheus:main Feb 8, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants