Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

journal: several timestamp cleanups and improvements #32592

Merged
merged 5 commits into from
May 2, 2024

Commits on May 1, 2024

  1. journald-audit: set _SOURCE_REALTIME_TIMESTAMP= field in server_dispa…

    …tch_message()
    
    No functional change, just refactoring.
    yuwata committed May 1, 2024
    Configuration menu
    Copy the full SHA
    3cd7783 View commit details
    Browse the repository at this point in the history
  2. journal: use STRLEN() and xsprintf()

    No functional change, just refactoring.
    yuwata committed May 1, 2024
    Configuration menu
    Copy the full SHA
    fbecb1f View commit details
    Browse the repository at this point in the history
  3. sd-journal: verify monotonic timestamp before assigning result

    Previously, ret_boot_id was assigned even when the function failed due
    to an invalid monotonic timestamp stored for a journal entry.
    yuwata committed May 1, 2024
    Configuration menu
    Copy the full SHA
    c9df471 View commit details
    Browse the repository at this point in the history
  4. logs-show: make output_timestamp_realtime() only take realtime timestamp

    No functional change, just refactoring and preparation for later
    commits.
    yuwata committed May 1, 2024
    Configuration menu
    Copy the full SHA
    6ed286d View commit details
    Browse the repository at this point in the history
  5. logs-show: adjust source timestamp with header timestamp

    Previously, _SOURCE_REALTIME_TIMESTAMP was only used for realtime
    timestamp, and _SOURCE_MONOTONIC_TIMESTAMP was for monotonic.
    
    This make these journal field used more aggressively. If we need
    realtime timestamp, but an entry has only _SOURCE_MONOTONIC_TIMESTAMP,
    then now realtime timestamp is calculated based on
    _SOURCE_MONOTONIC_TIMESTAMP and the header dual timestamp.
    Similary, monotonic timestamp is obtained from
    _SOURCE_REALTIME_TIMESTAMP and the header dual timestamp.
    
    This should change shown timestamps not so much in most cases, but may
    be improve the situation such as systemd#32492.
    yuwata committed May 1, 2024
    Configuration menu
    Copy the full SHA
    affde1d View commit details
    Browse the repository at this point in the history