Skip to content

Conversation

@herin049
Copy link
Contributor

@herin049 herin049 commented Dec 8, 2025

Fixes issue #2054 where platform.* telemetry API event types (except part of platform.report) do not get exported for logging. The implemented solution captures all logs by default, and simplifies the current implementation by reusing the core log record construction logic while reducing code duplication.

I have setup a toy lambda function to export logs to Grafana Cloud with the changes in this PR, here are the updated logs:
Screenshot From 2025-12-08 18-31-52

@herin049 herin049 requested a review from a team as a code owner December 8, 2025 00:19

address, err := listener.Start()
require.NoError(t, err)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The use of t.Cleanup() appeared to trigger a race condition using the race detector with zap.Logger switching to using defer appears to fix the issue.

@herin049 herin049 force-pushed the fix/report-platform-logs branch from 296c7f2 to 0c0e36a Compare December 8, 2025 20:35
Port int `mapstructure:"port"`
Types []string `mapstructure:"types"`
LogReport bool `mapstructure:"log_report"`
LogReport *bool `mapstructure:"log_report"`
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Switch to pointer to allow default value to be true

@herin049 herin049 changed the title [WIP] initial changes to export telemetry api logs [Enhancement]: Add support for exporting telemetry API 'platform.*' log events Dec 8, 2025
@herin049 herin049 changed the title [Enhancement]: Add support for exporting telemetry API 'platform.*' log events feat: Add support for exporting telemetry API 'platform.*' log events Dec 9, 2025
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.

1 participant