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

[3.1.0] | Add serverless paused and warming up errors to transient error lists #1560

Merged
merged 3 commits into from
Mar 28, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,13 @@ internal bool IsDNSCachingBeforeRedirectSupported

// Database '%.*ls' on server '%.*ls' is not currently available. Please retry the connection later.
// If the problem persists, contact customer support, and provide them the session tracing ID of '%.*ls'.
40613
40613,

// Can not connect to the SQL pool since it is paused. Please resume the SQL pool and try again.
42108,

// The SQL pool is warming up. Please try again.
42109
};

internal SessionData CurrentSessionData
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,7 @@ internal SqlInternalConnectionTds(
SqlClientEventSource.Log.TryAdvancedTraceEvent("<sc.SqlInternalConnectionTds.ctor|ADV> {0}, constructed new TDS internal connection", ObjectID);
}

// The erros in the transient error set are contained in
// The errors in the transient error set are contained in
// https://azure.microsoft.com/en-us/documentation/articles/sql-database-develop-error-messages/#transient-faults-connection-loss-and-other-temporary-errors
private static void populateTransientErrors()
{
Expand Down Expand Up @@ -614,6 +614,10 @@ private static void populateTransientErrors()
// Database '%.*ls' on server '%.*ls' is not currently available. Please retry the connection later.
// If the problem persists, contact customer support, and provide them the session tracing ID of '%.*ls'.
transientErrors.Add(40613);
// Can not connect to the SQL pool since it is paused. Please resume the SQL pool and try again.
transientErrors.Add(42108);
// The SQL pool is warming up. Please try again.
transientErrors.Add(42109);
// Do federation errors deserve to be here ?
// Note: Federation errors 10053 and 10054 might also deserve inclusion in your retry logic.
//transientErrors.Add(10053);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ private static readonly HashSet<int> s_defaultTransientErrors
40501, // The service is currently busy. Retry the request after 10 seconds. Incident ID: %ls. Code: %d.
40540, // The service has encountered an error processing your request. Please try again.
40197, // The service has encountered an error processing your request. Please try again. Error code %d.
42108, // Can not connect to the SQL pool since it is paused. Please resume the SQL pool and try again.
42109, // The SQL pool is warming up. Please try again.
10929, // Resource ID: %d. The %s minimum guarantee is %d, maximum limit is %d and the current usage for the database is %d. However, the server is currently too busy to support requests greater than %d for this database. For more information, see http://go.microsoft.com/fwlink/?LinkId=267637. Otherwise, please try again later.
10928, // Resource ID: %d. The %s limit for the database is %d and has been reached. For more information, see http://go.microsoft.com/fwlink/?LinkId=267637.
10060, // An error has occurred while establishing a connection to the server. When connecting to SQL Server, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: TCP Provider, error: 0 - A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.) (Microsoft SQL Server, Error: 10060)
Expand Down