guyl
guyl

Reputation: 2242

Renew ISession of nhibernate after db has fallen.

we are testing cases when the database has fallen and restarted, when using the ISession one more time we get an exception. is there a way to renew the session ? or better way, get some event through NHibernate that the db has shutdown ?

Upvotes: 0

Views: 60

Answers (1)

Anton Gogolev
Anton Gogolev

Reputation: 115799

ISessions must be disposed of when any database-related exception occurs, so you shouldn't actually try to renew it.

Upvotes: 3

Related Questions