Redacted returns the ReplicationCfg with password of the remote database redacted from both replication config and remote URL, i.e., any password will be replaced with xxxxx.
(ctx context.Context)
| 377 | // Redacted returns the ReplicationCfg with password of the remote database redacted from |
| 378 | // both replication config and remote URL, i.e., any password will be replaced with xxxxx. |
| 379 | func (rc *ReplicationConfig) Redacted(ctx context.Context) *ReplicationConfig { |
| 380 | config := *rc |
| 381 | if config.Password != "" { |
| 382 | config.Password = base.RedactedStr |
| 383 | } |
| 384 | if config.RemotePassword != "" { |
| 385 | config.RemotePassword = base.RedactedStr |
| 386 | } |
| 387 | config.Remote = base.RedactBasicAuthURLPassword(ctx, config.Remote) |
| 388 | return &config |
| 389 | } |
| 390 | |
| 391 | // sgReplicateManager should be used for all interactions with the stored cluster definition. |
| 392 | type sgReplicateManager struct { |
no test coverage detected