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

Fixes #36841 - Switch to Process.clock_gettime for ping #9868

Merged
merged 1 commit into from
Oct 19, 2023

Conversation

ehelms
Copy link
Member

@ehelms ehelms commented Oct 18, 2023

No description provided.

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

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

Don't you also need to change duration_ms itself?

@ekohl
Copy link
Member

ekohl commented Oct 18, 2023

For those following along, quoting man clock_gettime:

CLOCK_MONOTONIC
A nonsettable system-wide clock that represents monotonic time since—as described by POSIX—"some unspecified point in the past". On Linux, that point corresponds to the num‐ ber of seconds that the system has been running since it was booted.

The CLOCK_MONOTONIC clock is not affected by discontinuous jumps in the system time (e.g., if the system administrator manually changes the clock), but is affected by the incremental adjustments performed by adjtime(3) and NTP. This clock does not count time that the system is suspended. All CLOCK_MONOTONIC variants guarantee that the time re‐ turned by consecutive calls will not go backwards, but successive calls may—depending on the architecture—return identical (not-increased) time values.

app/services/ping.rb Outdated Show resolved Hide resolved
@ehelms
Copy link
Member Author

ehelms commented Oct 19, 2023

[test katello]

@ehelms ehelms merged commit 66f0c87 into theforeman:develop Oct 19, 2023
9 checks passed
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