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

Better time handling #8

Open
nwf opened this issue Jun 30, 2019 · 2 comments
Open

Better time handling #8

nwf opened this issue Jun 30, 2019 · 2 comments

Comments

@nwf
Copy link
Member

nwf commented Jun 30, 2019

Right now, we rely on SNTP being fairly prompt and reliable. If it isn't, we'll start off life with a timestamp of zero (and publish that in our heartbeats) and that doesn't seem like it's going to work out well. We should probably subscribe to timesync messages and either check against SNTP or use them as a fallback if we haven't heard otherwise.

@timparenti
Copy link
Member

I like the idea of using the timesync messages as a fallback until we've heard from SNTP. Is there a straightforward way for the devices to indicate back to the server which time source they're currently using?

@nwf
Copy link
Member Author

nwf commented Jun 30, 2019

We've never seen SNTP fail to synchronize within a second or two of getting an IP address; the devices hit the CMU NTP server. But, that said, we can certainly add a field to the heartbeat messages to tell us the time source or deviance of local clock at the last timesync message we saw.

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

No branches or pull requests

2 participants