Adding deprecate message to backup hooks#11491
Adding deprecate message to backup hooks#11491deepthi merged 7 commits intovitessio:release-15.0from
Conversation
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
If a new flag is being introduced:
If a workflow is added or modified:
Bug fixes
Non-trivial changes
New/Existing features
Backward compatibility
|
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
…ackup-hooks Signed-off-by: Manan Gupta <manan@planetscale.com>
|
@rsajwani I am taking the liberty to merge the release-15.0 branch since the VTOrc test names have changed and they are required now. |
go/vt/mysqlctl/backup.go
Outdated
| func registerBackupFlags(fs *pflag.FlagSet) { | ||
| fs.StringVar(&backupStorageHook, "backup_storage_hook", backupStorageHook, "if set, we send the contents of the backup files through this hook (deprecated: hooks will be disabled in v16.0. Please use ExternalCompressorCmd/ExternalDecompressorCmd instead).") | ||
| fs.StringVar(&backupStorageHook, "backup_storage_hook", backupStorageHook, "if set, we send the contents of the backup files through this hook.") | ||
| _ = fs.MarkDeprecated("backup_storage_hook", "--backup_storage_hook is deprecated; Consider using ExternalCompressorCmd/ExternalDecompressorCmd instead.") |
There was a problem hiding this comment.
For this, pflag is going to do roughly {{f.Name}} is deprecated.{{ if .Message ne "" }} {{ .Message }}{{ endif }}, so you should try this out and adjust accordingly.
There was a problem hiding this comment.
fixed it...
Flag --backup_storage_hook has been deprecated, consider using ExternalCompressorCmd/ExternalDecompressorCmd instead.
W1014 10:26:31.712856 67759 backup.go:211] checkNoDB failed, found active db vt_ks
W1014 10:26:32.067150 67759 builtinbackupengine.go:165] --backup_storage_hook is deprecated; Consider using ExternalCompressorCmd/ExternalDecompressorCmd instead.
| if backupStorageHook != "" { | ||
| log.Warning("--backup_storage_hook is deprecated; Consider using ExternalCompressorCmd/ExternalDecompressorCmd instead.") | ||
| } |
There was a problem hiding this comment.
We debated this a bit. The flag deprecation warning shows up only at tablet startup, whereas this will show up on every backup/restore, so it does have some additional value.
| return nil, err | ||
| } | ||
| if bm.TransformHook != "" { | ||
| log.Warning("--backup_storage_hook is deprecated; Consider using ExternalCompressorCmd/ExternalDecompressorCmd instead.") |
@GuptaManan100 @rsajwani please don't merge this until the deprecation wording is fixed |
…ackup-hooks Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
|
I was unable to forwardport this Pull Request to the following branches: |
* Adding deprecate message to backup hooks Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * adding markdeprecated Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fixing deprecation message Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fixing messaging Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fix flag name Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Manan Gupta <manan@planetscale.com> Co-authored-by: Manan Gupta <manan@planetscale.com>
* Adding deprecate message to backup hooks (#11491) * Adding deprecate message to backup hooks Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * adding markdeprecated Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fixing deprecation message Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fixing messaging Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fix flag name Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Manan Gupta <manan@planetscale.com> Co-authored-by: Manan Gupta <manan@planetscale.com> * fix release notes and summary Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * fixing some typos in release notes and summary Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * removing newline Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> Signed-off-by: Manan Gupta <manan@planetscale.com> Co-authored-by: Manan Gupta <manan@planetscale.com>
Signed-off-by: Rameez Sajwani rameezwazirali@hotmail.com
Description
This PR generates deprecation message for backup hooks. They are plan to be removed in v16.0
Related Issue(s)
Checklist
Deployment Notes