tdrd
Joined 14 years ago
Joined 14 years ago
Nothing to see here.
Sadly, those benchmarks (at the bottom of the thread) were done with a GCC that already included all the GCC 8.1 bells and whistles - results were unchanged under 8.1.
So it's still _really_ slow.
Here's how we did it in CockroachDB: https://github.com/cockroachdb/cockroach/blob/24ed8df04719a1...
The supporting code (protoutil) is https://godoc.org/github.com/cockroachdb/cockroach/pkg/util/... and https://godoc.org/github.com/cockroachdb/cockroach/pkg/util/....
Have you suggested this to the etcd maintainers?
Looks like it doesn't deal with subshells, but otherwise it did reasonably well.
http://explainshell.com/explain?cmd=find+.+-name+*.pb.cc+%7C...
In addition to being extremely precise, TrueTime is explicit about error in its measurements.
In other words, a call to TrueTime returns a lower and upper bound for the current time, which is important for systems like Spanner or CockroachDB when operations must be linearized.
In effect, Spanner sleeps on each operation for a duration of [latest_upper_bound - current_lower_bound] to ensure that operations are strictly ordered.
Your suggestion might improve typical clock synchronization, but still leaves defining the critical offset threshold to the operator, and importantly leaves little choice for software like CockroachDB other than to crash when it detects that the invariant is violated.
Have they documented the wire protocol? I couldn't find it.
https://github.com/cockroachdb/cockroach/blob/6b0698f/pkg/ut...
CockroachDB[1] has been using it since very early in the project.
[0] https://reviewable.io/
[1] https://github.com/cockroachdb/cockroach