In case anyone cares, I've narrowed the problem down to a call within the
PermissionService to
* GetGlobalPermissionsFor(IUser user, string operationName)*
For some reason (probably something on my end), the code
*Expression.Eq("User", user) *
**is causing the query to not get cached. I'm
using NHibernate.Caches.SysCache if that makes any difference.
I've extracted the querying part to my own app and pass in my own User
object which has a long Id property that is not part of the IUser interface
and instead restrict the query using this expression:
*Expression.Eq("User.Id", user.Id)*
*
*
The resulting SQL that is generated is exactly the same with each
restriction. However, the latter query gets cached.
I'm guessing this is an issue more to do with some misunderstanding I have
with SysCache instead of Rhino Security, but in case anyone else has come
across a similar issue, I hope this helps. I will probably dig into the
source of SysCache next to see what is causing my first attempt to not get
cached correctly.
Thanks.
--
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.