APM to Dynatrace
Introduction
The 1Gateway for Servicetrace APM to Dynatrace solution collects response time metrics from Servicetrace APM and sends them to Dynatrace as Synthetic Tests. It retrieves scheduled workflow run results by polling the Servicetrace database periodically for new results.
Dynatrace does not accept data older than 2 hours, so for best results, leave the solution running 24x7.
Step-by-step
- Install 1Gateway
- Install plugins and licenses package
- Restart 1Gateway
- Configure Dynatrace Sender plugin
- Configure Servicetrace APM Listener plugin
Overview
The Servicetrace APM - Dynatrace integration uses two plugins:
The Dynatrace sender inserts external tests and its results into Dynatrace using the External Synthetic API.
Installation
First install 1Gateway on the APM WIndows server.
Run the windows installer executable and follow the steps in the install wizard. The installer package for windows is called 1Gateway-2.5.9-windows-installer.exe.
Login
After the installation, if you checked the option to launch 1Gateway, you will see the following screen:
Enter the value ´admin´ for both the userid and password and click on the ´LOGIN´ button.
*Note: If you did not choose the option to launch 1Gateway at the end of the installation, simply navigate to http://localhost:8090 to launch 1Gateway
The resulting screen is the status overview screen.
Install Licenses
Make sure you are in administrator mode, navigate to system maintenance, and drag and drop your license file onto the file upload area at the top of the screen, or click within this area to select your license file from your file system.
Now return to the status screen by clicking on 1Gateway logo in the header at the top right of your screen or by choosing ´Status Overview´ from the dropdown menu. You should now see that the plugins are licensed and ready for configuration.
Configure the plugins
Dynatrace sender plugin
Enter the name of your Dynatrace server and click on “PROFILES” at the top to configure your customer environments.
Click on “ADD PROFILE” to configure your first environment.
CAUTION: The name you enter in the profile needs to be exactly the same as the name of the customer defined in APM!
Field name | Supported values | Description |
---|---|---|
Dynatrace server | URL to Dynatrace Instance | Dynatrace server. |
API Key | Any string | Dynatrace API key |
NOTE: Known issue – the TEST button does not work, and always returns “Test failed”. This does not indicate that the environment is incorrect. This issue will be resolved in a future release.
NOTE: The outbound message that is sent to Dynatrace needs to contain an "enviroment" key with the name of the plugin profile defined. This can be changed in the Dynatrace sender mapper
Servicetrace APM poller plugin
Click on the three dots at the right top of the Servicetrace APM Poller plugin and select “Edit”:
Enter the name of your APM server and the Administrator API key and a polling interval in seconds. The system will poll APM for new run results at this interval. Recommended value is 300 seconds, or every 5 minutes. Other configuration values may be required based on your particular data polling needs and are described in the following table.
Field name | Default/suggested value | Description |
---|---|---|
Database configuration fields | ||
Use database? | True / false | If true, the plugin will poll for data from the APM database directly. If false, it will poll for the data through the Servicetrace APM REST API. If true, configure the database configuration fields, otherwise they can be left blank. |
Use windows authentication? | True / false | If true, uses windows authentication in the JDBC connection string (appart of the sandard SQL authetication fields set, integratedSecurity, authenticationScheme and domain are also set) If false, uses SQL authentication in the JDBC connection stirng (only sets dsatabaseName, UserName and Password) |
Database host | n/a | Host of the SQL server used the Servicetrace APM |
Database domain | n/a | Only used in "Use windows authentication?" flag is set. Domain used for authentication |
Database user | n/a | Username used for SQL / windows authentication |
Database password | n/a | Password of the user used for SQL / windows authentication |
Database name | n/a | Name of the database to connect to |
Field parameter | id | Name of the identification field in the message |
Field default value | 1 | Default value of the identification field in the message. Only used in first poll. |
Servicetrace APM configuration fields | ||
Servicetrace server | n/a | Servicetrace server or IP |
API Key | n/a | Servicetrace API Key |
URI Schema | http | |
Maximum delay in APM data (minutes) | 5 | The maximum out of sequence data that we allow for. Should be longer that the longest runtime of any APM script |
Maximum interval for run results in APM (minutes) | 121 | The longest schedule interval in APM + 1. If APM scripts are run every two hours, then 121 minutes will result in capture of all data. |
Oldest data to retrieve (hours) | 2 | Always set to two hours when used with Dynatrace. |
Refresh customers and services every (hours) | 2 | Depends on the frequency that customers are added to APM. We check for new customers at startup. If customers are added frequently, this value should reflect that. |
Polling interval | 300 | Polling interval in seconds (recommended is 300) |
SQL query file path | data/catalog/plugins/plugin-stapm-poller/${version}/support_files/query.sql | Path to the SQL query to run in case Use Database? is true |
Once you have finished configuring your plugin, the following status screen will appear:
Activate the plugins
Activate the plugins and confirm that messages are being retrieved from APM Servicetrace by the poller and sent to Dynatrace
Activate Dynatrace sender plugin
Click on the three vertical dots for the Dynatrace plugin and choose the 'activate' option.
Activate Servicetrace APM poller plugin
Click on the three vertical dots for the APM plugin and choose the 'activate' option.
Check result
Click on 'Show messages' in the Servicetrace APM poller plugin to check that messages are being collected from APM. Click on 'Show messages' on the Dynatrace sender plugin to check that messages from APM are being transformed into a Dynatrace format.
Check Dynatrace for results: