Can I customize how process groups are detected?

For servers like JBoss, Tomcat, or Glassfish, Dynatrace automatically detects if multiple processes should be included in the same group. With Tomcat Dynatrace uses CATALINA_HOME and CATALINA_BASE to distinguish between different Tomcat clusters. For JBoss, Dynatrace uses JBOSS_HOME and the JBoss cluster configuration. For generic Java processes Dynatrace uses the JAR file or the main class used to start the process. Learn more about how Dynatrace tracks host processes.

This approach to process detection works fine in most cases, but isn’t perfect. This is why we’ve enabled you to customize how Dynatrace detects and identifies host processes in your environment.

What does this mean for services?

Dynatrace doesn’t merge services that are hosted across multiple process groups, because each process group is considered to be a logical cluster. When Dynatrace detects the “same” service in separate process groups, it treats them as separate services (e.g., one process might be used in staging and the other in production). However, if you instruct Dynatrace to merge two separate process groups into a single group, this will also result in the services on those processes being merged as well.

Adjusting detection of Java processes

Dynatrace allows you to specify Java system properties to adjust process group detection.

Go to Settings > Monitoring overview > Process group naming.

Here you create a naming rule that uses a Java system property to identify a process group (i.e., a cluster of Java processes that belong together). The Java system can be either an existing system that your application already uses (e.g., three different jetty.home values for three different Solr clusters) or you can add a new system. As long as the system property is available, Dynatrace can use it.

Optionally, you can define a second property that identifies a specific node in the cluster. This is useful if your cluster setup has specific names per node. For a detailed example, please see our Customizing process detection blog post.

Adjusting Tomcat detection

Normally CATALINA_HOME and CATALINA_BASE are two sides of the same coin and Dynatrace uses the combination to detect Tomcats and logical Tomcat clusters. In some scenarios CATALINA_BASE is used to configure different nodes of the same logical Tomcat cluster. To address this, go to Settings > Monitoring overview > Process group naming and enable the Use CATALINA_BASE to identify Tomcat cluster nodes switch. This will result in Tomcats being grouped solely on the basis of CATALINA_HOME and CATALINA_BASE representing the different nodes of that group.

Customizing detection of other process types

You can set the environment variable DT_CLUSTER_ID to have all processes that have the same value for this variable grouped together into the same process group. This variable sets the ID of cluster processes that belong together (for example, clusters of Apache web servers that belong together and host the same site). All processes found in a tenant that share the same ID are treated as the same process group, separate only by the hosts they run on.

Be sure that you only set the DT_CLUSTER_ID variable on a process-by-process basis, not system wide! If you set this variable system-wide, all processes may be grouped into a single process group for monitoring. This is undesirable and unsupported.

Separating process-cluster nodes

To separate nodes of a process cluster that run on the same host, use the DT_NODE_ID environment variable. This tells Dynatrace which processes should be considered separate process group instances.