@nxtedition/rocksdb 12.2.12 → 13.0.0
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
|
@@ -915,6 +915,9 @@ napi_status InitOptions(napi_env env, T& columnOptions, const U& options) {
|
|
|
915
915
|
tableOptions.filter_policy.reset(rocksdb::NewBloomFilterPolicy(10));
|
|
916
916
|
}
|
|
917
917
|
|
|
918
|
+
tableOptions.enable_index_compression = false;
|
|
919
|
+
NAPI_STATUS_RETURN(GetProperty(env, options, "enableIndexCompression", tableOptions.enable_index_compression));
|
|
920
|
+
|
|
918
921
|
std::optional<std::string> filterPolicyOpt;
|
|
919
922
|
NAPI_STATUS_RETURN(GetProperty(env, options, "filterPolicy", filterPolicyOpt));
|
|
920
923
|
if (filterPolicyOpt) {
|
|
@@ -934,6 +937,12 @@ napi_status InitOptions(napi_env env, T& columnOptions, const U& options) {
|
|
|
934
937
|
tableOptions.optimize_filters_for_memory = true;
|
|
935
938
|
NAPI_STATUS_RETURN(GetProperty(env, options, "optimizeFiltersForMemory", tableOptions.optimize_filters_for_memory));
|
|
936
939
|
|
|
940
|
+
tableOptions.enable_index_compression = false;
|
|
941
|
+
NAPI_STATUS_RETURN(GetProperty(env, options, "enableIndexCompression", tableOptions.enable_index_compression));
|
|
942
|
+
|
|
943
|
+
tableOptions.max_auto_readahead_size = 256 * 1024;
|
|
944
|
+
NAPI_STATUS_RETURN(GetProperty(env, options, "maxAutoReadaheadSize", tableOptions.max_auto_readahead_size));
|
|
945
|
+
|
|
937
946
|
columnOptions.table_factory.reset(rocksdb::NewBlockBasedTableFactory(tableOptions));
|
|
938
947
|
|
|
939
948
|
return napi_ok;
|
|
@@ -996,13 +1005,42 @@ NAPI_METHOD(db_open) {
|
|
|
996
1005
|
walCompression ? rocksdb::CompressionType::kZSTD : rocksdb::CompressionType::kNoCompression;
|
|
997
1006
|
|
|
998
1007
|
dbOptions.avoid_unnecessary_blocking_io = true;
|
|
1008
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "avoidUnnecessaryBlockingIO", dbOptions.avoid_unnecessary_blocking_io));
|
|
1009
|
+
|
|
999
1010
|
dbOptions.write_dbid_to_manifest = true;
|
|
1011
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "writeDbIdToManifest", dbOptions.write_dbid_to_manifest));
|
|
1012
|
+
|
|
1000
1013
|
dbOptions.create_missing_column_families = true;
|
|
1014
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "createMissingColumnFamilies", dbOptions.create_missing_column_families));
|
|
1015
|
+
|
|
1001
1016
|
dbOptions.fail_if_options_file_error = true;
|
|
1017
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "failIfOptionsFileError", dbOptions.fail_if_options_file_error));
|
|
1018
|
+
|
|
1019
|
+
dbOptions.advise_random_on_open = true;
|
|
1020
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "adviseRandomOnOpen", dbOptions.advise_random_on_open));
|
|
1002
1021
|
|
|
1022
|
+
dbOptions.optimize_filters_for_hits = false;
|
|
1023
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "optimizeFiltersForHits", dbOptions.optimize_filters_for_hits));
|
|
1024
|
+
|
|
1025
|
+
dbOptions.bytes_per_sync = 1024 * 1024;
|
|
1026
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "bytesPerSync", dbOptions.bytes_per_sync));
|
|
1027
|
+
|
|
1028
|
+
dbOptions.wal_bytes_per_sync = 1024 * 1024;
|
|
1029
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "walBytesPerSync", dbOptions.wal_bytes_per_sync));
|
|
1030
|
+
|
|
1031
|
+
dbOptions.strict_bytes_per_sync = true;
|
|
1032
|
+
NAPI_STATUS_THROWS(GetProperty(env, options, "strictBytesPerSync", dbOptions.strict_bytes_per_sync));
|
|
1033
|
+
|
|
1034
|
+
dbOptions.create_if_missing = false;
|
|
1003
1035
|
NAPI_STATUS_THROWS(GetProperty(env, options, "createIfMissing", dbOptions.create_if_missing));
|
|
1036
|
+
|
|
1037
|
+
dbOptions.enable_pipelined_write = false;
|
|
1004
1038
|
NAPI_STATUS_THROWS(GetProperty(env, options, "errorIfExists", dbOptions.error_if_exists));
|
|
1039
|
+
|
|
1040
|
+
dbOptions.enable_pipelined_write = true;
|
|
1005
1041
|
NAPI_STATUS_THROWS(GetProperty(env, options, "pipelinedWrite", dbOptions.enable_pipelined_write));
|
|
1042
|
+
|
|
1043
|
+
dbOptions.daily_offpeak_time_utc = "";
|
|
1006
1044
|
NAPI_STATUS_THROWS(GetProperty(env, options, "dailyOffpeakTime", dbOptions.daily_offpeak_time_utc));
|
|
1007
1045
|
|
|
1008
1046
|
// TODO (feat): dbOptions.listeners
|
package/deps/rocksdb/rocksdb.gyp
CHANGED
|
@@ -93,10 +93,10 @@
|
|
|
93
93
|
"USE_COROUTINES=1",
|
|
94
94
|
"HAVE_UINT128_EXTENSION=1",
|
|
95
95
|
"HAVE_ALIGNED_NEW=1",
|
|
96
|
-
|
|
96
|
+
"ROCKSDB_JEMALLOC=1",
|
|
97
|
+
"JEMALLOC_NO_DEMANGLE=1"
|
|
97
98
|
# "HAVE_FULLFSYNC=1",
|
|
98
99
|
# "NUMA=1",
|
|
99
|
-
# "JEMALLOC_NO_DEMANGLE=1",
|
|
100
100
|
],
|
|
101
101
|
"direct_dependent_settings": {
|
|
102
102
|
"libraries": [
|
|
@@ -108,7 +108,7 @@
|
|
|
108
108
|
"/usr/lib/x86_64-linux-gnu/libiberty.a",
|
|
109
109
|
"/usr/lib/x86_64-linux-gnu/libunwind.a",
|
|
110
110
|
"/usr/lib/x86_64-linux-gnu/libgflags.a",
|
|
111
|
-
|
|
111
|
+
"/usr/lib/x86_64-linux-gnu/libjemalloc.a"
|
|
112
112
|
],
|
|
113
113
|
},
|
|
114
114
|
"include_dirs": [
|
package/package.json
CHANGED
|
Binary file
|
|
Binary file
|