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

Why Unknown error 258 is not in SqlServerRetryingExecutionStrategy retryable error numbers. #34154

Closed
malylemireflo opened this issue Jul 3, 2024 · 1 comment

Comments

@malylemireflo
Copy link

Ask a question

I sometimes get this error when dtu are maxed out on azure hosted sql server database.

Microsoft.Data.SqlClient.SqlException: Execution Timeout Expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
Operation cancelled by user.
---> System.ComponentModel.Win32Exception: Unknown error 258

Why won't the SqlServerRetryingExecutionStrategy retry this by default?

EF Core version: 8.0.0.0
Database provider: Microsoft.EntityFrameworkCore.SqlServer
Target framework: NET 8.0
Operating system: Ubuntu
IDE: Visual Studio 2022 17.4

@malylemireflo malylemireflo changed the title Why Unknown error 258 is not in SqlServerRetryingExecutionStrategy retryable error number. Why Unknown error 258 is not in SqlServerRetryingExecutionStrategy retryable error numbers. Jul 3, 2024
@AndriySvyryd
Copy link
Member

That error can have a variety of causes, see dotnet/SqlClient#1530
It's not an expected transient error and thus EF won't retry it by default, you can add it in the EnableRetryOnFailure call if you consider it to be safe to retry for your scenarios.

@AndriySvyryd AndriySvyryd closed this as not planned Won't fix, can't repro, duplicate, stale Jul 12, 2024
@AndriySvyryd AndriySvyryd removed their assignment Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants