-
1. Re: Global/Normalized timestamp generator
galder.zamarreno Jul 5, 2012 9:05 PM (in response to ggarciao)What about synching your machine clocks with NTP?
I don't see the need to add extra logic to keep log files synchronized. Synch the clocks instead and problem solved. No code required.
For object creation date, if the clocks are synched, you'll get a pretty good approximation with currentTimeMillis call.
-
2. Re: Global/Normalized timestamp generator
ggarciao Jul 11, 2012 3:57 AM (in response to galder.zamarreno)I strongly disagree with you ...
A cluster should have a normalized timestamps generator for many use cases.
One example
Message producer/consumer: Almost all the implementations of this kind of patterns needs a normalized timestamps to know the order of processing of the distributed queue (this means several share-nothing queues).
One real case scenario:
Transaction processor: you have several servers handling business transactions, but to be faster do you not centralize all these transaction in the same queue, but in several ones. Then you can consume those queues to really process this sorted by 'creation timestamps'.
I know there is a lot of way to do this, but timestamps are widely used in distributed environments. Please check this:
- A plugin for ActiveMQ http://activemq.apache.org/timestampplugin.html
- In Oracle Coherence you can get this normalized timestamps with CacheFactory.ensureCluster().getTimeMillis()
Dont you think that this is important enough to be added to the roadmap? Is not blocker, but I think that this is a 'must have' feature.