File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
src/IntelliTect.AspNetCore.SignalR.SqlServer/Internal/SqlServer Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -363,6 +363,16 @@ private bool StartSqlDependencyListener()
363363 _notificationsDisabled = true ;
364364 return false ;
365365 }
366+ catch ( SqlException ex ) when ( ex . Number == 40510 || ex . Message . Contains ( "not supported" ) )
367+ {
368+ // Workaround for https://github.com/dotnet/SqlClient/issues/1264.
369+ // Specifically that Azure SQL Database reports that service broker is enabled,
370+ // even though it is entirely unsupported.
371+
372+ _logger . LogInformation ( "{0}SQL Service Broker is unsupported by the target database. Falling back on periodic polling." , _tracePrefix ) ;
373+ _notificationsDisabled = true ;
374+ return false ;
375+ }
366376 catch ( Exception ex )
367377 {
368378 _logger . LogError ( ex , "{0}Error starting SQL notification listener" , _tracePrefix ) ;
You can’t perform that action at this time.
0 commit comments