Ruleset: Design insights consist of a structure that groups them into logical sets. So called rulesets. Rulesets help identify the sort of insights and give you ways to navigate the findings as rulesets show up in the catalog column sets and on the Design Insights page.

Insight: Each ruleset contains one or more insights. Each Insight can consist of either a single search pattern or one or many blocks of advanced patterns. All patterns inside one block have an 'OR' relationship to each other. Meaning that if any of the patterns in that block is matched the result of that block results in a TRUE value for the database that pattern was found in. If an insight has multiple blocks the relationship between the blocks of patterns is that of an 'AND' relation. Meaning that if all blocks result in a TRUE value the insight returns a value of TRUE and the database is listed as having that design insight.

Pattern: A pattern is a search string that is fired on the collective set of database designs and returns any code elements that match the search string. The format of a pattern can be in either plain text or in the form of a regex expression*.


Keep in mind that newly added patterns, insights and rulesets will not be evaluated until the next evening run which typically starts at 18:30 (depending on your ApplicationInsights server's locale). Please allow for at least one night for results to show up.


In this topic:


Creating a Pattern

To create a design pattern, you first need to have the search string or regular expression you want to test for. You can use the Code Search to build and test a pattern and check whether it returns the results you would expect. 

Watch our Code Insights Masterclass (Video) video to learn many details about Code Search.


After knowing what pattern to search for open the Custom Insights – Manage view and switch to the "Patterns" tab in the left column. All patterns are listed here.

To create a new one:



Instead of creating a new one you can also duplicate an existing pattern by using the duplicate option behind the existing patterns name. This will create a copy that you can then edit to extend or change.


The new pattern will show in the list of patterns as unassigned (broken link icon) until it is assigned to an Insight.


Creating an Insight

To create a new insight, switch to the Insights tab on the left side of the Manage page and follow the following steps:



Alternatively, you can also copy an insight by clicking the copy option behind the name. This will create a copy of the insight and copies of all the patterns in it. After copying you can then alter the new insight to add or remove patterns and change the name.

As this copy action will also create new copies of all patterns included in the copied insight it is wise to really think through what is needed. Creating loads of copies of existing patterns might be confusing to manage and it might be better to create a new insight and reuse the existing patterns in combination with your new ones.


Adding system patterns (marked by the panagenda icon) into a custom insight will always result in copies of those system insights being made. It is not possible to add a system pattern directly to a custom insight.


Creating a Ruleset

To create a new ruleset go to the ruleset tab



Next Topic:

Reusing existing and panagenda rulesets, insights & patterns



* A regular expression is a special text string for describing a search pattern. More information about Regex can be found on the internet