Advanced settings

Updated at:

During JMeter stress testing, you can use the advanced settings to configure the log sample rate, DNS cache, and resolution rules.

Log sample rate

You can set a custom sample rate for logs. The default sample rate is 1%. To decrease the sample rate, enter a value in the range (0, 1]. To increase the sample rate, enter a number divisible by 10 in the range (1, 50], such as 20.
Note If you increase the sample rate, an additional fee applies. For example, a sample rate of 20% incurs an additional fee of 20% × Virtual User Minutes (VUM). For more information about billing, see Billing items.

DNS cache

On the Advanced settings page, you can choose to clear the DNS cache for each request. To do this, turn on the cache switch and select either Use system DNS resolver or Use custom DNS resolver.

If you use a custom DNS resolver, you can define custom domain name binding rules under the DNS cache area to resolve the target domain name to a specific IP address.

This feature only takes effect on HTTPSamplers that use the HTTPClient4 implementation. If no DNS server or domain binding information is specified, the system DNS resolver is used by default. The custom DNS resolver consists of two configuration areas: DNS Servers (enter domain names or IP addresses) and Domain Bindings (enter domain names and the corresponding IPv4 or IPv6 binding addresses).

Use a custom DNS resolver in the following scenarios:
  • Stress testing in a public staging environment

    When stress test requests must be accessed over the public network, you can bind the IP address of the staging environment to the public domain name. This isolates stress test traffic from production traffic and prevents impact on your live services.

  • Stress testing in PTS using the Alibaba Cloud VPC private network mode

    This stress testing mode runs tests over an Alibaba Cloud VPC private network. To avoid changing the API endpoint domain name for the test, you can bind an Alibaba Cloud VPC private network IP address to any domain name in the scenario. This lets you run stress tests within the Alibaba Cloud private network. For more information, see Alibaba Cloud VPC private network stress testing.