How to use Business Transactions

The main features of Business Transactions

The following is a list of the significant business transactions features:

  • Operates on server-side PurePaths.
  • Evaluates user actions.
  • Filters and splits..
  • Limits split values to significant values only with Smart Splitting
  • Baselines default results response time count and failure rate.
  • Includes numerous default business transactions.
  • Includes configurable measures storage in performance warehouse.

Goal of this tutorial

To demonstrate some of the previously listed features. You'll create new business transactions based on the default transactions. These transactions use filters to get meaningful and representative information from all web requests. You'll also group by various means and, finally, create a few charts for your measures.

Scenario

Use the easyTravel demo application to learn about various AppMon features and functions. Or you can use any standard web application because this scenario works with simple web requests. The tutorial includes the following steps:

  1. Create a basic business transaction for web requests.
  2. Add additional return values.
  3. Understand synthetic vs. real web requests.

Requirements

Run the demo application with injected agents and connect to a System Profile. If you use your own application, associate and activate the necessary web server Sensor.

Creating a basic Business Transaction for web requests

Enable the web request sensor in your System Profile to see the single requests to your application server. Your application may request single resources such as style sheets and images. Typically, you won't need this static content, or requests from bots or spiders, since they distort the necessary data.

Follow these steps to create a business transaction that filters out these requests:

  1. Right-click your System Profile and select Edit System Profile > Business Transaction.
  2. Click Create to create a new business transaction.
  3. Give it a name, such as Demo Web Requests.
  4. To return only relevant requests, add the following predefined filters from the Transaction Based Measures > Web Requests group:
    • No JS, CSS Requests: This uses a negation regular expression for URIs containing .js and .css files.
    • No Image Requests: This uses a negation regular expression for URIs containing .jpg, .jpeg, .gif, .png, and .ico files.
  5. Add an advanced filter from the Business Transaction Evaluation/Filter/Splitting Values group: No Spider Request: This looks at the web request's header field User Agent and uses a regular expression.

Note

The No Spider Request filter's regular expression may not exclude each bot and spider. If your site gets crawled by bots or spiders, adapt the filter or create additional filters. See http://www.user-agents.org for a list of user agent strings.

The result is the average response time (the PurePath duration) for the web requests. Use this business transaction to configure further, and chart this measure for an overview.

The image below shows the business transaction configuration and a dashboard that includes the following:

  • The overall web requests that match the Demo Web Requests business transaction.
  • The matching PurePaths.
  • A simple chart with the average response time over time.

The average response time varies because there are different requests with different execution and response times. You should group and separate (split) different web requests.

Add additional return values

In addition, you may want to analyze other metrics, like response size or the request size. With AppMon you can get them from the same business transaction. Follow these steps:

  1. Open the System Profile editor, and select sensor, responsible for web requests. In our example it is Servlets from the Customer Frontend (Java) Agent group.
  2. Make sure that the Measure request/response sizes check box is selected.
  3. Switch to the Business Transactions item, and select the Demo Web Requests business transaction for editing.
  4. In the Calculate Results pane, click + to add measures.
  5. In the Select Measure dialog box, find and select the Bytes Received and Bytes Sent measures from the Server Side Performance > Transaction Based Measures > Web Requests group.
  6. Save the changes to the business transaction.
  7. In the Cockpit, expand the Business Transactions node of the System Profile (easyTravel in this tutorial), and double-click the Demo Web Requests.
  8. In the Business Transactions dashlet, note two new columns with the newly added measures. You can use them, for instance, in charts.
  9. Add a new Chart dashlet.
  10. Click Add Series, find and select Bytes Received measure of the Business Transactions > Demo Web Requests group for it.
  11. Repeat for the Bytes Received measure.
  12. Experiment with charts, to get the most valuable and comfortable for you appearance. See Chart dashlet for more information.

Synthetic vs real web request

Monitor or load test tools, and not users, to generate synthetic web requests. Use these to test, or check availability, of a service to get the following:

  • Metrics from an application (a server status page that contains metrics).
  • Performance data for a certain function.

You can filter out those requests from your production monitoring charts, or treat them separately. They use the same data and parameters every time. This makes them unsuitable for data-driven behavior, and therefore, they aren't very representative.

These synthetic requests contain information to distinguish them from real requests. If you use AppMon's built-in web transaction monitors, it adds an HTTP header field labeled dynatrace. This makes it easy to create a filter or grouping. Also, this header is used when you integrate with test tools.

AppMon includes the following two predefined measures, which you can use as filters to include or exclude these requests:

  • No Synthetic Dynatrace Request
  • Synthetic Dynatrace Request

The Tagging setting in this filter only refers to the AppMon header. When you add the No Synthetic Dynatrace Request filter to the business transaction you can remove all of the requests generated by your own web transaction monitor. This lets you see only the real requests.

Now, you can create two copies of the previously used business transaction. You can add a different filter to each copy, and separate synthetic and real web requests.

  1. Open the System Profile editor, and select the Business Transactions item.
  2. Make a copy of the Demo Web Requests business transaction, and select it for editing.
  3. Change the name to the Demo Web Requests - Synth
  4. In the Filters pane, add the Synthetic Dynatrace Request measures.
  5. Save your changes.
  6. Repeat for the No Synthetic Dynatrace Requests measures.
  7. Put the new business transactions on one dashboard. After you create a few manual requests, you can see a difference between the synthetic and real requests.

Conclusion

AppMon has many features to easily manage business transactions. Multiple return values are a great way to get more than one metric from the same underlying Purepaths. Use regular expressions to filter and group, and get meaningful splitting values.

You can also use business transactions for the following:

  • Filter PurePaths by missing method calls. You use a negative filter that throws incidents if a method that is expected to be called isn't called.
  • User actions and visits.
  • Add multiple grouping values, like grouping by URI and by HTTP header value/parameters.

Expressions

Too many complex regular expressions can cause an excessive load on your system. Also, if you split by a Measure and generate many unique values, such as a session ID, it can add an excessive load on your performance warehouse.