Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ See the <<upgrade-to-v4>> guide.
These two properties were deprecated in v3.25.0.
({issues}3557[#3557])

* Remove support for the erroneous `ELASTIC_SANITIZE_FIELD_NAMES` and
`ELASTIC_IGNORE_MESSAGE_QUEUES` config environment variables. The correct env
vars are `ELASTIC_APM_SANITIZE_FIELD_NAMES` and
`ELASTIC_APM_IGNORE_MESSAGE_QUEUES`, respectively, and were supported starting
in v3.36.0.

[float]
===== Features

Expand Down
8 changes: 8 additions & 0 deletions docs/upgrade-to-v4.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,14 @@ default. In v4, printing the error to stderr is done by default (to mimic the
default Node.js uncaught exception behavior) and there is no option to disable
that.

===== `ELASTIC_SANITIZE_FIELD_NAMES`, `ELASTIC_IGNORE_MESSAGE_QUEUES`

Support for the erroneous `ELASTIC_SANITIZE_FIELD_NAMES` and
`ELASTIC_IGNORE_MESSAGE_QUEUES` config environment variables has been removed.
The correct env vars are `ELASTIC_APM_SANITIZE_FIELD_NAMES` and
`ELASTIC_APM_IGNORE_MESSAGE_QUEUES`, respectively, and were supported starting
in v3.36.0.


[[v4-api-changes]]
==== API changes
Expand Down
10 changes: 2 additions & 8 deletions lib/config/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,7 @@ const ENV_TABLE = {
disableSend: 'ELASTIC_APM_DISABLE_SEND',
environment: 'ELASTIC_APM_ENVIRONMENT',
exitSpanMinDuration: 'ELASTIC_APM_EXIT_SPAN_MIN_DURATION',
ignoreMessageQueues: [
'ELASTIC_IGNORE_MESSAGE_QUEUES',
'ELASTIC_APM_IGNORE_MESSAGE_QUEUES',
],
ignoreMessageQueues: 'ELASTIC_APM_IGNORE_MESSAGE_QUEUES',
elasticsearchCaptureBodyUrls: 'ELASTIC_APM_ELASTICSEARCH_CAPTURE_BODY_URLS',
errorMessageMaxLength: 'ELASTIC_APM_ERROR_MESSAGE_MAX_LENGTH',
errorOnAbortedRequests: 'ELASTIC_APM_ERROR_ON_ABORTED_REQUESTS',
Expand All @@ -171,10 +168,7 @@ const ENV_TABLE = {
metricsLimit: 'ELASTIC_APM_METRICS_LIMIT',
opentelemetryBridgeEnabled: 'ELASTIC_APM_OPENTELEMETRY_BRIDGE_ENABLED',
payloadLogFile: 'ELASTIC_APM_PAYLOAD_LOG_FILE',
sanitizeFieldNames: [
'ELASTIC_SANITIZE_FIELD_NAMES',
'ELASTIC_APM_SANITIZE_FIELD_NAMES',
],
sanitizeFieldNames: 'ELASTIC_APM_SANITIZE_FIELD_NAMES',
serverCaCertFile: 'ELASTIC_APM_SERVER_CA_CERT_FILE',
secretToken: 'ELASTIC_APM_SECRET_TOKEN',
serverTimeout: 'ELASTIC_APM_SERVER_TIMEOUT',
Expand Down
6 changes: 1 addition & 5 deletions test/config.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1757,7 +1757,7 @@ test('should accept and normalize ignoreMessageQueues', function (suite) {

suite.test('ignoreMessageQueues via env', function (t) {
const agent = new Agent();
process.env.ELASTIC_IGNORE_MESSAGE_QUEUES = 'f*o,bar,baz';
process.env.ELASTIC_APM_IGNORE_MESSAGE_QUEUES = 'f*o,bar,baz';
agent.start(agentOptsNoopTransport);
t.equals(
agent._conf.ignoreMessageQueues.length,
Expand Down Expand Up @@ -2060,10 +2060,6 @@ test('env variable names start with "ELASTIC_APM_" prefix', (t) => {
'KUBERNETES_NODE_NAME',
'KUBERNETES_POD_NAME',
'KUBERNETES_POD_UID',
// These are for backward compatibility -- they were accidentally added
// with the wrong prefix.
'ELASTIC_SANITIZE_FIELD_NAMES',
'ELASTIC_IGNORE_MESSAGE_QUEUES',
];
for (const name of names) {
if (exclusions.indexOf(name) !== -1) {
Expand Down