Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
7a09edb
string_util.cc: NumberToHumanString/BytesToHumanString: Fixed width
rockeet Mar 15, 2026
6735b70
internal_stats.cc: DumpDBStats() pretty align
rockeet Mar 15, 2026
943717b
update submodule rockside
rockeet Mar 15, 2026
345d747
Makefile: install topling site and db_bench_enterprise.yaml
rockeet Mar 18, 2026
5fcbac6
README: Add toplingdb sdk trial version with ToplingZipTable
rockeet Mar 18, 2026
2474da9
Makefile: bugfix: del '/' in $(DESTDIR)/$(PREFIX)
rockeet Mar 18, 2026
68fbc5f
Add build*.sh
rockeet Mar 18, 2026
4a689cb
update submodule rockside
rockeet Mar 18, 2026
89e4a4a
Makefile: install-shared & install-dcompact respect var STRIP_DEBUG_INFO
rockeet Mar 19, 2026
1aa07fa
Update build-min-dep-jni.sh
rockeet Mar 19, 2026
ec99b75
update submodule rockside
rockeet Mar 19, 2026
bcd74b3
Makefile: WITH_TOPLING_ROCKS pre-fix for trial
rockeet Mar 20, 2026
650d307
Makefile: let USE_LTO take effect only on DEBUG_LEVEL=0
rockeet Mar 20, 2026
7824afd
Fix build-min-dep-jni.sh
rockeet Mar 20, 2026
d847626
Makefile: trial obj
rockeet Mar 20, 2026
355304b
Update build-trial.sh
rockeet Mar 20, 2026
9d4d7a7
add btest-trial.sh
rockeet Mar 20, 2026
ea724e4
README: update quotes for quick start
rockeet Mar 20, 2026
0892907
README: contact us on compile
rockeet Mar 20, 2026
eafb8dc
Makefile: rpath: add '$ORIGIN/../lib'
rockeet Mar 21, 2026
4d7df6b
build-trial.sh: clean package dir before make
rockeet Mar 21, 2026
6919542
db_bench.sh: comment out -value_size to use default
rockeet Mar 21, 2026
d0b54a7
Makefile: set DEBUG_LEVEL?=2
rockeet Mar 21, 2026
cb95981
update submodule rockside
rockeet Mar 21, 2026
865e26d
update submodule rockside: improve page refresh
rockeet Mar 22, 2026
903594a
update build-trial.sh
rockeet Mar 22, 2026
3319b95
Makefile: check topling-rocks top_patent_algo.cc
rockeet Mar 24, 2026
2d56294
Update README
rockeet Mar 24, 2026
425c95a
Minor fix
rockeet Mar 26, 2026
98c5d8b
merging_iterator.cc: simplify macro FORCE_INLINE
rockeet Mar 26, 2026
cfc15a8
iterator_wrapper.h: use ForgeFuncPtr
rockeet Mar 26, 2026
b6bfd26
use topling-zip _rvref
rockeet Mar 27, 2026
227fd72
remove unused func ReplaceAll
rockeet Mar 27, 2026
f6ddc86
version_set.cc: extract `fi = file_iter_.iter()`
rockeet Mar 27, 2026
12a8417
merging_iterator.cc: add a static_assert
rockeet Mar 28, 2026
153fba2
db_iter.cc: SetUK: fix static_assert
rockeet Mar 29, 2026
7e51952
memtable: insert_hints_ use hash_strmap
rockeet Mar 29, 2026
2c2dfda
db_impl.cc: add local async_io to help compiler optimzer
rockeet Mar 30, 2026
50cc86b
merging_iterator.cc: static_assert, for commit 12a8417ff82a2c13ecc671…
rockeet Mar 30, 2026
9b11f99
Makefile: prompt user set WITH_TOPLING_ROCKS=0 on download fail
rockeet Mar 31, 2026
c6ad29e
Makefile: Fix CXXFLAGS += -DHAS_TOPLING_ROCKS
rockeet Mar 31, 2026
615a76e
Fix build-min-dep-jni.sh
rockeet Mar 31, 2026
beb710c
Update build sh script
rockeet Apr 1, 2026
532e983
Makefile: for legacy centos
rockeet Apr 1, 2026
8b5b29b
build sh add ospart
rockeet Apr 1, 2026
cf1ea6a
build-min-dep-jni.sh: fix comment
rockeet Apr 1, 2026
0dd8992
db_impl.cc: MultiGetOneCFH: NotSupported on conf error
rockeet Apr 2, 2026
6247d74
db_iter.cc: workaround clang17 bug(eager eval static_assert)
rockeet Apr 2, 2026
5635966
db_iter.cc: static_assert, not only for clang
rockeet Apr 2, 2026
5c755a2
java/rocksjni/transaction.cc: remove unused typedef FnGet
rockeet Apr 3, 2026
ea34cf6
db_iter.h: GetUK() add comment
rockeet Apr 6, 2026
40eb92e
memtable.h: remove useless #include
rockeet Apr 7, 2026
69eb325
block_based_table_reader_test.cc: bugfix: get_context.reserve(keys.si…
rockeet Apr 10, 2026
cb15747
Makefile: auto MAKE_UNIT_TEST=1 on *test*.o
rockeet Apr 10, 2026
68216a0
dbformat.h: make ikey comparator more smart
rockeet Apr 10, 2026
df5d3e9
version_set.cc: minor fix: use auto
rockeet Apr 10, 2026
1a8bdc0
version_set.cc: GetInst: avoid copy `Status` on hot path
rockeet Apr 11, 2026
dd5b50e
version_set.cc: GetInst: TOPLINGDB_WITH_FABRICATED_COMPLEXITY
rockeet Apr 11, 2026
2c4eb12
get_context: do not stat if statistics is null
rockeet Apr 11, 2026
1069131
Makefile: optimize lto flags for clang
rockeet Apr 11, 2026
749d64b
omit LookupKey on Get() for non TOPLINGDB_WITH_TIMESTAMP
rockeet Apr 10, 2026
026bd07
update submodule rockside
rockeet Apr 11, 2026
c4e2f0b
add compile.sh for claude code checking correctness
rockeet Apr 11, 2026
6962288
version_set.cc: FilePicker: remove redundant field `user_key_`
rockeet Apr 12, 2026
8f629ad
version_set.cc: GetInst: tell compiler more truth
rockeet Apr 12, 2026
5669b35
version_set.cc: Remove the negative refactory FilePicker
rockeet Apr 13, 2026
3396bce
version_set.cc: GetInst manually inline `prepare_next_level`
rockeet Apr 13, 2026
563d924
TableCache::GetNoneRowCache: check TOPLINGDB_WITH_TIMESTAMP
rockeet Apr 14, 2026
c172d98
version_set: add m_get_no_watch
rockeet Apr 14, 2026
71194bd
db_bench.sh: convenient fillseq,compact,readrandom
rockeet Apr 20, 2026
5e3a039
compile.sh: export PATH=/usr/local/bin:$PATH
rockeet Apr 20, 2026
c78a892
slice.h: Slice::value_type/iterator/const_iterator
rockeet Apr 20, 2026
ef5952c
db_impl.cc: DBImpl::GetAndRefSuperVersion(cfd,ro) add likely/unlikely
rockeet Apr 24, 2026
bc70eb4
db_impl.h: Add several `final` onto virtual func
rockeet Apr 25, 2026
9f0964f
c: add C FFI for registering side plugin comparator, filter, merge_op…
rockeet Apr 30, 2026
70f61c4
chore: update submodule rockside to 5cdbb9b
rockeet May 2, 2026
15409cd
c: rename FFI_Object to FFI_BridgeObject in register templates
rockeet May 2, 2026
6ffacb8
c: add rocksdb_stdstr_t type with create/destroy API
rockeet May 2, 2026
b891be2
c: add FFI_SerDe, FFI_WebManip and side_plugin_register_ex
rockeet May 2, 2026
207a070
c: add side_plugin_repo_forget_db API
rockeet May 2, 2026
6ba2d57
c: add side_plugin_repo_import(repo, json_str, errptr)
rockeet May 3, 2026
a1e611c
c: add side_plugin_xxxx_get_state(const rocksdb_xxxx_t*)
rockeet May 3, 2026
65ce0e1
submodule rockside: add sample-conf/mytopling{,-2nd}.json
rockeet May 4, 2026
bf54b9c
c: add side_plugin_{db,cf}_options_update_from
rockeet May 4, 2026
9f52c95
Override {DB,CF}Options in DB Open on env TOPLINGDB_EASY_MIGRATE_CONF
rockeet May 4, 2026
7b9e3a8
submodule rockside: UpdateFromName: warn not found only on DebugLevel…
rockeet May 4, 2026
18084ab
Easy Migrate: DBOptions & CFOptions lookup by using dbpath as namespace
rockeet May 5, 2026
078dd25
DB::CreateColumnFamily use new MaybeCFOptionsUpdateFrom(cf_options, c…
rockeet May 6, 2026
fcc800a
feat(db): register DB with EasyMigrate on open and drop on destroy
rockeet May 6, 2026
9926987
chore: add easy_db_bench.sh and bump rockside sample-conf
rockeet May 6, 2026
c850500
fix(db): expose persist_stats_cf_handle for submodule handle fix
rockeet May 7, 2026
88b5ef5
feat(db): add MaybeRetainCF/MaybeForgetCF call sites
rockeet May 7, 2026
ef3c088
chore: update rockside submodule
rockeet May 7, 2026
529d779
feat(c-api): add rocksdb_readoptions_is_in_pinning_section
rockeet May 9, 2026
5d68e7e
update submodule rockside
rockeet May 16, 2026
146594c
Add Status::ToSSO()
rockeet May 18, 2026
0477281
fix(db): auto-detect WAL format instead of trusting memtable_as_log_i…
rockeet May 18, 2026
8fa8e5d
fix(db): add check_wal_format option to gate WAL format auto-detection
rockeet May 18, 2026
ffc6b11
fix(db): return error on WAL format detection failure when check_wal_…
rockeet May 18, 2026
d4104a0
fix(db): add ROCKS_LOG_WARN before return on WAL format detection fai…
rockeet May 18, 2026
15b70eb
DBIter::Seek() remove call to value() for more lazy load
rockeet May 19, 2026
fc79b16
ReadOptions::ReadOptions() set cache_sst_file_iter
rockeet May 22, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
155 changes: 97 additions & 58 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ quoted_perl_command = $(subst ','\'',$(perl_command))
# `make install-shared`, `make static_lib`, `make install-static` or
# `make install`

# Set the default DEBUG_LEVEL to 1
DEBUG_LEVEL?=1
# Set the default DEBUG_LEVEL to 2
DEBUG_LEVEL?=2

# OBJ_DIR is where the object files reside. Default to the current directory
OBJ_DIR?=.
Expand Down Expand Up @@ -120,7 +120,7 @@ endif
ifeq (${DISABLE_JEMALLOC},1)
ifeq (${ROCKSDB_DISABLE_JEMALLOC},)
export_ROCKSDB_DISABLE_JEMALLOC := export ROCKSDB_DISABLE_JEMALLOC=1;
export ROCKSDB_DISABLE_JEMALLOC = 1
export ROCKSDB_DISABLE_JEMALLOC = 1
endif
endif

Expand Down Expand Up @@ -244,9 +244,15 @@ endif
# interfaces/internal abstractions, like in the iterator hierarchy. It works
# better when combined with profile-guided optimizations (not currently
# supported natively in Makefile).
OPTION_jemalloc := jemalloc-$(if $(filter 1,${DISABLE_JEMALLOC}),0,1)
OPTION_dyna_tls := dyna_tls-$(if $(filter 1,${TOPLING_USE_DYNAMIC_TLS}),1,0)
OPTION_lto := lto-0
ifeq ($(USE_LTO), 1)
CXXFLAGS += -flto
LDFLAGS += -flto=auto -fuse-linker-plugin
ifeq (${DEBUG_LEVEL},0)
CXXFLAGS += -flto
LDFLAGS += -flto=auto -fuse-linker-plugin
OPTION_lto := lto-$(if $(filter 1,${USE_LTO}),1,0)
endif
endif

# `COERCE_CONTEXT_SWITCH=1` will inject spurious wakeup and
Expand Down Expand Up @@ -389,7 +395,7 @@ endif
TOPLING_LIB_OBJECTS = $(addprefix ${TOPLING_CORE_DIR}/, ${TOPLING_LIB_OBJ_LIST_VAR})
LDFLAGS += ${TOPLING_CORE_LD_LIBS_EXTRA}

ifneq ($(filter auto_all_tests check check_0 watch-log gen_parallel_tests %_test %_test2 jtest, $(MAKECMDGOALS)),)
ifneq ($(filter auto_all_tests check check_0 watch-log gen_parallel_tests %_test %_test2 jtest %_test.o %_test2.o, $(MAKECMDGOALS)),)
MAKE_UNIT_TEST ?= 1
endif
ifeq (${MAKE_UNIT_TEST},1)
Expand All @@ -406,6 +412,15 @@ endif
ORIG_OBJ_DIR := ${OBJ_DIR}
OBJ_DIR := ${BUILD_PREFIX}${OBJ_DIR}/v${ROCKSDB_FULL_VERSION}

# COMPILER is in ignored
TRIAL_urldir := toplingdb/gpl-trial/${OPTION_lto}-${OPTION_jemalloc}-${OPTION_dyna_tls}/${UNAME_MachineSystem}-bmi2-${WITH_BMI2}/${BUILD_TYPE_SIG}
ifeq (${PLATFORM},OS_LINUX)
LINUX_NAME := $(shell source /etc/os-release; echo $$ID)
ifeq (${LINUX_NAME},centos)
TRIAL_urldir := ${TRIAL_urldir}/$(shell source /etc/os-release; echo $$ID$$VERSION_ID)
endif
endif

# 1. we define ROCKSDB_DISABLE_ZSTD=1 on build_detect_platform.
# 2. zstd lib is included in libterark-zbs
# 3. we alway use ZSTD
Expand All @@ -432,33 +447,24 @@ ifndef WITH_TOPLING_ROCKS
cd topling-rocks; \
git submodule update --init --recursive \
)
endif
ifeq (,$(wildcard sideplugin/topling-rocks))
WITH_TOPLING_ROCKS := 0
else
WITH_TOPLING_ROCKS := 1
ifeq (,$(wildcard sideplugin/topling-rocks/src/table/top_patent_algo.cc))
dummy := $(shell rm -rf sideplugin/topling-rocks)
endif
endif
# default 1
WITH_TOPLING_ROCKS := 1
endif

ifeq (${WITH_TOPLING_ROCKS},1)
ifeq (,$(wildcard sideplugin/topling-rocks))
# topling specific: just for people who has permission to topling-rocks
dummy := $(shell set -e -x; \
cd sideplugin; \
git clone ${GIT_TOPLING_ROCKS}; \
cd topling-rocks; \
git submodule update --init --recursive \
)
else
ifneq (,$(wildcard sideplugin/topling-rocks))
ifneq (${UPDATE_REPO},0)
ifeq (${MAKE_RESTARTS},)
dummy := $(shell set -ex; cd sideplugin/topling-rocks && git pull)
endif
endif
endif
ifeq (,$(wildcard sideplugin/topling-rocks/src/table/top_zip_table_builder.cc))
$(error WITH_TOPLING_ROCKS=1 but repo sideplugin/topling-rocks is broken)
endif
CXXFLAGS += -DHAS_TOPLING_ROCKS
endif

ifeq (,$(wildcard sideplugin/cspp-memtable))
Expand Down Expand Up @@ -611,13 +617,14 @@ endif # WITH_TOPLING_DCOMPACT
ifeq (${WITH_TOPLING_ROCKS},1)
ifneq (,$(wildcard sideplugin/topling-rocks))
CXXFLAGS += -Isideplugin/topling-rocks/src
CXXFLAGS += -DHAS_TOPLING_ROCKS
TOPLING_ROCKS_GIT_VER_SRC = ${BUILD_ROOT}/git-version-topling_rocks.cc
EXTRA_LIB_SOURCES += \
$(wildcard sideplugin/topling-rocks/src/table/*.cc) \
sideplugin/topling-rocks/${TOPLING_ROCKS_GIT_VER_SRC}
else
$(warning NotFound sideplugin/topling-rocks, this is ok, only ToplingZipTable is disabled)
ifeq (,${TOPLING_ZIP_TABLE_TRIAL_DAYS})
EXTRA_LIB_SOURCES += $(wildcard sideplugin/topling-rocks/src/table/*.cc)
EXTRA_LIB_SOURCES += sideplugin/topling-rocks/${TOPLING_ROCKS_GIT_VER_SRC}
else
# no TOPLING_ROCKS_GIT_VER_SRC
EXTRA_LIB_SOURCES += sideplugin/topling-zip_table_reader/top_zip_table_builder.cc
endif
endif
endif

Expand Down Expand Up @@ -785,7 +792,7 @@ endif

ifeq ($(LIB_MODE),shared)
# So that binaries are executable from build location, in addition to install location
EXEC_LDFLAGS += -Wl,-rpath -Wl,'$$ORIGIN'
EXEC_LDFLAGS += -Wl,-rpath -Wl,'$$ORIGIN:$$ORIGIN/../lib'
endif

ifeq ($(PLATFORM), OS_MACOSX)
Expand Down Expand Up @@ -1033,6 +1040,9 @@ endif
# topling specific WARNING_FLAGS
WARNING_FLAGS := -Wall -Wno-shadow
ifeq "$(shell a=${COMPILER};echo $${a:0:5})" "clang"
CXXFLAGS := $(patsubst -flto, -flto=thin, ${CXXFLAGS})
LLD_LTO_FLAGS := -fuse-ld=lld -flto=thin -Wl,--thinlto-jobs=all
LDFLAGS := $(patsubst -flto=auto, ${LLD_LTO_FLAGS}, ${LDFLAGS})
LDFLAGS += -latomic
#$(error LDFLAGS = ${LDFLAGS})
WARNING_FLAGS += -Wno-deprecated-builtins
Expand Down Expand Up @@ -1100,6 +1110,12 @@ ifneq ($(PPC_LIBC_IS_GNU),0)
LIB_OBJECTS += $(patsubst %.cc, $(OBJ_DIR)/%.o, $(RANGE_TREE_SOURCES))
endif

ifeq (${WITH_TOPLING_ROCKS},1)
ifeq (,$(wildcard sideplugin/topling-rocks))
LIB_OBJECTS += $(OBJ_DIR)/sideplugin/topling-zip_table_reader/top_zip_table_builder.o
endif
endif

GTEST = $(OBJ_DIR)/$(GTEST_DIR)/gtest/gtest-all.o
TESTUTIL = $(OBJ_DIR)/test_util/testutil.o
TESTHARNESS = $(OBJ_DIR)/test_util/testharness.o $(TESTUTIL) $(GTEST)
Expand Down Expand Up @@ -2592,39 +2608,44 @@ install-headers: gen-pc
install -d $(INSTALL_LIBDIR)
install -d $(INSTALL_LIBDIR)/pkgconfig
for header_dir in `$(FIND) "include/rocksdb" -type d`; do \
install -d $(DESTDIR)/$(PREFIX)/$$header_dir; \
install -d $(DESTDIR)$(PREFIX)/$$header_dir; \
done
for header in `$(FIND) "include/rocksdb" -type f -name *.h`; do \
install -C -m 644 $$header $(DESTDIR)/$(PREFIX)/$$header; \
install -C -m 644 $$header $(DESTDIR)$(PREFIX)/$$header; \
done
for header in $(ROCKSDB_PLUGIN_HEADERS); do \
install -d $(DESTDIR)/$(PREFIX)/include/rocksdb/`dirname $$header`; \
install -C -m 644 $$header $(DESTDIR)/$(PREFIX)/include/rocksdb/$$header; \
install -d $(DESTDIR)$(PREFIX)/include/rocksdb/`dirname $$header`; \
install -C -m 644 $$header $(DESTDIR)$(PREFIX)/include/rocksdb/$$header; \
done
install -d $(DESTDIR)/$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/json.h $(DESTDIR)/$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/json_fwd.h $(DESTDIR)/$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/builtin_table_factory.h $(DESTDIR)/$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/side_plugin_repo.h $(DESTDIR)/$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/side_plugin_factory.h $(DESTDIR)/$(PREFIX)/include/topling
install -d $(DESTDIR)/$(PREFIX)/include/terark
install -d $(DESTDIR)/$(PREFIX)/include/terark/io
install -d $(DESTDIR)/$(PREFIX)/include/terark/succinct
install -d $(DESTDIR)/$(PREFIX)/include/terark/thread
install -d $(DESTDIR)/$(PREFIX)/include/terark/util
install -d $(DESTDIR)/$(PREFIX)/include/terark/fsa
install -d $(DESTDIR)/$(PREFIX)/include/terark/fsa/ppi
install -d $(DESTDIR)/$(PREFIX)/include/terark/zbs
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/*.hpp $(DESTDIR)/$(PREFIX)/include/terark
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/io/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/io
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/succinct/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/succinct
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/thread/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/thread
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/util/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/util
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/fsa
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/*.inl $(DESTDIR)/$(PREFIX)/include/terark/fsa
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/ppi/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/fsa/ppi
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/zbs/*.hpp $(DESTDIR)/$(PREFIX)/include/terark/zbs
cp -ar ${TOPLING_CORE_DIR}/boost-include/boost $(DESTDIR)/$(PREFIX)/include
install -d $(DESTDIR)$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/json.h $(DESTDIR)$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/json_fwd.h $(DESTDIR)$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/builtin_table_factory.h $(DESTDIR)$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/side_plugin_repo.h $(DESTDIR)$(PREFIX)/include/topling
install -C -m 644 sideplugin/rockside/src/topling/side_plugin_factory.h $(DESTDIR)$(PREFIX)/include/topling
install -d $(DESTDIR)$(PREFIX)/include/terark
install -d $(DESTDIR)$(PREFIX)/include/terark/io
install -d $(DESTDIR)$(PREFIX)/include/terark/succinct
install -d $(DESTDIR)$(PREFIX)/include/terark/thread
install -d $(DESTDIR)$(PREFIX)/include/terark/util
install -d $(DESTDIR)$(PREFIX)/include/terark/fsa
install -d $(DESTDIR)$(PREFIX)/include/terark/fsa/ppi
install -d $(DESTDIR)$(PREFIX)/include/terark/zbs
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/*.hpp $(DESTDIR)$(PREFIX)/include/terark
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/io/*.hpp $(DESTDIR)$(PREFIX)/include/terark/io
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/succinct/*.hpp $(DESTDIR)$(PREFIX)/include/terark/succinct
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/thread/*.hpp $(DESTDIR)$(PREFIX)/include/terark/thread
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/util/*.hpp $(DESTDIR)$(PREFIX)/include/terark/util
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/*.hpp $(DESTDIR)$(PREFIX)/include/terark/fsa
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/*.inl $(DESTDIR)$(PREFIX)/include/terark/fsa
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/fsa/ppi/*.hpp $(DESTDIR)$(PREFIX)/include/terark/fsa/ppi
install -C -m 644 ${TOPLING_CORE_DIR}/src/terark/zbs/*.hpp $(DESTDIR)$(PREFIX)/include/terark/zbs
cp -ar ${TOPLING_CORE_DIR}/boost-include/boost $(DESTDIR)$(PREFIX)/include
install -d $(DESTDIR)$(PREFIX)/site
install -d $(DESTDIR)$(PREFIX)/toplingdb-conf
install -C -m 644 sideplugin/rockside/src/topling/web/index.html $(DESTDIR)$(PREFIX)/site
install -C -m 644 sideplugin/rockside/src/topling/web/style.css $(DESTDIR)$(PREFIX)/site
install -C -m 644 sideplugin/rockside/sample-conf/db_bench_enterprise.yaml $(DESTDIR)$(PREFIX)/toplingdb-conf
install -C -m 644 rocksdb.pc $(INSTALL_LIBDIR)/pkgconfig/rocksdb.pc

install-static: $(LIBRARY) static_lib
Expand All @@ -2634,6 +2655,9 @@ install-static: $(LIBRARY) static_lib
install-shared: $(SHARED4) shared_lib
install -d $(INSTALL_LIBDIR)
install -C -m 755 $(SHARED4) $(INSTALL_LIBDIR)
ifeq ($(STRIP_DEBUG_INFO),1)
$(STRIP_CMD) $(INSTALL_LIBDIR)/$(SHARED4)
endif
ln -fs $(SHARED4) $(INSTALL_LIBDIR)/$(SHARED3)
ln -fs $(SHARED4) $(INSTALL_LIBDIR)/$(SHARED2)
ln -fs $(SHARED4) $(INSTALL_LIBDIR)/$(SHARED1)
Expand All @@ -2643,10 +2667,17 @@ install: install-${LIB_MODE}
install-dev-static: install-headers install-static
install-dev-shared: install-headers install-shared
install-dev: install-dev-${LIB_MODE}
upload-trial: ${OBJ_DIR}/sideplugin/topling-zip_table_reader/top_zip_table_builder.o
ossutil cp --region=cn-qingdao -f \
$(OBJ_DIR)/sideplugin/topling-zip_table_reader/top_zip_table_builder.o \
oss://topling-tools/${TRIAL_urldir}/

install-dcompact: install dcompact_worker
install -d $(DESTDIR)$(PREFIX)/bin
install -C -m 755 sideplugin/topling-dcompact/tools/dcompact/${ORIG_OBJ_DIR}/dcompact_worker.exe $(DESTDIR)$(PREFIX)/bin
ifeq ($(STRIP_DEBUG_INFO),1)
$(STRIP_CMD) $(DESTDIR)$(PREFIX)/bin/dcompact_worker.exe
endif

install-tools: install tools
mkdir -p $(DESTDIR)$(PREFIX)/bin
Expand Down Expand Up @@ -3284,10 +3315,18 @@ ${BUILD_ROOT}/lib_static/libterark-zbs-${COMPILER}-${BUILD_TYPE_SIG}.a:
+make -C ${TOPLING_CORE_DIR} core fsa zbs

ifeq (${WITH_TOPLING_ROCKS},1)
ifneq (,$(wildcard sideplugin/topling-rocks))
ifneq (,$(wildcard sideplugin/topling-rocks/src/table/top_patent_algo.cc))
sideplugin/topling-rocks/${TOPLING_ROCKS_GIT_VER_SRC}: \
sideplugin/topling-rocks/Makefile \
$(shell find sideplugin/topling-rocks/{src,tools} -name '*.cc' -o -name '*.h')
+make -C sideplugin/topling-rocks ${TOPLING_ROCKS_GIT_VER_SRC}
sideplugin/topling-zip_table_reader/top_zip_table_builder.cc: sideplugin/topling-rocks/${TOPLING_ROCKS_GIT_VER_SRC}
else
${OBJ_DIR}/sideplugin/topling-zip_table_reader/top_zip_table_builder.o:
@mkdir -p $(dir $@)
@cd $(dir $@) && \
wget https://topling-tools.oss-cn-qingdao.aliyuncs.com/${TRIAL_urldir}/top_zip_table_builder.o || \
echo 'Download top_zip_table_builder fail, add WITH_TOPLING_ROCKS=0 to make command and try again'
endif
endif

Expand Down
12 changes: 4 additions & 8 deletions README-zh_cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ ToplingDB 由[北京拓扑岭科技有限公司](https://topling.cn)开发与维
## 快速开始
ToplingDB 需要 C++17,推荐 gcc 8.3 以上,或者 clang 也行。

ToplingDB 比 RocksDB 快得多,您可以自己快速验证:
ToplingDB 比 RocksDB 快得多,您可以自己快速验证,[下载 ToplingDB 企业版](https://topling-tools.oss-cn-qingdao.aliyuncs.com/toplingdb-8.10-trail90.tgz),或者自己编译
### Compile & run db_bench
```bash
sudo yum -y install git libaio-devel gcc-c++ gflags-devel zlib-devel bzip2-devel libcurl-devel liburing-devel snappy-devel jemalloc-devel
Expand All @@ -15,7 +15,9 @@ make -j`nproc` db_bench DEBUG_LEVEL=0
sudo make install PREFIX=/some/path # default is /usr/local
```

以上编译命令执行后,运行 [db_bench.sh](db_bench.sh)(需要[端口 2011](https://github.com/topling/rockside/blob/master/sample-conf/db_bench_enterprise.yaml#L4 "内嵌的 http web 服务使用端口 2011")),然后使用 ToplingDB:[原生 C++](https://github.com/topling/rockside/wiki/101 "典型场景是从 rocksdb 迁移过来)"),也支持 [Java](https://github.com/topling/rockside/wiki/SidePlugin-Java-Binding "内置在本 github 仓库中") 和 [Rust](https://github.com/topling/rust-toplingdb "另外的专门的 github 仓库")。
下载解压或者自行编译后,运行 [db_bench.sh](db_bench.sh)(需要[端口 2011](https://github.com/topling/rockside/blob/master/sample-conf/db_bench_enterprise.yaml#L4 "内嵌的 http web 服务使用端口 2011")),然后使用 ToplingDB:[原生 C++](https://github.com/topling/rockside/wiki/101 "典型场景是从 rocksdb 迁移过来)"),也支持 [Java](https://github.com/topling/rockside/wiki/SidePlugin-Java-Binding "内置在本 github 仓库中") 和 [Rust](https://github.com/topling/rust-toplingdb "另外的专门的 github 仓库")。

> 自己编译开源版时会自动下载预编译的试用版(90天) ToplingZipTable,如果下载失败,可以给 `make` 传递变量 `WITH_TOPLING_ROCKS=0` 禁用它(或[联系我们](mailto:contact@topling.cn))。

## 简单介绍
ToplingDB 的子模块 **[rockside](https://github.com/topling/rockside)** 是 ToplingDB 的入口,详情参考 **[SidePlugin wiki](https://github.com/topling/rockside/wiki)**。
Expand Down Expand Up @@ -84,12 +86,6 @@ toplingdb
```
make -j`nproc` EXTRA_CXXFLAGS='-DROCKSDB_DYNAMIC_CREATE_CF' rocksdbjava
```
## License
为了兼容开源协议,下列原先禁止字节跳动使用本软件的条款从 2023-04-24 起已被删除,也就是说,字节跳动使用 ToplingDB 的行为不再是非法的,也不是无耻的。

~~我们禁止字节跳动使用本软件,其它条款与上游 RocksDB 完全相同,~~ 详情参考 [LICENSE.Apache](LICENSE.Apache), [COPYING](COPYING), [LICENSE.leveldb](LICENSE.leveldb).

相应 LICENSE 文件中禁止字节跳动使用本软件的条款也已经删除:[LICENSE.Apache](LICENSE.Apache), [COPYING](COPYING), [LICENSE.leveldb](LICENSE.leveldb).

<hr/>
以下是上游 RocksDB 的原版 README
Expand Down
16 changes: 4 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ ToplingDB is developed and maintained by [Topling Inc](https://topling.cn). See
## Quick Start
ToplingDB requires C++17, gcc 8.3 or newer is recommended, clang also works.

ToplingDB is forked form [RocksDB](https://github.com/facebook/rocksdb), much faster than RocksDB, try it by yourself:
ToplingDB is forked form [RocksDB](https://github.com/facebook/rocksdb), much faster than RocksDB, you can [download ToplingDB Enterprise](https://topling-tools.oss-cn-qingdao.aliyuncs.com/toplingdb-8.10-trail90.tgz) or compile it by yourself:
### Compile & run db_bench
```bash
sudo yum -y install git libaio-devel gcc-c++ gflags-devel zlib-devel bzip2-devel libcurl-devel liburing-devel snappy-devel jemalloc-devel
Expand All @@ -16,7 +16,9 @@ make -j`nproc` db_bench DEBUG_LEVEL=0
sudo make install PREFIX=/some/path # default is /usr/local
```

After compile, you can run bundled [db_bench.sh](db_bench.sh)(need [port 2011](https://github.com/topling/rockside/blob/master/sample-conf/db_bench_enterprise.yaml#L4 "use port 2011 for embeded http server")), then use ToplingDB [in C++](https://github.com/topling/sideplugin-wiki-en/wiki/101 "maybe migrate from rocksdb"), or in [Java](https://github.com/topling/sideplugin-wiki-en/wiki/SidePlugin-Java-Binding "Bundled in this repo"), [Rust](https://github.com/topling/rust-toplingdb "A seperated repo").
After download+uncompress or compile, you can run bundled [db_bench.sh](db_bench.sh)(need [port 2011](https://github.com/topling/rockside/blob/master/sample-conf/db_bench_enterprise.yaml#L4 "use port 2011 for embeded http server")), then use ToplingDB [in C++](https://github.com/topling/sideplugin-wiki-en/wiki/101 "maybe migrate from rocksdb"), or in [Java](https://github.com/topling/sideplugin-wiki-en/wiki/SidePlugin-Java-Binding "Bundled in this repo"), [Rust](https://github.com/topling/rust-toplingdb "A seperated repo").

> During compiling, precompiled ToplingZipTable(90 days trial) will be auto downloaded, if download failed, you can pass `WITH_TOPLING_ROCKS=0` to `make` to disalbe it(or [contact us](mailto:contact@topling.cn)).

## Introduction
ToplingDB's submodule **[rockside](https://github.com/topling/rockside)** is the entry point of ToplingDB, see **[SidePlugin wiki](https://github.com/topling/sideplugin-wiki-en/wiki)**.
Expand Down Expand Up @@ -88,16 +90,6 @@ To enable these features, add `-D${MACRO_NAME}` to var `EXTRA_CXXFLAGS`, such as
```
make -j`nproc` EXTRA_CXXFLAGS='-DROCKSDB_DYNAMIC_CREATE_CF' rocksdbjava
```
## License
To conform open source license, the following term of disallowing bytedance is deleted since 2023-04-24,
that is say: bytedance using ToplingDB is no longer illeagal and is not a shame.

~~We disallow bytedance using this software, other terms are identidal with
upstream rocksdb license,~~ see [LICENSE.Apache](LICENSE.Apache), [COPYING](COPYING) and
[LICENSE.leveldb](LICENSE.leveldb).

The terms of disallowing bytedance are also deleted in [LICENSE.Apache](LICENSE.Apache), [COPYING](COPYING) and
[LICENSE.leveldb](LICENSE.leveldb).

<hr/>
<hr/>
Expand Down
9 changes: 9 additions & 0 deletions btest-trial.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/bash

if [ -e sideplugin/topling-rocks-bak ]; then
echo sideplugin/topling-rocks-bak exists >&2
exit 1
fi
mv sideplugin/{topling-rocks,topling-rocks-bak}
make WITH_TOPLING_ROCKS=1 $@
mv sideplugin/{topling-rocks-bak,topling-rocks}
Loading