@nxtedition/rocksdb 12.0.6 → 12.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/binding.cc CHANGED
@@ -798,9 +798,10 @@ napi_status InitOptions(napi_env env, T& columnOptions, const U& options) {
798
798
 
799
799
  NAPI_STATUS_RETURN(GetProperty(env, options, "blockRestartInterval", tableOptions.block_restart_interval));
800
800
 
801
- tableOptions.format_version = 5;
802
801
  tableOptions.checksum = rocksdb::kXXH3;
802
+
803
803
  tableOptions.decouple_partitioned_filters = true;
804
+ NAPI_STATUS_RETURN(GetProperty(env, options, "decouplePartitionedFilters", tableOptions.block_restart_interval));
804
805
 
805
806
  tableOptions.optimize_filters_for_memory = true;
806
807
  NAPI_STATUS_RETURN(GetProperty(env, options, "optimizeFiltersForMemory", tableOptions.optimize_filters_for_memory));
@@ -1020,9 +1021,12 @@ NAPI_METHOD(db_get_many_sync) {
1020
1021
  int32_t highWaterMarkBytes = std::numeric_limits<int32_t>::max();
1021
1022
  NAPI_STATUS_THROWS(GetProperty(env, argv[2], "highWaterMarkBytes", highWaterMarkBytes));
1022
1023
 
1023
- std::vector<rocksdb::Slice> keys{count};
1024
- std::vector<rocksdb::Status> statuses{count};
1025
- std::vector<rocksdb::PinnableSlice> values{count};
1024
+ std::vector<rocksdb::Slice> keys;
1025
+ keys.resize(count);
1026
+ std::vector<rocksdb::Status> statuses;
1027
+ statuses.resize(count);
1028
+ std::vector<rocksdb::PinnableSlice> values;
1029
+ values.resize(count);
1026
1030
 
1027
1031
  for (uint32_t n = 0; n < count; n++) {
1028
1032
  napi_value element;
@@ -1103,9 +1107,10 @@ NAPI_METHOD(db_get_many) {
1103
1107
  readOptions.optimize_multiget_for_io = true;
1104
1108
  readOptions.value_size_soft_limit = highWaterMarkBytes;
1105
1109
 
1106
- std::vector<rocksdb::Slice> keys{count};
1110
+ std::vector<rocksdb::Slice> keys;
1111
+ keys.reserve(count);
1107
1112
  for (uint32_t n = 0; n < count; n++) {
1108
- keys[n] = state.keys[n];
1113
+ keys.emplace_back(state.keys[n]);
1109
1114
  }
1110
1115
 
1111
1116
  state.statuses.resize(count);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nxtedition/rocksdb",
3
- "version": "12.0.6",
3
+ "version": "12.0.8",
4
4
  "description": "A low-level Node.js RocksDB binding",
5
5
  "license": "MIT",
6
6
  "main": "index.js",