Just the fact it works nice on .NET and not on mono suggests it's mono-related thing.
However, how do you manage the session, where / how do you create it / dispose it ? For example, you mihgt have it as static property, or Application/Cache variable, or maybe create it in every operation, or create it for every page (either in global.asax Request_Begin method or custom module) ? Also, do you use session binding / current session features in session factory? (if you don't know what it is, then you don't). Assuming you are doing the session-per-request style (the recommended), is there any way you can have a place to write code just after this specific exception happens (in global asax application error method or whatever) and re-create the session factory after it happens? Also, if using session binding then trying not to use that (not that it has anything to do with it, just removing one piece of the lego) *Mohamed Meligy *Readify | Senior Developer M:+61 451 835006 | W: readify.net [image: Description: Description: Description: Description: rss_16]<http://gurustop.net> [image: Description: Description: Description: Description: cid:[email protected]] <http://www.linkedin.com/in/meligy> [image: Description: Description: Description: Description: cid:[email protected]] <http://twitter.com/meligy> <http://www.greatplacetowork.com.au/best/best-companies-australia.php><http://www.readify.net/AboutUs/NewsItem.aspx?id=10> On Sat, Apr 30, 2011 at 6:28 PM, Josef Semmler <[email protected]>wrote: > Hi, > > i have a strange issue, maybe someone can help: > > I have a web application running on mono, using NHibernate to connect > to a SQL Server 2005 database. > > The problem is, that some request to the web app take too long and > therefore either the client disconnects > unexpectetly - or the webserver disconnects (time out) ... this causes > very often a ThreadAbortException. > After such a TheadAbortException is thrown it is very likely that > NHibernate starts to "freak out" ... i see a lot of "Array index out > of range" - related to queries usually work perfectly. It also > happens, that sql sessions "merge" - which means, it seems as if the > results requested by thread "a" somehow are read by thread "b" - > although they do not share a ISession object. > > Only a complete restart of the web application (webserver) stopps this > behavior and restores normal operation. > > Funny enough, wenn using microsoft .net these ThreadAbortException > seem to not cause such issues - so i'm unsure if this is a mono > problem or a NHibernate problem ... or how to resolve this problem at > all. > > Any thoughts highly welcome! > JS > > -- > You received this message because you are subscribed to the Google Groups > "nhusers" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/nhusers?hl=en. > > -- You received this message because you are subscribed to the Google Groups "nhusers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/nhusers?hl=en.
