Defining Exception Sets and Rules

Visual Studio 2012
Hh973126.collapse(en-us,VS.110).gif Hh973126.expand(en-us,VS.110).gif Hh973126.copycode(en-us,VS.110).gif Hh973126.copycodeHighlight(en-us,VS.110).gif Hh973126.drpdown(en-us,VS.110).gif Hh973126.drpdown_orange(en-us,VS.110).gif
PreEmptive Analytics for TFS User Guide
Defining Exception Sets and Rules
www.preemptive.com

Glossary Item Box

Subscriptions define the mapping between an application instrumented with exception reporting capabilities, a team project in which to create work items based on exceptions the application experiences, and the rules that govern the creation of such work items. Subscriptions can have multiple rules, each of which define a set of conditions under which a work item will be created including criteria such as the number and type of exception reports received, and the time period in which they must be received in order to trigger the creation of a work item. These settings are configured across all provisioned projects using the Configuration Utility installed alongside the PreEmptive Analytics aggregator service, or on a per-project basis via the PreEmptive Analytics Aggregator Visualizer extension for Visual Studio.

Hh973126.hs-tip(en-us,VS.110).gifPreEmptive Analytics CE allows you to create a single subscription for each team project, and to define up to three rules for each subscription. In addition, only a single rule type (ErrorCountOverTime) is included with PreEmptive Analytics CE. PreEmptive Analytics for TFS, purchased directly from PreEmptive Solutions, contains the ability to define an unlimited number of subscriptions and rules and includes additional rule types. For more information, please visit www.preemptive.com/pa or e-mail solutions@preemptive.com.

Create exception rules

  1. Launch Visual Studio and navigate to the Team Explorer pane. Provisioned team projects will show a PreEmptive Analytics entry.
  2. Click the PreEmptive Analytics node to open the PreEmptive Analytics hub.
  3. In the Settings group, click Configure. This will launch the rule configuration window.
  4. Click on the General node in the left navigation. The Aggregator Configuration URL will be displayed. If there is an error connecting to the Aggregator Configuration service, it must be corrected before you can proceed. See the Troubleshooting the Analytics Aggregator Service topic for steps in solving issues with the aggregator service.
  5. Select the Exception Sets node in the left navigation. By default, there is a single exception set defined named AllExceptions which matches all incoming exceptions. You can create other exception sets which match one or more exception types as follows:
    1. Click the + icon to add a new, empty exception set. Provide a name for this exception set in the Name field.
    2. In the Exceptions grid, add a new row for each exception type you would like to track. Fill in the fully-qualified exception type name (such as System.Net.WebException or java.io.FileNotFoundException) in the Exception Type column, and provide a name for this exception type (typically the unqualified exception type name) in the Name column.
      Hh973126.hs-note(en-us,VS.110).gifPreEmptive Analytics does not attempt to traverse the inheritance hierarchy of reported exceptions. For example, adding a rule for System.ApplicationException will not automatically match reported exceptions that are sub-types of System.ApplicationException.
    Hh973126.hs-caution(en-us,VS.110).gifOnce you have created rules that reference this exception set, you will not be able to delete it or change the Name field without first removing all the rules that reference it.
  6. Select the Subscriptions node in the left navigation, and click the + icon to add a new, empty subscription.
  7. Provide a name for this subscription in the Name field.
  8. In the Identity group box, supply the Company and Application ID values you used when instrumenting your application to send exception reporting data. For more information on how to add and configure exception reporting in your applications, see the Adding Exception Reporting to a .NET Application topic.

  9. Leave the value of the Data Retention Days field set to the default of 30 unless you wish to change the duration for which the aggregator service will keep detailed data for each received exception.
  10. In the Team Foundation Server group box, optionally specify the area path you wish to use for the created work items in the Area Path field.
  11. In the Rules grid, you can create rules to be applied to exception reports received from the application you specified above:

    1. Choose the exception set you wish to use for this rule in the Exception Set Name dropdown. All exceptions that are included in this set can potentially trigger the execution of the rule.
    2. In the Span Minutes column, specify how far back from the current time the aggregator service should query for exception report messages. Each time the aggregator service checks for exception new exception reports, if there are sufficient exception reports to meet the threshold criteria between the time of the check and the x minutes prior, a work item will be created. The default is one day (1440 minutes).
    3. In the Threshold column, specify the threshold value you wish to use, such as the number of exceptions (of the types defined in your exception set) that must be received to trigger the creation of a work item.
  12. You can add additional subscriptions to process exception reporting data from other applications, or from the same application using a different Area Path by selecting the Subscriptions node and clicking the + icon to create additional subscriptions.

See Also

Adding Exception Reporting to a .NET Application
Adding Exception Reporting to a .NET Application

Troubleshooting
Troubleshooting the Analytics Aggregator Service

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft