Обсуждение: pgsql: Measure Bloom index signature-length reloption in bits, not word

Поиск
Список
Период
Сортировка

pgsql: Measure Bloom index signature-length reloption in bits, not word

От
Tom Lane
Дата:
Measure Bloom index signature-length reloption in bits, not words.

Per discussion, this is a more understandable and future-proof way of
exposing the setting to users.  On-disk, we can still store it in words,
so as to not break on-disk compatibility with beta1.

Along the way, clean up the code associated with Bloom reloptions.
Provide explicit macros for default and maximum lengths rather than
having magic numbers buried in multiple places in the code.  Drop
the adjustBloomOptions() code altogether: it was useless in view of
the fact that reloptions.c already performed default-substitution and
range checking for the options.  Rename a couple of macros and types
for more clarity.

Discussion: <23767.1464926580@sss.pgh.pa.us>

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/ee4af347ba89b8492d1f86b6456865e1de1d030f

Modified Files
--------------
contrib/bloom/bloom.h   |  33 ++++++++-----
contrib/bloom/blscan.c  |   2 +-
contrib/bloom/blutils.c | 125 ++++++++++++++++++++----------------------------
doc/src/sgml/bloom.sgml |  19 ++++----
4 files changed, 86 insertions(+), 93 deletions(-)