Use overlapping validity: create a new secret version, deploy apps that can use the new secret, then revoke the old one. Prefer short-lived credentials where possible. Make sure apps reload secrets safely (restart/sidecar/reload hook) and monitor failures during the rollout.
Expanding on the short answer — what usually matters in practice:
A tiny example (an explanation template):
// Example: discuss trade-offs for "secrets-rotation:-how-do-you-rotate-credentials-"
function explain() {
// Start from the core idea:
// Use overlapping validity: create a new secret version, deploy apps that can use the new se
}