Skip to content

feat(logger): GDC_LOGGING_APPENDER=CONSOLE routes splunk channel to stdout#2082

Merged
gd-ladislavandel merged 1 commit into
masterfrom
grif-233-console-appender
Jun 26, 2026
Merged

feat(logger): GDC_LOGGING_APPENDER=CONSOLE routes splunk channel to stdout#2082
gd-ladislavandel merged 1 commit into
masterfrom
grif-233-console-appender

Conversation

@gd-ladislavandel

@gd-ladislavandel gd-ladislavandel commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Summary

  • When GDC_LOGGING_APPENDER=CONSOLE is set, the brick's splunk-shaped log channel writes to STDOUT instead of constructing a RemoteSyslogLogger to NODE_NAME:514.
  • Default SYSLOG preserves the existing behavior — no regression risk for clusters that don't opt in.
  • Mirrors the appender pattern adopted by Bear webapp services in gdc-webapp-microservices#1099 so Alloy can scrape pod stdout natively into Loki, removing the host rsyslog → /mnt/log/gdc-ruby hop.

JIRA: GRIF-233

Pairs with

gooddata/msf#6503execmgr-k8s change that forwards gdc.logging.appender as the GDC_LOGGING_APPENDER env var on every brick K8s Job. Both PRs need to land for the appender to flip end-to-end.

Test plan

  • bundle exec rspec spec/unit/bricks/middleware/logger_middleware_spec.rb — green locally (13 examples, 0 failures, including 3 new ones: CONSOLE skips RemoteSyslogLogger, CONSOLE still registers splunk channel, explicit SYSLOG creates the syslog forwarder)
  • After the paired MSF PR merges and a staging cluster sets gdc.logging.appender=CONSOLE, trigger one LCM brick and confirm output appears in Loki under {sourcetype="console-log", container=~".*brick.*"} |= "action=" with the same brick=…, action=…, execution_id=… key=value body that today appears under sourcetype="ruby".

…tdout

When GDC_LOGGING_APPENDER=CONSOLE is set, the brick's splunk-shaped log
channel writes to STDOUT instead of constructing a RemoteSyslogLogger to
NODE_NAME:514. Default SYSLOG preserves the existing behavior. This
mirrors the appender pattern adopted by Bear webapp services and lets
Alloy scrape pod stdout natively (Loki-native ingestion) without going
through the host rsyslog → /mnt/log/gdc-ruby hop.

JIRA: GRIF-233

@hung-nguyen-hoang hung-nguyen-hoang left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@gd-ladislavandel gd-ladislavandel added this pull request to the merge queue Jun 26, 2026
Merged via the queue into master with commit 7ba732e Jun 26, 2026
26 of 27 checks passed
@gd-ladislavandel gd-ladislavandel deleted the grif-233-console-appender branch June 26, 2026 11:58
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