Jump to: navigation, search

Difference between revisions of "HowTo:Configure Logging"


(Created page with "Logging in {{UBIK}} can be configured for the Web Service as well as for the UBIK.Studio. The logging for the Web Service can be configured via editing the [[UBIK_Web_Service...")
 
 
(52 intermediate revisions by 4 users not shown)
Line 1: Line 1:
Logging in {{UBIK}} can be configured for the Web Service as well as for the UBIK.Studio.
+
== Configure Logging for Version 3.5 or earlier ==
 +
By default, logging is switched on using default setttings, for example for the destination path of the logging files. See [[Configuration_Files/Logging.config|Logging.config]] for an example of a configuration file for logging.
 +
 
 +
=== Switch off logging  ===
 +
Turning off logging can be done by setting the '''switchValue''' in the Category Source to '''Off''' in the corresponding config files:
 +
* '''UBIK.Studio.exe.config''' for {{UBIK Studio}}
 +
* '''Web.config''' for the webservice
  
The logging for the Web Service can be configured via editing the [[UBIK_Web_Service_Configuration|Web Service Configuration]] in section [[UBIK_Web_Service_Configuration_Example#loggingConfiguration|loggingConfiguration]]:
 
<ol>
 
<li>Open [[UBIK_Studio_Basics|UBIK Studio]] and connect to the database which should be configured for LAS.</li>
 
<li>Open [[UBIK_Studio_Basics#Database_specific_settings|database specific settings]] and set</li>
 
{| class="wikitable" | width = "50%"
 
|-
 
! Parameter!! Value!! Comment
 
|-
 
| ''SessionManagementType''|| '''1''' || 0 = Local Management, 1 = LAS, 2 = GAS
 
|-
 
| ''SessionServiceUrl''|| https://SERVERNAME/UBIK/USAM.svc/SOAP?? || Address of the authentication service
 
|}
 
</ol>
 
<ol start="3">
 
<li>Open the [[UBIK Web Service Configuration|web.config]] of the data service and set the session's management type and URL to the according address of the web service.</li>
 
 
<source lang="xml">
 
<source lang="xml">
  <appSettings>
+
<loggingConfiguration name="" tracingEnabled="true" defaultCategory="ASSERTION">
    ...
+
...
    <add key="UBIK.Service.SessionManagementType" value="1" />
+
  <categorySources>
    <add key="UBIK.Service.SessionManagementUrl" value="https://SERVERNAME/UBIK/USAM.svc/SOAP" />
+
    ...
    ...
+
    <add switchValue="Off" name="ASSERTION">
  </appSettings>
+
        <listeners>
 +
          <add name="log.assertion"/>
 +
        </listeners>
 +
    </add>
 +
  ...
 +
  </categorySources>
 +
...
 +
</loggingConfiguration>
 
</source>
 
</source>
<li> If the authentication service is in a different location, open the [[UBIK Web Service Configuration|web.config]] of the USAM service:<br/>
 
* the settings in the configuration file are the same as in the data service
 
* however, the settings for the SessionManagementType and the SessionManagementUrl will be ignored
 
</li>
 
</ol>
 
{{Attention|It is important that the authentication service connects to the same database as the data service!}}
 
  
[[Category:How-To]]
+
[[File:UI_Configure _Logging_EntLibConfig.png|220px|thumb|border|alt=Configure logging|Configure logging]]
 +
Instead of editing the config files, it is also possible to use the graphical configuration tool from the [http://www.microsoft.com/en-us/download/details.aspx?id=15104 Enterprise Library]. After installing the package open the config file with the tool and switch on or off logging for each category as shown.
 +
{{Clear}}
 +
 
 +
==See also==
 +
* [[Logging]]
 +
* [[Configuration_Files]]
 +
* [[Web_Service_Configuration|Web service configuration]]
 +
* [[Activity:WriteLogEntry_(Activity)|WriteLogEntry (Activity)]]
 +
* [[Serilog]]
 +
{{Category/Version|3.5.0}}
 +
 
 +
[[Category:3.5.0|Configure Logging]]
 +
[[Category:How-To|Configure Logging]]
 +
[[Category:Installing|Configure Logging]]
 +
[[Category:Server|Configure Logging]]

Latest revision as of 11:23, 24 November 2020

Configure Logging for Version 3.5 or earlier

By default, logging is switched on using default setttings, for example for the destination path of the logging files. See Logging.config for an example of a configuration file for logging.

Switch off logging

Turning off logging can be done by setting the switchValue in the Category Source to Off in the corresponding config files:

  • UBIK.Studio.exe.config for UBIK® Studio
  • Web.config for the webservice
<loggingConfiguration name="" tracingEnabled="true" defaultCategory="ASSERTION">
...
   <categorySources>
     ...
     <add switchValue="Off" name="ASSERTION">
        <listeners>
           <add name="log.assertion"/>
        </listeners>
     </add>
   ...
   </categorySources>
...
</loggingConfiguration>
Configure logging
Configure logging

Instead of editing the config files, it is also possible to use the graphical configuration tool from the Enterprise Library. After installing the package open the config file with the tool and switch on or off logging for each category as shown.

See also