Related: #92337. When tracing REST requests with APM, we capture HTTP headers as labels on the trace, but redact sensitive values. However, we can't know ahead of time what are all possible sensitive values. It would be better if it was possible to configure additional patterns to redact.
modules/apm/src/main/java/org/elasticsearch/tracing/apm/APMTracer.java
}
    public void setNodeName(String nodeName) {
        this.nodeName = nodeName;
    }
    /**
     * This class is used to make all OpenTelemetry services visible at once
     */
    record APMServices(Tracer tracer, OpenTelemetry openTelemetry) {}
    public APMTracer(Settings settings) {
        this.includeNames = APM_TRACING_NAMES_INCLUDE_SETTING.get(settings);
        this.excludeNames = APM_TRACING_NAMES_EXCLUDE_SETTING.get(settings);
        this.filterAutomaton = buildAutomaton(includeNames, excludeNames);
        this.enabled = APM_ENABLED_SETTING.get(settings);
    }
    void setEnabled(boolean enabled) {
        this.enabled = enabled;
        if (enabled) {
            this.services = createApmServices();
        } else {
            destroyApmServices();
        }
    }
    void setIncludeNames(List<String> includeNames) {
        this.includeNames = includeNames;
        this.filterAutomaton = buildAutomaton(includeNames, excludeNames);
    }
    void setExcludeNames(List<String> excludeNames) {
        this.excludeNames = excludeNames;
        this.filterAutomaton = buildAutomaton(includeNames, excludeNames);
    }