Skip to content

Added the monotonic time stamp with existing UTC - #176

Open
KonkatiBhavani wants to merge 1 commit into
developfrom
feature/Timestamp_Monotonic
Open

Added the monotonic time stamp with existing UTC#176
KonkatiBhavani wants to merge 1 commit into
developfrom
feature/Timestamp_Monotonic

Conversation

@KonkatiBhavani

Copy link
Copy Markdown

Added Monotonic timestamp

Copilot AI review requested due to automatic review settings July 14, 2026 12:10
@KonkatiBhavani
KonkatiBhavani requested review from a team as code owners July 14, 2026 12:10

Copilot AI 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.

Pull request overview

Adds a new syslog-ng template intended to enrich log lines with journald boot ID and monotonic timestamp alongside the existing UTC wall-clock timestamp, and switches generated file destinations to use that unified format.

Changes:

  • Introduces a new t_unified template-function including _BOOT_ID and __MONOTONIC_TIMESTAMP.
  • Updates generated destination file templates to use t_unified instead of t_rdk.
  • Adds generation of a fallback destination using the new unified template (but currently in a way that risks duplicate destination definitions).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 164 to +165
destination_statement = "destination d_" + line + " { file(\"`log_path`/" + destination_filter_list[0].rsplit("=", 1)[1].strip() + "\" template(\"$(t_rdk)\\n\"));};"
destination_statement = "destination d_" + line + " { file(\"`log_path`/" + destination_filter_list[0].rsplit("=", 1)[1].strip() + "\" template(\"$(t_unified)\\n\"));};"
Comment on lines 166 to 169
with open(config_file, 'a') as conf:
conf.write("%s\n" % (destination_statement))
conf.write("destination d_fallback { file(\"`log_path`/syslog_fallback.log\" template(\"$(t_unified)\\n\"));};\n")
conf.close()
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