Convert API Monitoring Test to Performance Test

You can convert your API Monitoring tests into BlazeMeter Performance tests. This feature works by converting your existing JSON files (used for monitoring) into JMX files, the standard format for performance testing with Apache JMeter.

How Conversion Works

API Monitoring tests are built to ensure the functionality and health of your APIs. By converting them into Performance tests, you can evaluate how your APIs perform under different load and stress conditions.

BlazeMeter takes your JSON configuration, which defines API calls, endpoints, request methods, parameters, and assertions, and transforms it into a JMX file format. This JMX file can be used directly in JMeter, saving you time and effort in recreating these tests manually.

By leveraging this feature, you can go beyond functional monitoring and gain deeper insights into your API's performance. Load test your APIs, check response times under various levels of stress, and pinpoint bottlenecks more effectively.

To convert your API Monitoring test into a Performance test:

  1. Navigate to the Test Editor by clicking on an existing test or selecting Create Test.

  2. From the left pane, select Convert.

  3. Select the Workspace and Project from your BlazeMeter account to convert the test into. A new Performance Test will be generated within the specified workspace and project.

  4. Select Convert to Performance Test. Upon successful conversion, you will be redirected to the new Performance Test in a separate tab.

    The redirect will occur only if popups are enabled.

Conversion Limitations

During conversion, steps like Request, Pause, and Conditional If are generally supported, but some limitations apply:

  • API Monitoring Test Settings (such as test environments) will not be converted into JMeter equivalents.

  • Incoming/Inbound Requests, Conditional Loops, Subtests, and browser performance test steps will not be converted.

  • For Request steps, while API Monitoring supports various Assertions and Variable Extraction combinations, JMeter has limitations. For instance, API Monitoring allows you to assert that a specific JSON field's value is greater than 0, but JMeter's JSON Assertion does not have greater_than or less_than options, opting instead for comparisons like equal, not_empty, empty and not_equal. Incompatible assertions will be skipped during conversion.

  • In JMeter, Timers are always executed before a request (or any Sampler). If there is a Pause step between two requests in API Monitoring, JMeter attaches a Constant Timer to the second request. However, if a Pause step is at the end of a test or block (such as Conditional If), it is skipped during conversion as it serves no purpose. For example, a Pause step at the end of a Conditional If block will be omitted from the JMX file.

  • Pre-request and post-request scripts will be converted to JSR223PreProcessor and JSR223PostProcessor in JMeter, respectively. However, if a script uses any API Monitoring-specific functions, its content is not automatically converted. You will need to manually adjust the syntax.

  • Any API Monitoring operation that includes interaction with files, such as adding multipart bodies, binary bodies, or snippets, are not included in the conversion. You will have to handle them manually after the conversion process.