Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 8072: restic deprecation - warning messages #8096

Merged
merged 1 commit into from
Aug 12, 2024

Conversation

Lyndon-Li
Copy link
Contributor

@Lyndon-Li Lyndon-Li commented Aug 8, 2024

Fix issue #8072, add the warning messages for restic deprecation

Copy link

codecov bot commented Aug 8, 2024

Codecov Report

Attention: Patch coverage is 78.26087% with 5 lines in your changes missing coverage. Please review.

Project coverage is 58.77%. Comparing base (2645948) to head (fefb4b8).
Report is 5 commits behind head on main.

Files Patch % Lines
pkg/cmd/cli/install/install.go 0.00% 3 Missing ⚠️
pkg/podvolume/backupper.go 83.33% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8096      +/-   ##
==========================================
- Coverage   58.78%   58.77%   -0.01%     
==========================================
  Files         358      358              
  Lines       30079    30084       +5     
==========================================
+ Hits        17681    17682       +1     
- Misses      10950    10954       +4     
  Partials     1448     1448              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Lyndon-Li
Copy link
Contributor Author

Lyndon-Li commented Aug 8, 2024

With this PR, users will see below warnings when --uploader-type=restic is specified during installation:
In the output of installation:
⚠️ Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero

In Velero server log:
level=warning msg="Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero

In the output of velero backup describe for a backup with fs-backup:

  Namespaces:
    <namespace>:   resource: /pods name: <pod name> message: /Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero

And users will see below warnings when upgrading from v1.9 or lower:
In Velero server log:
level=warning msg="Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero

In the output of velero backup describe for a backup with fs-backup:

  Namespaces:
    <namespace>:   resource: /pods name: <pod name> message: /Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero

@Lyndon-Li Lyndon-Li changed the title issue 8072: restic deprecation - warning messages Issue 8072: restic deprecation - warning messages Aug 8, 2024
@Lyndon-Li Lyndon-Li marked this pull request as ready for review August 8, 2024 08:20
return nil

if t == ResticType {
return fmt.Sprintf("Uploader '%s' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero", t), nil
Copy link
Contributor

Choose a reason for hiding this comment

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

@sseago any feedback for the wording?

Copy link
Collaborator

Choose a reason for hiding this comment

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

@reasonerjt I'd replace "otherwise, the backed up data may not be accessed by new versions of Velero" with "otherwise this backup won't be available for restore when this functionality is removed in a future version of Velero"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done, thanks for the suggestion @sseago

@Lyndon-Li
Copy link
Contributor Author

Lyndon-Li commented Aug 8, 2024

@sseago @shubham-pampattiwar Please help to review this PR and let me know how you feel about the warning messages.

For 1.15 and 1.16, you will see below warnings if `--uploader-type=restic` is used in Velero installation:
In the output of installation:
```
⚠️ Uploader 'restic' is deprecated, don't use it for new backups, otherwise, the backed up data may not be accessed by new versions of Velero
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please update the warning message in docs as well.
Ref: #8096 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

Copy link
Collaborator

@shubham-pampattiwar shubham-pampattiwar left a comment

Choose a reason for hiding this comment

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

Update warning text in the docs

Copy link
Collaborator

@shubham-pampattiwar shubham-pampattiwar left a comment

Choose a reason for hiding this comment

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

/lgtm

Defaulted container "velero" out of: velero, openshift-velero-plugin (init), velero-plugin-for-aws (init)                            
time="2024-08-09T20:28:35Z" level=info msg="setting log-level to INFO" logSource="pkg/cmd/server/server.go:199"                      
time="2024-08-09T20:28:35Z" level=info msg="Starting Velero server restic-warn (fefb4b858c796630428fb204a60b051f53fb1de6)" logSource=
"pkg/cmd/server/server.go:201"                                                                                                       
time="2024-08-09T20:28:35Z" level=info msg="1 feature flags enabled [EnableCSI]" logSource="pkg/cmd/server/server.go:203"            
time="2024-08-09T20:28:35Z" level=warning msg="Uploader 'restic' is deprecated, don't use it for new backups, otherwise the backups w
on't be available for restore when this functionality is removed in a future version of Velero" logSource="pkg/cmd/server/server.go:2
94"

@reasonerjt reasonerjt merged commit 260a499 into vmware-tanzu:main Aug 12, 2024
45 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