How to enable second level cache in ActiveRecord Linq?

683 views Asked by At

Second level cache can be enable using QueryOptions. But how could be enabled in Castle ActiveRecord Linq? ActiveRecordLinq class does not have such a property.

1

There are 1 answers

6
Mauricio Scheffer On BEST ANSWER

I think QueryOptions applied only for the old Linq provider (pre NH 3). With NH 3 you have to call Cacheable() on the IQueryable<T>. I'm pretty sure you can apply the same method to an IQueryable returned by ActiveRecord.