Skip to content

feat: create O11yReporter with getOrgConnection function when event has target org username @W-21306700#835

Merged
shetzel merged 4 commits intomainfrom
sh/send-connection-to-o11y
Feb 24, 2026
Merged

feat: create O11yReporter with getOrgConnection function when event has target org username @W-21306700#835
shetzel merged 4 commits intomainfrom
sh/send-connection-to-o11y

Conversation

@shetzel
Copy link
Contributor

@shetzel shetzel commented Feb 19, 2026

create O11yReporter with getOrgConnection function when event has target org username so that PDP events are sent to the org's o11y endpoint.

Also, the o11y reporter that sends PDP events no longer batches since the 30 second interval would prevent node processes from exiting in short lived processes such as the CLI telemetry uploader.

Should address these issues:
forcedotcom/cli#3505
forcedotcom/cli#3506

@W-21306700@

NOTE: This requires forcedotcom/telemetry#476

const eventName = asString(event.eventName) ?? 'UNKNOWN';
const enableO11y = asBoolean(event.enableO11y) ?? false;
const productFeatureId = asString(event.productFeatureId) ?? 'aJCEE0000000mHP4AY';
const targetOrgUsername = asString(event.targetOrgUsername) ?? undefined;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you need them to eventually be string|undefined,

I'd use string? and undefined un the commandExecution stuff (instead of null) just to save some steps

@shetzel shetzel merged commit 327ac7a into main Feb 24, 2026
15 checks passed
@shetzel shetzel deleted the sh/send-connection-to-o11y branch February 24, 2026 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants