elasticsearch/qa
Rory Hunter 512bfebc10
Provide tracing implementation using OpenTelemetry + APM agent (#88443)
Part of #84369. Implement the `Tracer` interface by providing a
module that uses OpenTelemetry, along with Elastic's APM
agent for Java.

See the file `TRACING.md` for background on the changes and the
reasoning for some of the implementation decisions.

The configuration mechanism is the most fiddly part of this PR. The
Security Manager permissions required by the APM Java agent make
it prohibitive to start an agent from within Elasticsearch
programmatically, so it must be configured when the ES JVM starts.
That means that the startup CLI needs to assemble the required JVM
options.

To complicate matters further, the APM agent needs a secret token
in order to ship traces to the APM server. We can't use Java system
properties to configure this, since otherwise the secret will be
readable to all code in Elasticsearch. It therefore has to be
configured in a dedicated config file. This in itself is awkward,
since we don't want to leave secrets in config files. Therefore,
we pull the APM secret token from the keystore, write it to a config
file, then delete the config file after ES starts.

There's a further issue with the config file. Any options we set
in the APM agent config file cannot later be reconfigured via system
properties, so we need to make sure that only "static" configuration
goes into the config file.

I generated most of the files under `qa/apm` using an APM test
utility (I can't remember which one now, unfortunately). The goal
is to setup up a complete system so that traces can be captured in
APM server, and the results in Elasticsearch inspected.
2022-08-03 14:13:31 +01:00
..
apm Provide tracing implementation using OpenTelemetry + APM agent (#88443) 2022-08-03 14:13:31 +01:00
ccs-common-rest Move kNN search and dense vectors to core (#87815) 2022-06-22 21:10:20 -07:00
ccs-rolling-upgrade-remote-cluster Remove calls to deprecated xcontent method (#84733) 2022-08-01 22:18:03 +09:30
ccs-unavailable-clusters Port QA projects to use javaRestTest and yamlRestTest (#86703) 2022-05-12 11:32:07 +02:00
evil-tests Add package cache to EmbeddedImplClassLoader (#88537) 2022-07-25 15:31:58 +01:00
full-cluster-restart Clean up request/response for get-cluster-settings (#86347) 2022-05-02 11:21:34 -04:00
logging-config Revert "Deprecation dataset value changed to elasticsearch.deprecation (#83254)" (#87837) 2022-06-20 14:02:34 +02:00
mixed-cluster Move yaml rest test case to separate test lib (#84835) 2022-03-11 10:51:11 -05:00
multi-cluster-search [Tests] Enhance multi cluster search test skipping (#85566) 2022-04-20 17:54:42 +02:00
no-bootstrap-tests Add support for reading stable plugin descriptors (#88731) 2022-07-26 10:28:24 +09:30
os Pull alpine image in a retry in Docker tests (#88654) 2022-07-25 09:41:17 +01:00
remote-clusters Move io utils to core package (#85954) 2022-04-19 21:26:28 -07:00
repository-multi-version Remove calls to deprecated xcontent method (#84733) 2022-08-01 22:18:03 +09:30
rolling-upgrade Add 'mode' option to _source field mapper (#88211) 2022-07-18 12:50:10 +01:00
smoke-test-http Remove calls to deprecated xcontent method (#84733) 2022-08-01 22:18:03 +09:30
smoke-test-ingest-disabled Port QA projects to use javaRestTest and yamlRestTest (#86703) 2022-05-12 11:32:07 +02:00
smoke-test-ingest-with-all-dependencies Rework testing conventions gradle plugin (#87213) 2022-06-20 16:26:38 +02:00
smoke-test-multinode Port QA projects to use javaRestTest and yamlRestTest (#86703) 2022-05-12 11:32:07 +02:00
smoke-test-plugins Move the ingest attachment processor to the default distribution (#87989) 2022-06-28 02:10:36 -04:00
system-indices Use origin for the client when running _features/_reset (#88622) 2022-07-22 10:20:06 -04:00
unconfigured-node-name Port QA projects to use javaRestTest and yamlRestTest (#86703) 2022-05-12 11:32:07 +02:00
verify-version-constants Default hashing algo setting refactor (#86146) 2022-04-26 09:01:30 -04:00
build.gradle Do not create unused testCluster (#77581) 2021-09-23 03:45:59 -04:00