AppDynamics Application Intelligence Platform

3.8.x Documentation



Release Notes

Child pages
  • Regular Expressions In Match Conditions

AppDynamics Inc.

Skip to end of metadata
Go to start of metadata

In AppDynamics you can use regular expressions (sometimes referred to as "regex") as an extension to simple pattern matching. Regular expressions enable you to combine similar transactions, rather than having to record and identify every variation. You can use regular expressions in custom match rules, custom exit points, and other configurations.

Regular Expression Engines

The App Agent for Java uses Java libraries for regular expressions. For more information see:

The App Agent for .NET uses the built in .NET regular expressions engine: For more information, see:

The App Agent for PHP uses PHP's built-in PCRE regular expression engine and requires the same syntax, including delimiters (for example: /^Foo/). For more information, see:

Regular Expression Examples

Custom Business Transaction Rules

Online retail applications might have URLs where the useful grouping information is distributed in different segments of the URI.  One example is  In this example, a useful business transaction might be to match on “/store/jump” and “all” to group all user requests to view all of an available category. A possible regex (regular expression) for this case is:


Consider the following REST URL: /myapp/card/{cardnumber}/session. Say, you want a transaction defined where the numeric card number is irrelevant. With URL patterns such as:

  • /group/1/nodsession/
  • /group/1/nodsession
  • /group/31/nodsession/
  • /group/2/nodsession

This regular expression will match:



To group URLs that contain letters then numbers into one business transaction, such as the following:

But not match on this URL (because it has no digits after the letters)

Try the following:



Or, to handle upper case letters, the following:



If you want it to match more strictly, try this:


Backend Discovery Rules

For an example of a JDBC backend regular expression, see JDBC with complex URLs.

Regular Expression Testing Tools and Resources

You can find many regex testing pages and other resources online. - is a multi-purpose regex testing website where you can create and test regular expressions. The website supports JavaScript, PHP and other languages. - RegexPlanet is a regular expression test page for all known engines (languages): Java, JS, .NET, PHP and more.  - general purpose site with numerous resources, including quick starts, tutorials, examples, and more.

Java - a simple testing page for Java

.NET - Regexlib is a .NET engine tester that also has a library of regular expressions and a list of resources.