Set the tunables to the 'default' values on create.
Default to the legacy values when we decode, so that an old map without
values defined gets legacy values.
Signed-off-by: Sage Weil <sage@inktank.com>
::decode(crush->max_rules, blp);
::decode(crush->max_devices, blp);
+ // legacy tunables, unless we decode something newer
+ set_tunables_legacy();
+
try {
// buckets
crush->buckets = (crush_bucket**)calloc(1, crush->max_buckets * sizeof(crush_bucket*));
crush = crush_create();
assert(crush);
have_rmaps = false;
+
+ set_tunables_default();
}
// tunables