Skip to content

Commit

Permalink
chore: updated code
Browse files Browse the repository at this point in the history
  • Loading branch information
aryamohanan committed Dec 4, 2024
1 parent 575654e commit 65428b0
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/collector/src/announceCycle/unannounced.js
Original file line number Diff line number Diff line change
Expand Up @@ -225,9 +225,10 @@ function applySpanBatchingConfiguration(agentResponse) {

/**
* - The agent configuration currently uses a pipe ('|') as a separator for endpoints.
* - This function splits the string by both pipe ('|') and comma (',') to ensure compatibility.
* - This function supports both ('|') and comma (',') to ensure future compatibility.
* - Additionally, it supports the `string[]` format for backward compatibility,
* as this was the previously used standard.
* as this was the previously used standard. The final design decision is not yet completed.
* https://github.ibm.com/instana/requests-for-discussion/pull/84
*
* @param {AgentAnnounceResponse} agentResponse
*/
Expand Down
2 changes: 2 additions & 0 deletions packages/collector/test/apps/agentStubControls.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ class AgentStubControls {
env.KAFKA_TRACE_CORRELATION = opts.kafkaConfig.traceCorrelation.toString();
}
}
// This is not the INSTANA_IGNORE_ENDPOINTS env. We use this "IGNORE_ENDPOINTS" env for the fake agent to
// serve the ignore endpoints config to our tracer.
if (opts.ignoreEndpoints) {
env.IGNORE_ENDPOINTS = JSON.stringify(opts.ignoreEndpoints);
}
Expand Down
4 changes: 4 additions & 0 deletions packages/core/src/util/normalizeConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -723,5 +723,9 @@ function normalizeIgnoreEndpoints(config) {
`Failed to parse INSTANA_IGNORE_ENDPOINTS: ${process.env.INSTANA_IGNORE_ENDPOINTS}. Error: ${error.message}`
);
}
} else {
return;
}

logger.debug(`Ignore endpoints have been configured: ${JSON.stringify(config.tracing.ignoreEndpoints)}`);
}

0 comments on commit 65428b0

Please sign in to comment.