Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The default behavior of the Exception Manager is to publish exceptions to the Windows Event Log, however, Aptify also provides the ability to write the log exceptions to a file within the Aptify database. In addition, Aptify also includes publishers that can write to a database or send an SMTP message and it is possible to create new publishers as a plug-in. Aptify 5.5.4 adds the ability to enable a database publisher. Enabling the database publisher sends exceptions logged in the database to the Error Log entity, and saved as Error Log records , so that the Viewing System and Entity Form Template Aptify viewing system and entity form template functionality can be used to find and view these exceptions.

Note

When only the database publisher is enabled in Aptify, exceptions are no longer sent to the Windows Event Log. It is possible to enable both publishers , so that exceptions are sent to the Windows Event Log and to Error Log records.

...

  1. Log in to Aptify using the default login dialog if you have not previously logged in as this user.
    • When a user connects to Aptify from a computer running the Aptify Desktop client for the first time, the client downloads new copies of all of the relevant Object Repository Objects, including including Startup.exe.config and  and Aptify Shell.exe.config.
    • You can also capture exceptions from an Aptify application server by modifying the AptifyAsyncProcessor.exe.config file on the Application server.
    • You can also log exceptions capture from Aptify web by modifying the site's web.config file. 

  2. Locate the the Startup.exe.config or  and Aptify Shell.exe.config config file on your client computer (typically located in in C:\Program Files\Aptify 5.0 or 5.5).
  3.  Right-click the file and select select Properties from  from the pop-up menu to open the Windows Properties dialog for this file.
  4.  If necessary, clear the the Read-only check box in the Attributes section.
    •  The config files may be read-only by default.
  5.  Click Click OK to  to close the file’s Properties dialog.
  6. Open the 'Startup.exe.config or ' and 'Aptify Shell.exe.config using ' using a text editor, such as Notepad or Notepad++.
  7.  Uncomment the the publisher mode attribute  attribute from within the exceptionManagement section by removing the <!-- from before and the --> from the end. The line is below:

    No Format
    nopaneltrue
    <publisher mode="on" days="3"  exceptionformat="xml" directory="c:\" assembly="AptifyExceptionManagement" type="Aptify.Framework.ExceptionManagement.XMLFilePublisher"/>

     

    • If the line does not exist, add it between the exceptionManagement tags.

    • When no publishers are defined in the exceptionManagement section, the default publisher is used. The default publisher is the Event Log publisher.
       

  8.  Configure the settings to fit your organization’s needs.

    • publisher mode: Values are  Values are On or  or Off. When set to to On, exceptions are published to that publisher. When set to to Off, exceptions are not published to the publisher.
    • days: The  The length of time that exceptions are logged before a new file is created.
    • exceptionformat: The  The format of the exception file.Values are are xml or  or exception. The supported format for the default publisher is is xml.
    • directory: The  The location where the file should be logged. Note that all users must have access to the file and file location.
    • assembly: The  The assembly for this publisher. The default value is is AptifyException. However an , a developer can create a plug-in based on an organization’s needs. 

    • type: The  The publisher type. The default value is is Aptify.Framework.ExceptionManagement.XMLFilePublisher. Aptify 5.5.4 adds support for a database publisher that sends database exceptions to a new entity, Error Log. The type for the database publisher is Aptify.Framework.ExceptionManagement.DatabasePublisher.

      For example, to enable the database publisher, you would enter something similar to the following:

      No Format
      nopaneltrue
      <exceptionManagement mode="on" defaultseverity="0" legacytextformat="true">
          <publisher mode="on" assembly="AptifyExceptionManagement" type="Aptify.Framework.ExceptionManagement.DatabasePublisher"/>
      </exceptionManagement>

       

      In this example, both the default Error Log publisher and the database publisher are enabled:

      No Format
      nopaneltrue
      <exceptionManagement mode="on" defaultseverity="0">
          <publisher mode="on" assembly="AptifyExceptionManagement" type="Aptify.Framework.ExceptionManagement.DatabasePublisher"/>
          <publisher mode="on" assembly="AptifyExceptionManagement" type="Aptify.Framework.ExceptionManagement.EventLogPublisher"/>
      </exceptionManagement>



  9. Save the Startup.exe.config or  and Aptify Shell.exe.config file (or web.config for Aptify web or AptifyAsyncProcessor.exe.config file on the Application server).

 

Note

When the database publisher is enabled, it is possible that a great number of Error Log records could be created. Aptify recommends that when the database publisher is enabled, that archive runs be set up for the Error Log records. See the "Archive Runs" section of the Administration Services chapter of the Aptify 5.5.1 Administration Guide for more information.

 

 

...

all exceptions are logged to Error Log records (unless you have it configured to log to both Aptify and the Windows Event Log). This can result in a large number of records which you may find you want to archive or delete over time. There is not currently an archive run type to support archiving. This is a feature we are considering for future releases. Please contact Aptify if you are interested in this feature. See Archiving Transactional Data for more information.

Aptify 5.5.5 adds a stored procedure database object, spDeleteERRORLOGRecordBefore, to the Error Log entity to enable the deletion of all Error Log records created before a date specified in a parameter, @BeforeDate.