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

[ReceveryServices] Delay in long running operations #18567

Closed
VeryEarly opened this issue Jun 15, 2022 · 0 comments · Fixed by #18568
Closed

[ReceveryServices] Delay in long running operations #18567

VeryEarly opened this issue Jun 15, 2022 · 0 comments · Fixed by #18568
Assignees
Labels
bug This issue requires a change to an existing behavior in the product in order to be resolved.

Comments

@VeryEarly
Copy link
Contributor

Description

Some code changes introduced in PR: https://github.com/Azure/azure-powershell/pull/18154/files#diff-1aac40bedaa2fc2c2abbee9d763b1eb0e96c67a7817dc28d5f1212505f0803bcR48
for file src/RecoveryServices/RecoveryServices.Backup.Helpers/TrackingHelpers.cs

This change make the logic from:

to

  • if not playback mode, sleep for 5 seconds
  • if record or playback mode, sleep for another 5 seconds
    which cause test cases in playback mode timeout

From the history I have to guess what you want is to remove the redundant check for playback mode which should look like

if (String.Compare(testMode, "Record", StringComparison.OrdinalIgnoreCase) == 0)
{
    Thread.Sleep(10000);
}
else
{
  TestMockSupport.Delay(_defaultSleepForOperationTracking * 1000);
}

which is clearer:

  • if record mode, sleep for 10 seconds
  • if not test, sleep for 5 seconds

Issue script & Debug output

no debug output

Environment data

no environment data

Module versions

no module version

Error output

No response

@VeryEarly VeryEarly added bug This issue requires a change to an existing behavior in the product in order to be resolved. needs-triage This is a new issue that needs to be triaged to the appropriate team. labels Jun 15, 2022
@ghost ghost removed the needs-triage This is a new issue that needs to be triaged to the appropriate team. label Jun 15, 2022
@VeryEarly VeryEarly self-assigned this Jun 15, 2022
@VeryEarly VeryEarly added this to the July 2022 (2022-07-05) milestone Jun 15, 2022
@VeryEarly VeryEarly linked a pull request Jun 15, 2022 that will close this issue
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue requires a change to an existing behavior in the product in order to be resolved.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant