Versions Compared


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


The .NET Agent requires special syntax for getter chains for HTTP Requests.

 For ASP.NET WebForms, MVC, and MVC WebAPI applications, create getter chains based upon the System.Web.HttpRequest objects.

For ASP.NET Core on the full framework, create getter chains based upon Microsoft.AspNetCore.Http.Internal.DefaultHttpRequest objects.


If you have both ASP.NET and ASP.NET Core on the full framework apps in the same tier, you cannot use a getter chain to apply to both because they use different objects to handle HTTP requests.

  • Use the following syntax to delineate the boundaries of the getter chain:

    No Format
  • The following example determines the user principal:

    No Format

For ASP.NET Core on the full framework, you need to use the <TBD> object

Places to use this syntax include:

  • HTTP Request Data Collectors
  • ASP.NET Transaction Detection custom expressions

Java Notes and Examples

The following sections apply to getter chains used in Java Agent configurations.

Values Passed in a Getter Chain

The value passed in a getter chain is always a string unless cast to another type.  

The following cast types are supported:

  • int
  • float
  • bool (the primitive Boolean value)
  • boolean (a boxed boolean value; i.e. an object type that wraps a boolean)
  • long
  • object

The following section shows examples of how to refer to the types in parameters to getter chain methods. Notice that letter case is not important for the names of the types. Type casing is performed in a case-insensitive manner.

Java Getter Chain Examples

  • Getter chain with integer parameters in the substring method using the forward slash as the type separator:

    No Format
    getAddress(appdynamics, sf).substring(int/0, int/10)
  • Getter chain with various non-string parameter types:

    No Format
    getAddress(appdynamics, sf).myMethod(float/0.2, boolean/true, boolean/false, int/5)
  • Getter chain with forward slash escaped; escape character needed here for the string parameter:

    No Format
    getUrl().split(\/) # node slash is escaped by a backward slash
  • Getter chain with an array element:

    No Format
  • Getter chains that return Hashmap values:

    No Format
  • Getter chain with multiple array elements separated by commas:

    No Format
  • Getter chain retrieves property values, such as the length of an array:

    No Format
  • Getter chain using backslash to escape the dot in the string parameter;
    the call is getParam (a.b.c).

    No Format
  • In the following getter chain, the first dot requires an escape character because it is in a string method parameter (inside the parentheses). The second dot does not require an escape character because it is not in a method parameter (it is outside the parentheses).

    No Format
  • The following getter chain is from a transaction splitting rule on URIs that use a semicolon as a delimiter.

    No Format

    The call gets the URI using getRequestURI() and then splits it using the escaped forward slash. From the resulting array it takes the third entry (as the split treats the first slash as a separator) and inserts what before the slash (in this case, nothing) into the first entry. Then it splits this result using the semicolon, getting the first entry of the resulting array, which in this case contains the API name. 
    For example, given the following URI:

    No Format

    The getter chain splits on the API name, so the resulting split transactions are "API.abc", "API.xyz" and so on.

    Tip: When using string.split(), remember that it takes a regex and you have to escape any special regex characters.

    For example, if you want to split on left square bracket ([):

    No Format
    Java syntax: split("
    Getter chain syntax: split([)