Take the above
IsLine.ExceptionProcess.ExceptionProcessProvider namespaces:
System logs and system exceptions are recorded separately, ILFW system logs and exceptions are processed to improve system flexibility and security. Exceptionprocessprovider is the main component that an application needs to interact with, and it is used to produce an exception message, the resulting exception message is not directly displayed, and it is not output until the layout is formatted.
Overview:
The exception module attached to the IsLine.AppLog.AppLogProvider part, while the exception module design as a special system log to treat, so use the exception module first to configure the Applog module, the specific method see Aicken related articles.
After configuring the log module, you need to introduce namespaces:
Using IsLine.ExceptionProcess.ExceptionProcessProvider;
and use the "Add" tab in Web.config to add a exception pointer:
<add key= "IsLine.ExceptionProcess.Configuration.RenderName" value= "Oracleusingsprender"/>
The function of this pointer is to tell the exception module to use the renderer, the name of the renderer is value, the module load, will automatically load the Isline.applog namespace under the "Renderer initialization" module, after the initialization of the renderer, The specific exception object will be loaded.
This configuration process is described as follows, if we need to put the exception information into the Oracle database, later found that the exception is not so important, just a text file can be written, then we need to modify the Web.config file.
1. Add the following nodes between <configSections></configSections>
Code
<sectionGroup name="IsLine.AppLog.Configuration">
<section name="FileRender" type="IsLine.Data.Configuration.SuitConfig"/>
<section name="OracleUsingSPRender" type="IsLine.Data.Configuration.SuitConfig"/>
</sectionGroup>
2. Add the following nodes between </configSections><appSettings>
Code
<isline.applog.configuration>
<filerender>
<appenderstyle>file</appender Style>
<appendertype>text</appendertype>
<appenderinf>islinelog/log4net1.txt< ;/appenderinf>
<AppenderContent>-> Event Date: @eventDate;-> Level: @level;-> Message: @exception;-> Source: @source;-> Stack Trace: @StackTrace-> Trigger: @trigger;-> Memo: @message </appendercontent>
<layoutinf></layoutinf>
<level>debug</lev El>
</filerender>
<oracleusingsprender>
<appenderstyle>oracle</append Erstyle>
<appendertype>storedprocedure</appendertype>
<appenderinf>isline.data. Configuration.oracleconnectstring</appenderinf>
<appendercontent>sp_add_ilfwlog. Add_ilfwlog</appendercontent>
<layoutinf> </layoutinf>
<level>debug</level>
</oracleusingsprender>
</IsLine.AppL og. Configuration>