I am using SqlDependency
to get change notifications from SQL Server. If the SQL Server is restarted, the notifications are resumed with it, but if SQL Server is stopped and then started then it looses the dependency.
Is this the expected behavior?
If yes then how can I know if the SqlDependency
is stopped and I need to re-register the dependency. SqlNotificationInfo
doesn't provide any information regarding it.