Is time synchronization between multiple speakers on Heroku?

Is there any article about how synchronized are the times on multiple speakers in heroku and how reliable are they?

I am running a node.js application on Heroku and need to know if the time I get using Date.now() or new Date() synchronized across multiple speakers?

  • Using the cluster module, it seems that all processes running on the same dynoder have the same time. Do they use local machine time or a clock server?
  • I tested two speakers in one application to print a timestamp as soon as they start, and it looks like they have the same time. Is it reliable?
  • I have not tested using speakers in different applications. Perhaps they have the same time or in a reliable range of differences?

In addition, I mean a time difference of less than 1000 ms, which may be due to insignificant break times of the process.

+6
source share
2 answers

I don’t think so, and I don’t think it is reliable.

Message How to set clock synchronization in the cloud (AWS, heroku, etc.) on many nodes? there is good general information both in the question and in the answer about NTP, virtual machines and the cloud.

+1
source

It's a bit late, but YES, Heroku's speakers are in sync.

Screenshot from support ticket: Ticket support

NTP is also very accurate, and 1000ms are definitely in the NTP range.

0
source

Source: https://habr.com/ru/post/976583/


All Articles