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

Fix Error log bug #207

Merged
merged 2 commits into from
Oct 26, 2023
Merged

Fix Error log bug #207

merged 2 commits into from
Oct 26, 2023

Conversation

Shashank1306s
Copy link

@Shashank1306s Shashank1306s commented Oct 3, 2023

Improved error floatation during csi-polling timeout scenario.

Signed-off-by: Shashank Singh <[email protected]>
anshulahuja98
anshulahuja98 previously approved these changes Oct 3, 2023
@Shashank1306s Shashank1306s marked this pull request as draft October 3, 2023 05:33
@@ -267,7 +267,8 @@ func GetVolumeSnapshotContentForVolumeSnapshot(volSnap *snapshotv1api.VolumeSnap
if err != nil {
if err == wait.ErrWaitTimeout {
if snapshotContent.Status != nil && snapshotContent.Status.Error != nil {
log.Errorf("Timed out awaiting reconciliation of volumesnapshot, Volumesnapshotcontent %s has error: %v", snapshotContent.Name, snapshotContent.Status.Error.Message)
log.Errorf("Timed out awaiting reconciliation of volumesnapshot, Volumesnapshotcontent %s has error: %v", snapshotContent.Name, *snapshotContent.Status.Error.Message)
return nil, errors.Errorf("CSI got timed out with error: %v", *snapshotContent.Status.Error.Message)
Copy link
Collaborator

Choose a reason for hiding this comment

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

unsure about this return statement here, we return on line 276 with the original error, right ?

Copy link
Author

@Shashank1306s Shashank1306s Oct 16, 2023

Choose a reason for hiding this comment

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

Hi @shubham-pampattiwar, here in line 268 the err is compared to wait.ErrWaitTimeout which is timed out waiting for the condition

and while returning this error message is floated in the velero rather than actual error.
So, I've added this return statement for floating actual error

@Shashank1306s Shashank1306s marked this pull request as ready for review October 26, 2023 11:25
@github-actions github-actions bot requested a review from sseago October 26, 2023 11:25
@sseago sseago merged commit c108fa5 into vmware-tanzu:main Oct 26, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants