Add APM user settings

Change how the APM Server runs by providing your own user settings. User settings are appended to the apm-server.yml configuration file for your instance and provide custom configuration options.

Tip

Some settings that could break your cluster if set incorrectly are blacklisted. Review the list of settings that are generally safe in cloud environments. For detailed information about APM settings, see the APM documentation.

To add user settings:

  1. Log into the Elasticsearch Service Console.
  2. On the Deployments page, select your deployment.

    Narrow your deployments by name, ID, or choose from several other filters. To customize your view, use a combination of filters, or change the format from a grid to a list.

  3. From your deployment menu, go to the Edit page.
  4. At the bottom of the APM instance, expand the User settings overrides caret.
  5. Update the user settings.
  6. Click Save changes.
Note

If a setting is not supported by Elasticsearch Service, you will get an error message when you try to save.

Supported APM settings

Elasticsearch Service supports the following APM settings.

For version 7.2 and later:

This stack version includes all of the settings from 7.2 and the following:

apm-server.ilm.enabled
Enables index lifecycle management (ILM) for the indices created by the APM Server. Defaults to false. Please make sure that, for existing APM server, you add that setting together with: setup.template.overwrite: true (defaults to false). Otherwise the index template will not be overridden and ILM changes will not take effect.

For version 6.5 and later:

This stack version includes all of the settings from 6.4 and the following:

apm-server.max_event_size
Specifies the maximum allowed size of an event for processing by the server, in bytes. Defaults to 307200.
output.elasticsearch.pipelines
Adds an array for pipeline selector configurations that support conditionals, format string-based field access, and name mappings used to parse data using ingest node pipelines.
apm-server.register.ingest.pipeline.enabled
Loads the pipeline definitions to Elasticsearch when the APM Server starts up. Defaults to false.
apm-server.register.ingest.pipeline.overwrite
Overwrites the existing pipeline definitions in Elasticsearch. Defaults to true.
apm-server.rum.event_rate.lru_size
Defines the number of unique IP addresses that can be tracked in the LRU cache, which keeps a rate limit for each of the most recently seen IP addresses. Defaults to 1000.
apm-server.rum.event_rate.limit
Sets the rate limit per second for each IP address for events sent to the APM Server v2 RUM endpoint. Defaults to 300.
Note

With the version 6.5 release, we recommend verifying that your agents continue to be compatible with your APM Server.

For version 6.4 and later:

apm-server.rum.enabled
Enables/disables Real User Monitoring (RUM) support.
apm-server.rum.allow_origins
Specifies the comma-separated list of permitted origins from user agents. The default is *, which allows everything.
apm-server.rum.library_pattern
Differentiates library frames against specific attributes. The default value is "node_modules|bower_components|~".
apm-server.rum.exclude_from_grouping
Configures the RegExp to be matched against a stacktrace frame’s file_name.
apm-server.rum.rate_limit
Sets the rate limit per second for each IP address for requests sent to the RUM endpoint. Defaults to 10.
apm-server.capture_personal_data
When set to true, the server captures the IP of the instrumented service and its User Agent. Enabled by default.
setup.template.settings.index.number_of_shards
Specifies the number of shards for the Elasticsearch template.
setup.template.settings.index.number_of_replicas
Specifies the number of replicas for the Elasticsearch template.

For version 6.3:

apm-server.frontend.enabled
Enables/disables frontend support.
apm-server.frontend.allow_origins
Specifies the comma-separated list of permitted origins from user agents. The default is *, which allows everything.
apm-server.frontend.library_pattern
Differentiates library frames against specific attributes. The default value is "node_modules|bower_components|~".
apm-server.frontend.exclude_from_grouping
Configures the RegExp to be matched against a stacktrace frame’s file_name.
apm-server.frontend.rate_limit
Sets the rate limit per second per IP address for requests sent to the frontend endpoint. Defaults to 10.
apm-server.capture_personal_data
When set to true, the server captures the IP address of the instrumented service and its User Agent. Enabled by default.
max_procs
Max number of CPUs used simultaneously. Defaults to the number of logical CPUs available.
setup.template.settings.index.number_of_shards
Specifies the number of shards for the Elasticsearch template.
setup.template.settings.index.number_of_replicas
Specifies the number of replicas for the Elasticsearch template.
output.elasticsearch.bulk_max_size
Maximum number of events to bulk together in a single Elasticsearch bulk API request. By default, this number changes based on the size of the instance.
output.elasticsearch.worker
Maximum number of concurrent workers publishing events to Elasticsearch. By default, this number changes based on the size of the instance.
queue.mem.events
Maximum number of events to concurrently store in the internal queue. By default, this number changes based on the size of the instance. https://www.elastic.co/guide/en/apm/server/6.3/tune-apm-server.html#tune-output-config
queue.mem.flush.min_events
Minimum number of events to have before pushing them to Elasticsearch. By default, this number changes based on the size of the instance.
queue.mem.flush.timeout
Maximum duration before sending the events to the output if the min_events is not crossed.