clock-synchronization

Is there an off-the-shelf clock synchronization solution for Java?

人走茶凉 提交于 2019-12-22 04:18:27
问题 We have a large high-performance software system which consists of multiple interacting Java processes (not EJBs). Each process can be on the same machine or on a different machine. Certain events are generated in one process, and are then propagated in different ways to other processes for further processing and so on. For benchmarking purposes, we need to create a log of when each event passed through a "checkpoint", eventually combine these logs to obtain a timeline of how each event

Clock on webpage using server and system time?

空扰寡人 提交于 2019-12-18 15:09:21
问题 I need to add a clock to a web page. The clock needs to be synchronized with a server but I really don't want to have it constantly check the server as the page will be open 24/7 on several PCs. Is there some way to get the time from the server and then use the systems clock to keep it updated and check the server every 15 minutes or so to keep it synced? 回答1: The way I've gone about this before is: Take the time from the server, Take the time from the client (immediately) Get an offset. When

Is there an off-the-shelf clock synchronization solution for Java?

折月煮酒 提交于 2019-12-05 04:01:38
We have a large high-performance software system which consists of multiple interacting Java processes (not EJBs). Each process can be on the same machine or on a different machine. Certain events are generated in one process, and are then propagated in different ways to other processes for further processing and so on. For benchmarking purposes, we need to create a log of when each event passed through a "checkpoint", eventually combine these logs to obtain a timeline of how each event propagated through the system and with what latency (of course, process switching and IPC adds latency,

How do I establish clock synchronization in the cloud (AWS, heroku, etc) across many nodes?

让人想犯罪 __ 提交于 2019-12-03 16:58:21
问题 I would like to run a large cluster of nodes in the cloud (AWS, Heroku, or maybe self-manged VMS), whose clocks must be synchronized with a predefined tolerance in mind. I'm looking for a tolerance of maybe 200 ms. That means if I have 250 nodes, the largest clock difference between any of the 250 nodes should never exceed 200 ms. I don't really care about the actual date / time with respect to the world. The solution has to be fault tolerant, and should not need to rely on the accuracy of

Clock on webpage using server and system time?

痴心易碎 提交于 2019-11-30 12:01:56
I need to add a clock to a web page. The clock needs to be synchronized with a server but I really don't want to have it constantly check the server as the page will be open 24/7 on several PCs. Is there some way to get the time from the server and then use the systems clock to keep it updated and check the server every 15 minutes or so to keep it synced? The way I've gone about this before is: Take the time from the server, Take the time from the client (immediately) Get an offset. When showing the clock, apply the offset to the current time on the client. You only need to update this

The best way to synchronize client-side javascript clock with server date

孤街醉人 提交于 2019-11-26 12:44:40
I have a task to show digital clock (with minutes precision) on HTML page in some fixed timezone (MSK or MSD - depending on current date). I'd like to avoid relying on client system clock, so some synchronization with server is required. HTTP server sends Date header in each response so we can send an AJAX GET or HEAD request to any URL of our site to get server date, calculate the difference with client date and use it when updating clock with setTimeout(). There are other issues remains: timezone switching for daylight settings, latency accounting for very slow connections. Any idea to this

The best way to synchronize client-side javascript clock with server date

情到浓时终转凉″ 提交于 2019-11-26 03:04:19
问题 I have a task to show digital clock (with minutes precision) on HTML page in some fixed timezone (MSK or MSD - depending on current date). I\'d like to avoid relying on client system clock, so some synchronization with server is required. HTTP server sends Date header in each response so we can send an AJAX GET or HEAD request to any URL of our site to get server date, calculate the difference with client date and use it when updating clock with setTimeout(). There are other issues remains: