February 2020
Intermediate to advanced
734 pages
38h 13m
English
As we've already seen, the values produced by timeshard sequences may not be desirable. In some cases, frontend languages may not even be compatible. JavaScript, for example, is not compatible with such large values by default. So what can we do instead?
Another valid setting for the bdr.default_sequence_kind parameter is galloc, for global allocation. Rather than arbitrarily producing large values, each node actually requests a range of values from the consensus layer. Once this range is exhausted, the node obtains another, and so on.
This approach may result in more latency on each sequence range boundary, but is otherwise compatible with more common INTEGER and SERIAL types. Look at the following SQL:
SET bdr.default_sequence_kind ...
Read now
Unlock full access