<object id="SessionFactory" type="Spring.Data.NHibernate.LocalSessionFactoryObject, Spring.Data.NHibernate21" singleton="true">
<property name="DbProvider" ref="DbProvider" />
<property name="MappingAssemblies">
<list>
<value>XXX.BusinessDomain</value>
</list>
</property>
<property name="HibernateProperties">
<dictionary>
<entry key="hibernate.connection.provider" value="NHibernate.Connection.DriverConnectionProvider"/>
<entry key="hibernate.connection.driver_class" value="NHibernate.Driver.MySqlDataDriver"/>
<entry key="hibernate.dialect" value="NHibernate.Dialect.MySQLDialect"/>
<entry key="hbm2ddl.keywords" value="none"/>
<entry key="proxyfactory.factory_class" value="NHibernate.ByteCode.Castle.ProxyFactoryFactory, NHibernate.ByteCode.Castle"/>
<entry key="hibernate.cache.provider_class" value="NHibernate.Caches.SysCache.SysCacheProvider,NHibernate.Caches.SysCache" />
<entry key="cache.use_second_level_cache" value="true" />
<entry key="expiration" value="300" /> <!-- five minutes, at the minute -->
</dictionary>
</property>
<property name="ExposeTransactionAwareSessionFactory" value="true" />
</object>
</configSections>
...
<section name="syscache" type="NHibernate.Caches.SysCache.SysCacheSectionHandler, NHibernate.Caches.SysCache" requirePermission="false" />
</configSections>
<syscache>
<cache region="entities" expiration="3600" priority="5" />
<cache region="LongTerm" expiration="3600" priority="5" /> <!-- as a reference -->
<cache region="ShortTerm" expiration="900" priority="3" /> <!-- as a reference -->
</syscache>
<class name="XXX">
<cache usage="nonstrict-read-write" region="entities" />
SysCache2 requires Microsoft SQL Server 2000 or higher and .NET Framework version 2.0 or higher.