Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions APM/After+Startup+Error.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ parent: "Installation+steps"
---
Sometimes after startup an error in java occurs when Mendix generates a different parameter name in a different Mendix version. If this happens, let me know via apmtool@mansystems.nl, so Mansystems can rename the java action parameter that causes this.
You can solve this the following way. First you open the project folder:
![](attachments/20644420/21168266.png)
![](attachments/After_Startup_Error/Show_Project_Dir.png)

And search for the file in the javasource/ apmagent/actions folder
![](attachments/20644420/21168267.png)
![](attachments/After_Startup_Error/Explorer_Actions_Folder.png)

You have to change the old parameter name into the new parameter name in java in the code between the lines
// BEGIN USER CODE
and
// END USER CODE
.
Sample java file that Mendix generates with some fictive parameter mismatch:
![](attachments/20644420/21168268.png)
![](attachments/After_Startup_Error/Action_Java_Source.png)
76 changes: 50 additions & 26 deletions APM/Console.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,58 +4,82 @@ category: "User Manual"
---
This chapter describes the APM Tool console. This is the home screen of the APM tool. The following screenshot shows the APM Tool Console.

![](attachments/19956212/21168246.png)
![](attachments/Console/Overview.png)

The console shows the primary APM tools, allows you to start and stop them and shows counters to see what these tools are currently doing. You also see some badges indicating if additional tools are running. These badges can be clicked to jump directly to their respective tools. You can refresh counters on the console to keep track of what is happening by clicking the [Refresh All Counters] button.
The console shows recent information from the statistics, measurements, trap and log tools.
The individual tools can be selected from the menu on the left side of the page.
These tools are described in separate chapters. In this chapter the overall tool configuration is described.

All tools, including those under the tools menu are described in a separate chapter. This chapter describes the _Settings, including licensing, _the _Search menu and the rerouting dialog:_

## Settings
## After Startup Configuration

From the console, you can change the application wide settings:
![](attachments/Console/Settings_After_Startup.png)

![](attachments/19956212/21725190.png)
Here you determine which tools should run _after startup_.
There is also a safety constant (in the Mendix Modeler) which overrules these after startup settings and
enables the admin to take control of these settings.

Here you determine which tools should run _after startup_. There is also a safety constant (in the Mendix Modeler) which overrules these after startup settings and enables the admin to take control of these settings.
As a protection, you can set a _Maximum log level after startup_ if the Log Tool is run after startup.
This can avoid the Log Tool running on an unexpectedly high level after startup.

As a protection, you can set a _Maximum log level after startup_ if the Log Tool is run after startup. This can avoid the Log Tool running on an unexpectedly high level after startup.
You can configure what should happen with the Performance Tool before shutdown.
Default it will cancel a running recording,
but you can choose to _Stop and process the Performance Tool before shutdown_.
If you have proper protection settings like thresholds and maximum number of microflows
(see Performance Tool options) you can run the performance tool in a production environment.

You can configure what should happen with the Performance Tool before shutdown. Default it will cancel a running measurement, but you can choose to _Stop and process the Performance Tool before shutdown_. If you have proper protection settings like thresholds and maximum number of microflows (see Performance Tool options) you can run the performance tool in a production environment.
In some cases, tools are run for a fixed period of time.
However running after startup usually means you want to run a specific tool all the time.
With the option _Clear fixed period of time after startup_ you can make sure
the tools will keep on running after startup.

In some cases, tools are run for a fixed period of time. However running after startup usually means you want to run a specific tool all the time. With the option _Clear fixed period of time after startup_ you can make sure the tools will keep on running after startup.
## License Detail Configuration

## License Information
![](attachments/Console/Settings_License.png)

The APM Tool requires an application license that can be requested via mail using the button in the settings dialog on the second tab.

A license is required per App. Every license has an end date.

The license code goes in the license field. The _Expiry date_ field can be used to store the license expiration date.
The license code goes in the license field. The _Expiry date_ field is automatically filled.

![](attachments/19956212/21725191.png)

## Advanced Configuration
## Log Rerouting Configuration

![](attachments/Console/Settings_Rerouting.png)

This option adds log messages from other sources to the Mendix logging,
so all log information is combined and available in the log and trap tool.

A JDBC URL and explain plan query are added to the global settings. These are automatically filled during the installation.
An example: javax.mail sends debug output to the console(system.out).
With the [Java Console Rerouting] option enabled the debug output is catched and provided to the Mendix logging.

This URL is used for explain plan and in the query tool. You can use $HostName, $PortNumber,$DatabaseName, $UserName and $Password. They will be replaced with the current one on execution. This allows for production database dumps to be used without the risk of connection to the production database from a test environment after the load of a production dump.
You can manually start/stop the rerouting options. Rerouted are:
* Java standard output (system.out) and standard error (system.err) messages,
* Java Util logging
* Log4j messages

## Search Menu
## JDBC Configuration

The search menu allows you to search through data- and statistics recorded by the different tools provided by APM.
![](attachments/Console/Settings_JDBC.png)

![](attachments/19956212/21725192.png)
A JDBC URL is automatically set during installation. For special cases this URL can be changed.
The URL can contain variables that are replaced on executing a JDBC statement.
You can use $HostName, $PortNumber,$DatabaseName, $UserName and $Password.
They will be replaced with the current one on execution.
This allows for production database dumps to be used without the risk of connection to the production database from a test environment after the load of a production dump.

_Search Microflows_ allows you to browse through microflows including the calling tree (microflow > microflow) which can help find bottlenecks in long running microflows/actions.

Runtime requestscan be triggered by the client API to execute a microflow, retrieve-, change-, delete data and more. Scheduled events and web services also trigger runtime requests. _Search Runtime Requests_ allows you to investigate these application runtime requests coming from different entry points.
The explain plan query is also automatically set during installation.
This query is used with the explain plan option in the performance tool.

## The Log Rerouting
The next 4 options are used in the query tool to determine the output and set a timeout.


## Advanced Configuration

The Java standard output(system.out) and standard error(system.err) messages, the Java Util logging and Log4j messages are not visible and not recorded for a Mendix application. Using the Log Rerouting function the log messages generated by these logging mechanism can be rerouted to the Mendix logging mechanism(Core.logger).
![](attachments/Console/Settings_Advanced.png)

The dialog to manage these options can be opened from the console rerouting button and looks like this:
A default measurement graph can be chosen for the console.

![](attachments/19956212/21725193.png)

An example: javax.mail sends debug output to the console(system.out). With the [Java Console Rerouting] option enabled the debug output is catched and provided to the Mendix logging mechanism and as such made available to the Log Tool and Trap Tool.
6 changes: 3 additions & 3 deletions APM/Inserting+context+information.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The Performance Tool (since version 1.2.1) has a special action to allow context

To add context information use the java action PerformanceTool.PerformanceToolInfoAction in your microflow as shown below.

![](attachments/19956341/20218034.png)
![](attachments/Inserting_context_information/Performance_Tool_Info_Action_Details.png)

You can use the info string for the action name and a message string. Optionally you can add 3 mendix objects that have all their attributes added.

Expand All @@ -18,8 +18,8 @@ You can use the info string for the action name and a message string. Optionally

This leads to an action in the action list with context information:

![](attachments/19956341/20218032.png)
![](attachments/Inserting_context_information/Microflow_Java_Action.png)

Details of the Performance Tool info action will look similar to the image below.

![](attachments/19956341/20218033.png)
![](attachments/Inserting_context_information/Performance_Tool_Info_Action_InList.png)
33 changes: 9 additions & 24 deletions APM/Installation+steps.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,38 +7,29 @@ This chapter describes the installation of the APM tool.
# Backup

Did you commit your work to the team server? And did you make a database backup?
![](attachments/20644417/21168256.png)
![](attachments/Installation_steps/Commit.png)

If you don't have installed an SVN client like Tortoise SVN make a copy of the widgets folder in your project.

# Import Module APMAgent

Import the module APMAgent in the modeler.
![](attachments/20644417/21168257.png)
![](attachments/Installation_steps/Import_Module_Package.png)

Write down the widgets in the warning dialog that are overwritten to be able to revert these changes.

# Optional: revert overwritten widgets

If you don't want your widgets replaced with the widgets in the APM Tool module use the Tortoise SVN revert function on the widgets folder. Or copy the backup widgets from the first step back to the widgets folder.
Unmodified AppStore widgets:
\widgets\CustomString.mpk
\widgets\ChartJS.mpk
\widgets\BootstrapTreeViewWidget.mpk
Mansystems also added some widgets that are not in the AppStore.

# Copy Language if other than English US is used

If you are not using only English, United States copy the English, United States language for the APMAgent module to all the languages using Tools\Language Operations in the modeller:
![](attachments/20644417/21168258.png)

![](attachments/20644417/21168259.png)
![](attachments/20644417/21168260.png)
![](attachments/Installation_steps/Language_Operations_Header.png)
![](attachments/Installation_steps/Language_Operations_APM.png)
![](attachments/Installation_steps/Language_Operations_Footer.png)

# Add permissions

Add permissions APMAgent.Admin to project security / user roles tab to a selected administrator role.
![](attachments/20644417/21168261.png)
![](attachments/Installation_steps/Add_Permissions.png)

**_Note._** _Do not use the Debug role. This is for developer of the APM tool to test certain features._ _If you want to get rid of the warnings about security introduce a Debug user role and give this user role permissions to APMAgent.Debug._

Expand All @@ -49,7 +40,7 @@ Add permissions APMAgent.Admin to project security / user roles tab to a selecte
# Add to navigation

To use the APM Tools you need to call the APM Tool user interface (UI). Use the "APMAgent/USE_ME/IVK_OpenConsole" microflow for this. Add a navigation menu item for example.
![](attachments/20644417/21168262.png)
![](attachments/Installation_steps/Add_To_Navigation.png)

# Optional: Add to After startup and before shutdown

Expand All @@ -60,13 +51,7 @@ Call APMAgent\USE_ME\AfterStartup from an after startup microflow. This feature
Call APMAgent\USE_ME\BeforeShutdown from a before shutdown microflow.

You can find the AfterStartup and BeforeShutdown microflows in the project settings.
![](attachments/20644417/21168263.png)

# Fix error(s)

The following error is known to appear:

1. An error that you have to update widgets because a different version is used in the project
![](attachments/Installation_steps/Project_Settings_After_Startup.png)

# Start the Modeler or the Runtime

Expand All @@ -79,7 +64,7 @@ Otherwise login as Admin and navigate to the APM Tool.
# Welcome dialog

After startup for the first time a small wizard is started:
![](attachments/20644417/21168264.png)
![](attachments/Installation_steps/Welcom_Dialog.png)

* Use button to send mail with license request
* Upon receiving the license, copy-paste
Expand Down
1 change: 0 additions & 1 deletion APM/Installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ For the experienced user quick outline of the installation:

* Backup (commit in Modeler, backup database, copy project folder?)
* Import APM Agent module
* Optionally revert widgets
* Copy language if other than English US is used
* Configure to use USE_ME/AfterStartup and USE_ME/BeforeShutdown
* Add permission(s) to your Administrator role
Expand Down
10 changes: 5 additions & 5 deletions APM/Introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,22 +20,22 @@ The APMx Statistics tool collects statistical data on microflows and client API

_Screenshot of the statistics tool. For load balanced environments you see the server where the microflow runs. _

_![](attachments/19956139/21725185.png)_
_![](attachments/Introduction/Statistics_Tool.png)_

# The Performance Tool to record microflows

When our support wants to investigate a performance issue, either pro-actively coming from the statistics tool or reactively when a customer reports an issue they use the APMx Performance tool. With this tool they can see on the action level the duration of the steps in the microflow. They can drill down and see individual SQL statements. They can even ask the database for an explain plan that tells you how the database processes the query, which indexes it uses and more. This tool quickly helps to pinpoint where the issue is.

_Screenshot of call tree. Gives you an overview of what happens, showing called microflows and 1 iteration of a loop, filtering by duration._

![](attachments/19956139/21725186.png)
![](attachments/Introduction/Performance_Tool_Browse_Actions.png)
_Screenshot of the performance tool output. You can double click on all actions and in the case of microflow call, you browse to the next microflow and in the case of loops you will see the individual iterations._

![](attachments/19956139/21725187.png)
![](attachments/Introduction/Performance_Tool_Browse_Microflow.png)

_Screenshot of SQL statements during an action._

![](attachments/19956139/21725188.png)
![](attachments/Introduction/Performance_Tool_Tree_View.png)

# The Measurements Tool to collect even more information and trigger an alarm when needed

Expand All @@ -45,7 +45,7 @@ The measurements can be used to trigger events on thresholds. For example if mor

The trigger can be to trap logging, to execute a microflow, for example to send an email or to make a heap dump.

![](attachments/19956139/21725189.png)
![](attachments/Introduction/Measurements_Tool.png)

# The Trap Tool is your flight data recorder

Expand Down
6 changes: 3 additions & 3 deletions APM/JVM+Browser.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ category: "User Manual"
---
A JVM Browser shows information similar to JConsole or JVisualVM tools provided with the Java JDK. Using the [Refresh] button refreshes an individual item.

![](attachments/19956346/20218035.png)
![](attachments/JVM_Browser/Overview.png)

Double clicking an items drills down shows its details.

![](attachments/19956346/20218036.png)
![](attachments/JVM_Browser/Details.png)

You can start collecting statistics on individual items using the [Collect] button. These statistics can be viewed in the Measurements Tool.

Expand All @@ -18,4 +18,4 @@ The statistics of the tools, measurements as well as Mendix statistics are made

An example of Mendix runtime statistics is show in the image below

![](attachments/19956346/21725216.png)
![](attachments/JVM_Browser/Additional_JMX.png)
2 changes: 1 addition & 1 deletion APM/Java+security+settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Procedure to simulate cloud security plus APMAgent permissions:

1. Turn off the emulate cloud security option in project settings, active configuration, server tab

![](attachments/20644421/21168269.png)
![](attachments/Java_security_settings/Java_Command_Line_Options.png)

1. Copy file =<project-folder>\resources\apmtool\mx5\apm_cloud_template_mx5.policy to a **<new file>**. Change the file replacing <project-folder> with your actual project folder path.

Expand Down
6 changes: 3 additions & 3 deletions APM/Load+Test+Recorder.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,21 @@ This chapter gives an overview of the load test recorder. Mansystems has a load

The APM Tool includes the load test recorder, so APM Tool users are immediately ready for a load test and need not again add a module to their App. Load test customers will need the APM Tool for measurements and hence also benefit from the addition.

![](attachments/20644530/21168288.png)
![](attachments/Load_Test_Recorder/Overview.png)

## Load Test Recorder Control

You can start and stop the Load Test Recorder. The followingscreenshot below shows the Log Tool when started:

![](attachments/20644530/21168289.png)
![](attachments/Load_Test_Recorder/Control.png)

You can Start and stop timers to mark individual functionality in the session. This helps the load tool to measure those functions.

## Load Test Recorder Options

The following screenshot shows the Load Test Recorder Options:

![](attachments/20644530/21168291.png)
![](attachments/Load_Test_Recorder/Options.png)

The [Max messages to record] can limit the amount of records in memory. The recording stops when the maximum is reached.

Expand Down
Loading