Skip to content

gcp: Send structured fioserver logs to Cloud Logging - #307

Merged
doanac merged 2 commits into
mainfrom
gcp-logging-fix
Oct 21, 2026
Merged

doanac merged 2 commits into
mainfrom
gcp-logging-fix

Conversation

@doanac

@doanac doanac commented Oct 15, 2026

Copy link
Copy Markdown
Member

fioserver emits JSON log lines, but the journald receiver delivered each one as an opaque MESSAGE string, so its fields could not be queried. Parse it into jsonPayload, map slog's level onto the entry severity, and drop journald metadata that is constant or duplicated by the resource labels.

fioserver emits JSON log lines, but the journald receiver delivered
each one as an opaque MESSAGE string, so its fields could not be
queried. Parse it into jsonPayload, map slog's level onto the entry
severity, and drop journald metadata that is constant or duplicated
by the resource labels.

Signed-off-by: Andy Doan <doanac@qti.qualcomm.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@doanac
doanac requested a review from StealthyCoder October 15, 2026 20:52
@doanac

doanac commented Oct 15, 2026

Copy link
Copy Markdown
Member Author

@StealthyCoder - i have confirmed and tested against my GCP deployment. Could you test this against your AWS deployment?

The CloudWatch agent's journald collector wraps each journal entry as
{"body": {"MESSAGE": ..., <journal fields>}}, leaving fioserver's JSON
line as an escaped string that Logs Insights cannot query. The agent
offers no way to reshape these events, so a log group transformer
lifts the fioserver fields to the top level and drops the journal
metadata.

aws_cloudwatch_log_transformer first appeared in provider 6.25, so
the pin moves to 6.x, along with the region attribute 6.0 renamed.

Signed-off-by: Andy Doan <doanac@qti.qualcomm.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@doanac
doanac merged commit 5f76ef4 into main Oct 21, 2026
20 of 22 checks passed
@doanac
doanac deleted the gcp-logging-fix branch October 21, 2026 17:50
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