Chat Support
Loupe - Log - Monitor - Resolve
Loupe / Developer's Guide / For .NET Framework / For ASP.NET MVC / Agent Configuration / Through the Web.Config file / Developer's Guide - Session File Configuration
In This Topic
    Developer's Guide - Session File Configuration
    In This Topic

    The sessionFile configuration section adjusts how session files are managed.  The session file is the persistent on-disk record of the session.  If disabled, no session file will be recorded which means that there will be no data to package or access with the Loupe Desktop.

    Configuration Type Path
    App.Config File (xml) gibraltar.sessionFile
    Environment Variable Prefix Loupe__SessionFile
    Option Description Default Value Required
    enabled When true, Loupe data will be recorded to a local file where it can then be packaged for analysis on another computer or locally with the Loupe Desktop. true false
    folder

    The folder to store session files in instead of using the local collection repository. 

    If null or empty, files will be stored in a central data folder which is the preferred setting.

    "" false
    autoFlushInterval

    The maximum number of seconds data can be held in memory before it is flushed to disk. 

    In addition to the automatic flush due to the amount of information waiting to be written out the messenger will automatically flush to disk based on the number of seconds specified.

    15 false
    indexUpdateInterval

    The number of seconds between index updates. 

    An index is maintained of session information including the number and types of messages and session status.  It is updated automatically when a session is stopped and in certain other cases.  This setting will control how often updates are published outside of these cases.

    15 false
    maxFileSize

    The maximum number of megabytes in a single file before a new file is started.

    When the file reaches the maximum size it will be closed and a new file started. Due to compression effects and other data storage considerations, final files may end up slightly larger on disk or somewhat smaller.  Setting to zero will allow files to grow to the maximum size allowed by the file format (1 GB) or the maxLocalDiskUsage, whichever is less.

    Once a file is closed it will be sent to the server if autoSendSessions is enabled.

    20 false
    maxFileDuration

    The maximum number of minutes in a single file before a new file is started.

    When the file reaches the maximum age it will be closed and a new file started.  Setting to zero will allow the file to cover an unlimited period of time.

    Once a file is closed it will be sent to the server if autoSendSessions is enabled.

    1440 false
    enableFilePruning

    When true, files will be pruned for size or age.

    By default, files older than a specified number of days are automatically deleted and the oldest files are removed when the total storage of all files for the application exceeds a set value.  Setting this option to false will disable all pruning.

    true false
    maxLocalDiskUsage

    The maximum number of megabytes for all files for the current application on the local drive before older files are purged.

    When the maximum local disk usage is approached, files are purged by selecting the oldest files first.  This limit may be exceeded temporarily by the maximum file size because the active file will not be purged.  Size is specified in megabytes.  Files are purged first by looking for the oldest sessions and then the oldest file fragments for an active session if necessary.

    150 false
    maxLocalFileAge

    The maximum number of days that session files for the current application are retained.

    Session files that were closed longer than the retention interval ago will be removed regardless of space constraints. 

    90 false
    minimumFreeDisk

    The minimum amount of free disk space in megabytes on the session destination drive for any logging to be performed.

    If the amount of free disk space falls below this value, existing session files will be removed to free space.  If no more session files are available, recording will stop until adequate space is available.  Size is specified in megabytes.

    50 false
    forceSynchronous

    When true, all writes will be performed synchronously.  This will ensure they are committed to disk before the next message is processed.

    This can affect the degree of parallelism of a multithreaded application and throughput, so is generally only set in cases when the application is crashing during startup or other hard to catch scenarios.

    false false
    maxQueueLength

    The maximum number of queued messages waiting to be written to disk.

    Once the total number of messages waiting to be written exceeds the maximum queue length the log writer will switch to a synchronous mode to catch up.  This will not cause the application to experience synchronous logging behavior unless the publisher queue is also filled.

    2000 false

    Example

    Session File Configuration
    Copy Code
    <configuration>
      <configSections>
        <sectionGroup name="gibraltar">
          <section name="sessionFile" type="Gibraltar.Agent.SessionFileElement, Gibraltar.Agent" />
        </sectionGroup>
      </configSections>
      <gibraltar>
        <sessionFile maxLocalFileAge="28" maxFileDuration="240" maxFileSize="5" />
      </gibraltar>
    </configuration>
    

     

    Environment Configuration
    Copy Code
    Loupe__SessionFile__MaxLocalFileAge=28
    Loupe__SessionFile__MaxFileDuration=240
    Loupe__SessionFile__MaxFileSize=5
    

    For more information on how these parameters work together to control session file pruning see Developer's Guide - Session File Pruning.

    See Also