Showing results for 
Show  only  | Search instead for 
Did you mean: 

This product reached the end of support date on March 31, 2021.

Maven Testing Automation Issues and Questions



I have a client that is trying to integrate Dynatrace with Maven to facilitate testing automation. They are referencing this documentation ( The clients goal is to capture session (include purepath) during their
performance testing. Currently, they use Dynatrace client GUI, set the
customer date/time range and export the result. Ideally they would like
to automate this. Their testing is done with JMeter and they would like
to orchestrate JMeter run and Dynatrace capturing with Maven script.

When running the mvn tool, they are getting this error:

Using a REST client, they get the error:

Session recording is not allowed if continuous transaction storage is enabled.

The issue is that the Dynatrace server is being used by other business units, so they have not
disabled continuous storage. They want to schedule it for overnight, and had a few questions. I have not done anything with Maven and am still learning about automation in general, so was wondering if anyone on the community has done this or has any thoughts. Here were the clients questions:

  • 1.)Is it
    possible to enable/disable via REST services?
  • 2.)What
    is required to download (only Maven plug-in) in order to use it?
  • 3.)Are there any other potential issues that can be determined from the context above?




Dynatrace Pro
Dynatrace Pro

Hi Brittany,

CTS cannot be enabled/disabled via REST AFAIK. Keep in mind that a server restart is also required each time you change it.

I am not sure why you would use the dtAutomation library in this case.

As you are using jMeter it might make more sense to include the DT REST calls immediately in the jMeter test plan. The dtAutomation library is especially geared towards unit and integration tests. Since all the dtAutomation library does is executing the right REST calls at the right time and relaying the testRunID to the underlying unit/integration tests, there is nothing that cannot be done without it. There is a pretty good walkthrough on how to do that here:

In jMeter you can start the session recording before the test (given that CTS is disabled); inform Dynatrace that a test is coming and tag all the subsequent tests with the returned testRunId and at the end stop recording all using the specific REST calls outlined here:

Hope this makes sense for now and is enough to get you started. Let us know if any other issues come up.


I agree with Kristof. I also have some JMeter Scripts that make these REST Calls and then use the TestRunID that gets returned by the registerTestRun REST CALL with the x-dynatrace HTTP Header


Awesome, thank you so much for the detailed explanation!! That's very helpful and I really appreciate it. I've let the customer know and will reply back if any more issues come up. Thanks again!