Hi All,
Just a quick question. I am using the SysCacheProvider with Query Caching turned on. This is for an ASP.Net app. If 2 or more requests come in with the same query (Press F5 a couple of times) then I get this exception (From NHibernate Logs).
2006-07-07 11:05:28,888 INFO NHibernate.Loader.Loader - [VERY LONG QUERY]
2006-07-07 11:05:28,888 INFO NHibernate.Loader.Loader - [VERY LONG QUERY]
2006-07-07 11:05:28,888 INFO NHibernate.Loader.Loader - [VERY LONG QUERY]
2006-07-07 11:05:28,888 INFO NHibernate.Loader.Loader - [VERY LONG QUERY]
2006-07-07 11:05:28,904 WARN NHibernate.Util.ADOExceptionReporter - System.ArgumentException: Item has already been added. Key in dictionary: "NHibernate-Cache:NHibernate.Cache.StandardQueryCache:sql: [VERY LONG QUERY]
at System.Collections.Hashtable.Insert(Object key, Object nvalue, Boolean add)
at System.Collections.Hashtable.Add(Object key, Object value)
at NHibernate.Caches.SysCache.SysCache.Put(Object key, Object value)
at NHibernate.Cache.StandardQueryCache.Put(QueryKey key, IType[] returnTypes, IList result, ISessionImplementor session)
at NHibernate.Loader.Loader.List(ISessionImplementor session, QueryParameters queryParameters, ISet querySpaces, IType[] resultTypes)
at NHibernate.Loader.CriteriaLoader.List(ISessionImplementor session)
at NHibernate.Impl.SessionImpl.Find(CriteriaImpl criteria)
2006-07-07 11:05:28,904 INFO NHibernate.Loader.Loader - [VERY LONG QUERY]
2006-07-07 11:05:28,904 ERROR NHibernate.Util.ADOExceptionReporter - Item has already been added. Key in dictionary: "NHibernate-Cache:NHibernate.Cache.StandardQueryCache:sql: [VERY LONG QUERY]
Is there any information available on this? Is this a bug? Is Query Caching stable? Do I have to implement my own locking on top of
NHibernate (if using cache)? That seems like an inefficient solution.
Cheers
Guido Tapia
Hibernate version: 1.0.2
Name and version of the database you are using:SQL Server 2000
|