Skip to content

Conversation

@lifenjoiner
Copy link
Member

  1. Give time to NIC to be ready.
  2. Avoid peak request times.

1. Give time to NIC to be ready.
2. Avoid peak request times.
@jedisct1
Copy link
Member

We can probably just use clocksmith.SleepWithGranularity with a granularity larger than the default (5 seconds) instead.

@lifenjoiner
Copy link
Member Author

... uh, the difference:
clocksmith: always try to wake up in time;
sleepIncludeInertia: always try to sleep an "extra" minor duration, like "sleep in".

For cases that have hibernated beyond the app scheduled time, sleepIncludeInertia is better?
Draw a diagram and you'll get it. I'm not sure if the following is clear enough.

clocksmith:
|-------*-------+------+--------------*------------+------|
                     ^ ^                                  ^
                     1 2                                  3

sleepIncludeInertia:
|-------*-------+------+--------------*------------+------|
                     ^ ^                           ^
                     1 2                           3

1: frozen
2: wake up from hibernation, jump to 3
3: now

@lifenjoiner
Copy link
Member Author

Supplement:
The difference lies in the probability distribution of the delay.
We expect it to be as close as possible to the specified value, which is neither too large nor too small.
Devices: old Vs new;
Hibernation: very long Vs normal;
Customized sources or less servers specified.

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