|
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<!-- Configuration Sections In This File -->
<configSections>
<!-- NHibernate Section -->
<section
name="hibernate-configuration"
type="NHibernate.Cfg.ConfigurationSectionHandler,NHibernate"
/>
<!-- Log4Net Section -->
<section
name="log4net"
type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"
/>
</configSections>
<!-- NHibernate Configuration -->
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2">
<session-factory>
<property name="connection.provider">
NHibernate.Connection.DriverConnectionProvider
</property>
<property name="dialect">
NHibernate.Dialect.MsSql2005Dialect
</property>
<property name="connection.driver_class">
NHibernate.Driver.SqlClientDriver
</property>
<property name="connection.connection_string">
Data Source=(local)\SQLExpress;Initial Catalog=NHibernateSimpleDemo;Integrated Security=True;Pooling=False
</property>
</session-factory>
</hibernate-configuration>
<!-- Log4Net Configuration -->
<log4net>
<!-- Define an output appender (where the logs can go) -->
<appender name="LogFileAppender" type="log4net.Appender.FileAppender, log4net">
<param name="File" value="log.txt" />
<param name="AppendToFile" value="true" />
<layout type="log4net.Layout.PatternLayout, log4net">
<param name="ConversionPattern" value="%d [%t] %-5p %c [%x] <%X{auth}> - %m%n" />
</layout>
</appender>
<!-- Note: Priority level can be ALL/DEBUG/INFO/WARN/ERROR/FATAL/OFF -->
<!-- Setup the root category, set the default priority level and add the appender(s) (where the logs will go) -->
<root>
<priority value="WARN" />
<appender-ref ref="LogFileAppender" />
</root>
</log4net>
</configuration>
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
David Veeneman is a financial planner and software developer. He is the author of "The Fortune in Your Future" (McGraw-Hill 1998). His company, Foresight Systems, develops planning and financial software.