Skip to content

Commit 4f1ad92

Browse files
To fix the issue: show_techsupport & saidump errors during testbed testing by replacing redis-rdb-tool with rdb-cli (#1391) (#1471)
Why I did it Fix issue: #1387 The latest redis-rdb-tools-0.1.15 doesn't support Redis 7.0. Redis 7.0 was released in 2020 and adopted by SONiC's latest version. So, this issue turned out. https://github.com/sripathikrishnan/redis-rdb-tools I.e., the rdb-tools is far behind the Redis 7.0. The librdb can perfectly fix this issue. Please see quote from https://github.com/redis/librdb. Motivation behind this project There is a genuine need by the Redis community for a versatile RDB file parser that can export data, perform data analysis, or merely extract raw data from RDB and RESTORE it against a live Redis server. However, available parsers have shortcomings in some aspects such as lack of long-term support, lagging far behind the latest Redis release, and usually not being optimized for memory, performance, or high-traffic streaming for production environments. Additionally, most of them are not written in C, which limits the reuse of Redis components and the potential to contribute back to Redis repo. To address these issues, it is worthwhile to develop a new parser with a modern architecture, that maybe can also challenge the current integrated RDB parser of Redis and even replace it in the future. So, the below PRS are to replace rdbtools with librdb's tool rdb-cli. sonic-net/sonic-buildimage#19268 Co-authored-by: JunhongMao <[email protected]>
1 parent a00e89d commit 4f1ad92

14 files changed

Lines changed: 18889 additions & 209 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ unittest/meta/tests
111111
unittest/syncd/tests
112112
unittest/vslib/tests
113113
unittest/vslib/testslibsaivs
114+
unittest/saidump/tests
114115
vslib/tests
115116

116117
# Temporary files #

configure.ac

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,7 @@ AC_OUTPUT(Makefile
295295
unittest/lib/Makefile
296296
unittest/vslib/Makefile
297297
unittest/syncd/Makefile
298+
unittest/saidump/Makefile
298299
pyext/Makefile
299300
pyext/py2/Makefile
300301
pyext/py3/Makefile)

saidump/Makefile.am

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,14 @@ AM_CXXFLAGS = $(SAIINC) -I$(top_srcdir)/lib
22

33
bin_PROGRAMS = saidump
44

5-
saidump_SOURCES = saidump.cpp
5+
saidump_SOURCES = main.cpp SaiDump.cpp
66
saidump_CPPFLAGS = $(CODE_COVERAGE_CPPFLAGS)
77
saidump_CXXFLAGS = $(DBGFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS_COMMON) $(CODE_COVERAGE_CXXFLAGS)
88
saidump_LDADD = -lhiredis -lswsscommon -lpthread -L$(top_srcdir)/meta/.libs -lsaimetadata -lsaimeta \
99
-L$(top_srcdir)/lib/.libs -lsairedis -lzmq $(CODE_COVERAGE_LIBS)
10+
11+
noinst_LIBRARIES = libsaidump.a
12+
13+
libsaidump_a_SOURCES = SaiDump.cpp
14+
libsaidump_a_CPPFLAGS = $(CODE_COVERAGE_CPPFLAGS)
15+
libsaidump_a_CXXFLAGS = $(DBGFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS_COMMON) $(CODE_COVERAGE_CXXFLAGS)

0 commit comments

Comments
 (0)