Merge branch 'keydbpro' into PRO_RELEASE_6

Former-commit-id: 97280cec291bca779739e008b9467fbb40a19a5f
This commit is contained in:
Ben Schermel 2020-06-10 17:35:21 -04:00
commit 9e9064782d
74 changed files with 198 additions and 417 deletions

8
.gitignore vendored
View File

@ -10,12 +10,11 @@ core
!**/keydb-sentinel.service.d !**/keydb-sentinel.service.d
*.log *.log
dump.rdb dump.rdb
src/keydb-server src/keydb-pro-server
**/bin/keydb-server **/bin/keydb-pro-server
**/app/keydb-server **/app/keydb-pro-server
*.deb *.deb
*.rpm *.rpm
keydb-pro-server
src/keydb-cli src/keydb-cli
**/bin/keydb-cli **/bin/keydb-cli
**/app/keydb-cli **/app/keydb-cli
@ -33,7 +32,6 @@ keydb-check-dump
redis-cli redis-cli
redis-sentinel redis-sentinel
redis-server redis-server
keydb-pro-server
doc-tools doc-tools
release release
misc/* misc/*

View File

@ -1,18 +1,14 @@
### KeyDB DEB Package Source Builds ### KeyDB DEB Package Source Builds
This directory contains scripts and components needed to generate debian packages on different distributions/architectures from source This directory contains scripts and components needed to generate debian packages on different distributions/architectures using source
The 'debian' directory contains debian source code for bionic, buster and later distributions as it uses functions only available with debhelper11+. 'debian_dh9' is used for xenial, stretch and earlier distributions using debhelper9. You will need to install pbuilder `sudo apt install pbuilder`
You will need to install pbuilder `sudo apt install pbuilder` along with other distribution specific dependancies
Generate deb packages with the following script command run from this directory: Generate deb packages with the following script command run from this directory:
``` ```
$ ./deb-buildsource.sh $ ./deb-buildsource.sh
``` ```
This generates a directory structure, .dsc file, original.tar.gz, .changes files and new changelog for the distribution and architecture installed.
This generates a directory structure, .dsc file, original.tar.gz, and new changelog for the distribution and architecture installed.
When complete the produced debian packages will be located in deb_files_generated directory. When complete the produced debian packages will be located in deb_files_generated directory.

View File

@ -19,12 +19,12 @@ elif [ "$distributor" == "Ubuntu" ]; then
fi fi
codename=$(lsb_release --codename --short) codename=$(lsb_release --codename --short)
date=$(date +%a," "%d" "%b" "%Y" "%T) date=$(date +%a," "%d" "%b" "%Y" "%T)
pkg_name=keydb-$majorv:$version$distname pkg_name=keydb-pro-$majorv:$version$distname
# create build tree # create build tree
cd ../../../ cd ../../../
tar -czvf keydb_$version.orig.tar.gz --force-local KeyDB tar -czvf keydb-pro_$version.orig.tar.gz --force-local KeyDB-Pro
cd KeyDB/pkg/deb/ cd KeyDB-Pro/pkg/deb/
mkdir -p $pkg_name/tmp mkdir -p $pkg_name/tmp
if [[ "$codename" == "xenial" ]] || [[ "$codename" == "stretch" ]]; then if [[ "$codename" == "xenial" ]] || [[ "$codename" == "stretch" ]]; then
cp -r debian_dh9 $pkg_name/tmp/debian cp -r debian_dh9 $pkg_name/tmp/debian
@ -32,9 +32,9 @@ else
cp -r debian $pkg_name/tmp cp -r debian $pkg_name/tmp
fi fi
cp master_changelog $pkg_name/tmp/debian/changelog cp master_changelog $pkg_name/tmp/debian/changelog
mv ../../../keydb_$version.orig.tar.gz ./$pkg_name mv ../../../keydb-pro_$version.orig.tar.gz ./$pkg_name
cd $pkg_name/tmp cd $pkg_name/tmp
changelog_str="keydb ($majorv:$version-$build$distname) $codename; urgency=medium\n\n * $version $changelog_comments \n\n -- Ben Schermel <ben@eqalpha.com> $date +0000\n\n" changelog_str="keydb-pro ($majorv:$version-$build$distname) $codename; urgency=medium\n\n * $version $changelog_comments \n\n -- Ben Schermel <ben@eqalpha.com> $date +0000\n\n"
if [ $# -eq 0 ]; then if [ $# -eq 0 ]; then
sed -i "1s/^/$changelog_str\n/" debian/changelog sed -i "1s/^/$changelog_str\n/" debian/changelog
elif [ $# -eq 1 ] && [ "$1" != "None" ]; then elif [ $# -eq 1 ] && [ "$1" != "None" ]; then
@ -53,8 +53,9 @@ if [ "$codename" == "xenial" ]; then
else else
sudo pbuilder create --distribution $codename sudo pbuilder create --distribution $codename
fi fi
sudo pbuilder --update sudo pbuilder --update
sudo pbuilder --build *.dsc sudo pbuilder --build *.dsc --logfile /mnt/pbuilderlog.log
# move new packages to deb_files_generated and clean up # move new packages to deb_files_generated and clean up
cp /var/cache/pbuilder/result/*$version*.deb ../deb_files_generated cp /var/cache/pbuilder/result/*$version*.deb ../deb_files_generated

View File

@ -9,7 +9,6 @@ else
SYSTEMD_EXTRA=$(cat <<EOF SYSTEMD_EXTRA=$(cat <<EOF
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX
#MemoryDenyWriteExecute=true
ProtectKernelModules=true ProtectKernelModules=true
ProtectKernelTunables=true ProtectKernelTunables=true
ProtectControlGroups=true ProtectControlGroups=true
@ -26,22 +25,28 @@ do
case "${BINARY}" in case "${BINARY}" in
keydb-server) keydb-server)
NAME="keydb" NAME="keydb"
BINARY_EXEC="keydb-server"
BINARY_NAME="keydb-pro-server"
TARGET_NAME="keydb-pro-server"
;; ;;
keydb-sentinel) keydb-sentinel)
NAME="sentinel" NAME="sentinel"
BINARY_EXEC="keydb-sentinel"
BINARY_NAME="keydb-sentinel"
TARGET_NAME="keydb-pro-sentinel"
;; ;;
esac esac
case "${MODE}" in case "${MODE}" in
default) default)
EXTRA="Alias=${NAME}.service" EXTRA="Alias=${NAME}.service"
TARGET="debian/${BINARY}.service" TARGET="debian/${TARGET_NAME}.${BINARY}.service"
NAMESPACED="${NAME}" NAMESPACED="${NAME}"
DESCRIPTION="Advanced key-value store" DESCRIPTION="Advanced key-value store"
;; ;;
templated) templated)
EXTRA="" EXTRA=""
TARGET="debian/${BINARY}@.service" TARGET="debian/${TARGET_NAME}.${BINARY}@.service"
NAMESPACED="${NAME}-%i" NAMESPACED="${NAME}-%i"
DESCRIPTION="Advanced key-value store (%I)" DESCRIPTION="Advanced key-value store (%I)"
;; ;;
@ -89,7 +94,7 @@ Documentation=https://docs.keydb.dev, man:${BINARY}(1)
[Service] [Service]
Type=forking Type=forking
ExecStart=/usr/bin/${BINARY} /etc/keydb/${NAMESPACED}.conf ExecStart=/usr/bin/${BINARY_NAME} /etc/keydb/${NAMESPACED}.conf
ExecStop=/bin/kill -s TERM \$MAINPID ExecStop=/bin/kill -s TERM \$MAINPID
PIDFile=/var/run/${NAMESPACED}/${BINARY}.pid PIDFile=/var/run/${NAMESPACED}/${BINARY}.pid
TimeoutStopSec=0 TimeoutStopSec=0

View File

@ -1,4 +1,4 @@
Source: keydb Source: keydb-pro
Section: database Section: database
Priority: optional Priority: optional
Maintainer: Ben Schermel <ben@eqalpha.com> Maintainer: Ben Schermel <ben@eqalpha.com>
@ -16,17 +16,22 @@ Build-Depends:
autotools-dev <!nocheck>, autotools-dev <!nocheck>,
autoconf <!nocheck>, autoconf <!nocheck>,
libjemalloc-dev <!nocheck>, libjemalloc-dev <!nocheck>,
libssl-dev <!nocheck> libssl-dev <!nocheck>,
libsnappy-dev <!nocheck>,
zlib1g-dev <!nocheck>,
libbz2-dev <!nocheck>,
liblz4-dev <!nocheck>,
libzstd-dev <!nocheck>
Standards-Version: 4.2.1 Standards-Version: 4.2.1
Homepage: https://docs.keydb.dev/ Homepage: https://docs.keydb.dev/
Vcs-Git: https://github.com/JohnSully/KeyDB.git Vcs-Git: https://github.com/JohnSully/KeyDB-Pro.git
Vcs-Browser: https://github.com/JohnSully/KeyDB Vcs-Browser: https://github.com/JohnSully/KeyDB-Pro
Package: keydb Package: keydb-pro
Architecture: all Architecture: all
Depends: Depends:
keydb-server (<< ${binary:Version}.1~), keydb-pro-server (<< ${binary:Version}.1~),
keydb-server (>= ${binary:Version}), keydb-pro-server (>= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface (metapackage) Description: Persistent key-value database with network interface (metapackage)
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -37,11 +42,11 @@ Description: Persistent key-value database with network interface (metapackage)
. .
This package depends on the keydb-server package. This package depends on the keydb-server package.
Package: keydb-sentinel Package: keydb-pro-sentinel
Architecture: any Architecture: any
Depends: Depends:
lsb-base (>= 3.2-14), lsb-base (>= 3.2-14),
keydb-tools (= ${binary:Version}), keydb-pro-tools (= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface (monitoring) Description: Persistent key-value database with network interface (monitoring)
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -50,11 +55,11 @@ Description: Persistent key-value database with network interface (monitoring)
. .
This package contains the keydb Sentinel monitoring software. This package contains the keydb Sentinel monitoring software.
Package: keydb-server Package: keydb-pro-server
Architecture: any Architecture: any
Depends: Depends:
lsb-base (>= 3.2-14), lsb-base (>= 3.2-14),
keydb-tools (= ${binary:Version}), keydb-pro-tools (= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface Description: Persistent key-value database with network interface
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -63,7 +68,7 @@ Description: Persistent key-value database with network interface
. .
The dataset is stored entirely in memory and periodically flushed to disk. The dataset is stored entirely in memory and periodically flushed to disk.
Package: keydb-tools Package: keydb-pro-tools
Architecture: any Architecture: any
Depends: Depends:
adduser, adduser,

View File

@ -0,0 +1 @@
pkg/deb/conf/sentinel.conf /etc/keydb

View File

@ -0,0 +1 @@
debian/keydb-pro-sentinel.1

View File

@ -0,0 +1 @@
pkg/deb/conf/keydb.conf /etc/keydb

View File

@ -0,0 +1 @@
debian/keydb-pro-server.1

View File

@ -1,7 +1,7 @@
debian/bash_completion.d/* /usr/share/bash-completion/completions debian/bash_completion.d/* /usr/share/bash-completion/completions
src/keydb-server /usr/bin
src/keydb-benchmark /usr/bin src/keydb-benchmark /usr/bin
src/keydb-check-aof /usr/bin src/keydb-check-aof /usr/bin
src/keydb-check-rdb /usr/bin src/keydb-check-rdb /usr/bin
src/keydb-cli /usr/bin src/keydb-cli /usr/bin
src/keydb-pro-server /usr/bin
src/keydb-sentinel /usr/bin src/keydb-sentinel /usr/bin

View File

@ -1 +0,0 @@
debian/keydb-sentinel.1

View File

@ -1 +0,0 @@
debian/keydb-server.1

View File

@ -18,7 +18,8 @@ endif
override_dh_auto_install: override_dh_auto_install:
debian/bin/generate-systemd-service-files debian/bin/generate-systemd-service-files
dh_installsystemd --restart-after-upgrade dh_installsystemd --name keydb-server --restart-after-upgrade
dh_installsystemd --name keydb-sentinel --restart-after-upgrade
override_dh_auto_test: override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))

View File

@ -9,7 +9,6 @@ else
SYSTEMD_EXTRA=$(cat <<EOF SYSTEMD_EXTRA=$(cat <<EOF
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX
#MemoryDenyWriteExecute=true
ProtectKernelModules=true ProtectKernelModules=true
ProtectKernelTunables=true ProtectKernelTunables=true
ProtectControlGroups=true ProtectControlGroups=true
@ -26,9 +25,13 @@ do
case "${BINARY}" in case "${BINARY}" in
keydb-server) keydb-server)
NAME="keydb" NAME="keydb"
BINARY_EXEC="keydb-server"
BINARY_NAME="keydb-pro-server"
;; ;;
keydb-sentinel) keydb-sentinel)
NAME="sentinel" NAME="sentinel"
BINARY_EXEC="keydb-sentinel"
BINARY_NAME="keydb-sentinel"
;; ;;
esac esac
@ -78,8 +81,6 @@ do
# #
# $ systemctl start ${BINARY}@myname.service # $ systemctl start ${BINARY}@myname.service
# $ keydb-cli -s /var/run/${NAME}-myname/${BINARY}.sock info | grep config_file # $ keydb-cli -s /var/run/${NAME}-myname/${BINARY}.sock info | grep config_file
#
# -- Chris Lamb <lamby@debian.org> Mon, 09 Oct 2017 22:17:24 +0100
EOF EOF
fi fi
@ -91,7 +92,7 @@ Documentation=https://docs.keydb.dev, man:${BINARY}(1)
[Service] [Service]
Type=forking Type=forking
ExecStart=/usr/bin/${BINARY} /etc/keydb/${NAMESPACED}.conf ExecStart=/usr/bin/${BINARY_NAME} /etc/keydb/${NAMESPACED}.conf
ExecStop=/bin/kill -s TERM \$MAINPID ExecStop=/bin/kill -s TERM \$MAINPID
PIDFile=/var/run/${NAMESPACED}/${BINARY}.pid PIDFile=/var/run/${NAMESPACED}/${BINARY}.pid
TimeoutStopSec=0 TimeoutStopSec=0

View File

@ -1,4 +1,4 @@
Source: keydb Source: keydb-pro
Section: database Section: database
Priority: optional Priority: optional
Maintainer: Ben Schermel <ben@eqalpha.com> Maintainer: Ben Schermel <ben@eqalpha.com>
@ -6,6 +6,11 @@ Build-Depends:
debhelper (>= 9~), debhelper (>= 9~),
dpkg-dev (>= 1.17.5), dpkg-dev (>= 1.17.5),
systemd, systemd,
# libhiredis-dev (>= 0.14.0),
# libjemalloc-dev [linux-any],
# liblua5.1-dev,
# lua-bitop-dev,
# lua-cjson-dev,
procps <!nocheck>, procps <!nocheck>,
build-essential <!nocheck>, build-essential <!nocheck>,
tcl <!nocheck>, tcl <!nocheck>,
@ -16,17 +21,22 @@ Build-Depends:
autotools-dev <!nocheck>, autotools-dev <!nocheck>,
autoconf <!nocheck>, autoconf <!nocheck>,
libjemalloc-dev <!nocheck>, libjemalloc-dev <!nocheck>,
libssl-dev <!nocheck> libssl-dev <!nocheck>,
libsnappy-dev <!nocheck>,
zlib1g-dev <!nocheck>,
libbz2-dev <!nocheck>,
liblz4-dev <!nocheck>,
libzstd-dev <!nocheck>
Standards-Version: 4.2.1 Standards-Version: 4.2.1
Homepage: https://docs.keydb.dev/ Homepage: https://docs.keydb.dev/
Vcs-Git: https://github.com/JohnSully/KeyDB.git Vcs-Git: https://github.com/JohnSully/KeyDB-Pro.git
Vcs-Browser: https://github.com/JohnSully/KeyDB Vcs-Browser: https://github.com/JohnSully/KeyDB-Pro
Package: keydb Package: keydb-pro
Architecture: all Architecture: all
Depends: Depends:
keydb-server (<< ${binary:Version}.1~), keydb-pro-server (<< ${binary:Version}.1~),
keydb-server (>= ${binary:Version}), keydb-pro-server (>= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface (metapackage) Description: Persistent key-value database with network interface (metapackage)
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -37,11 +47,11 @@ Description: Persistent key-value database with network interface (metapackage)
. .
This package depends on the keydb-server package. This package depends on the keydb-server package.
Package: keydb-sentinel Package: keydb-pro-sentinel
Architecture: any Architecture: any
Depends: Depends:
lsb-base (>= 3.2-14), lsb-base (>= 3.2-14),
keydb-tools (= ${binary:Version}), keydb-pro-tools (= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface (monitoring) Description: Persistent key-value database with network interface (monitoring)
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -50,11 +60,11 @@ Description: Persistent key-value database with network interface (monitoring)
. .
This package contains the keydb Sentinel monitoring software. This package contains the keydb Sentinel monitoring software.
Package: keydb-server Package: keydb-pro-server
Architecture: any Architecture: any
Depends: Depends:
lsb-base (>= 3.2-14), lsb-base (>= 3.2-14),
keydb-tools (= ${binary:Version}), keydb-pro-tools (= ${binary:Version}),
${misc:Depends}, ${misc:Depends},
Description: Persistent key-value database with network interface Description: Persistent key-value database with network interface
keydb is a key-value database in a similar vein to memcache but the dataset keydb is a key-value database in a similar vein to memcache but the dataset
@ -63,7 +73,7 @@ Description: Persistent key-value database with network interface
. .
The dataset is stored entirely in memory and periodically flushed to disk. The dataset is stored entirely in memory and periodically flushed to disk.
Package: keydb-tools Package: keydb-pro-tools
Architecture: any Architecture: any
Depends: Depends:
adduser, adduser,

View File

@ -1,86 +1,13 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Contact: John Sully <john@eqalpha.com> Upstream-Contact: John Sully <john@eqalpha.com>
Upstream-Name: keydb Upstream-Name: keydb-pro
Source: https://github.com/JohnSully/KeyDB Source: https://github.com/JohnSully/KeyDB-Pro
Files: * Files: *
Copyright: © 2006-2014 Salvatore Sanfilippo <antirez@gmail.com> Copyright: © 2006-2014 Salvatore Sanfilippo <antirez@gmail.com>
Copyright © 2019, John Sully Copyright © 2019, John Sully
License: BSD-3-clause License: Proprietary
Files:
src/rio.*
src/t_zset.c
src/ziplist.h
src/intset.*
src/redis-check-aof.c
deps/hiredis/*
deps/linenoise/*
Copyright:
© 2009-2012 Pieter Noordhuis <pcnoordhuis@gmail.com>
© 2009-2012 Salvatore Sanfilippo <antirez@gmail.com>
License: BSD-3-clause
Files:
src/lzf.h
src/lzfP.h
src/lzf_d.c
src/lzf_c.c
Copyright:
© 2000-2007 Marc Alexander Lehmann <schmorp@schmorp.de>
© 2009-2012 Salvatore Sanfilippo <antirez@gmail.com>
License: BSD-2-clause
Files: src/setproctitle.c
Copyright:
© 2010 William Ahern
© 2013 Salvatore Sanfilippo
© 2013 Stam He
License: BSD-3-clause
Files: src/ae_evport.c
Copyright: © 2012 Joyent, Inc.
License: BSD-3-clause
Files: src/ae_kqueue.c
Copyright: © 2009 Harish Mallipeddi <harish.mallipeddi@gmail.com>
License: BSD-3-clause
Files: utils/install_server.sh
Copyright: © 2011 Dvir Volk <dvirsk@gmail.com>
License: BSD-3-clause
Files: deps/jemalloc/*
Copyright:
© 2002-2012 Jason Evans <jasone@canonware.com>
© 2007-2012 Mozilla Foundation
© 2009-2012 Facebook, Inc.
License: BSD-3-clause
Files: src/pqsort.*
Copyright: © 1992-1993 The Regents of the University of California
License: BSD-3-clause
Files: deps/lua/*
Copyright: © 1994-2012 Lua.org, PUC-Ri
License: MIT
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
.
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
Files: debian/* Files: debian/*
Copyright: © 2009 Chris Lamb <lamby@debian.org> Copyright: © 2009 Chris Lamb <lamby@debian.org>

View File

@ -1 +1 @@
keydb_5.3.3-1~bionic1_source.buildinfo database optional keydb-pro_5.3.3-1~bionic1_source.buildinfo database optional

View File

@ -1,6 +1,6 @@
.TH KEYDB-BENCHMARK 1 "August 17, 2019" .TH KEYDB-BENCHMARK 1 "August 17, 2019"
.SH NAME .SH NAME
keydb-benchmark \- Benechmark a KeyDB instance keydb-benchmark \- Benchmark a KeyDB instance
.SH SYNOPSIS .SH SYNOPSIS
.B redis-benchmark .B redis-benchmark
[\-h <host>] [\-p <port>] [\-c <clients>] [\-n <requests]> [\-k <boolean>] [\-h <host>] [\-p <port>] [\-c <clients>] [\-n <requests]> [\-k <boolean>]

View File

@ -0,0 +1 @@
debian/keydb-pro-sentinel.1

View File

@ -21,4 +21,6 @@ then
find /etc/keydb -maxdepth 1 -type d -name 'keydb-sentinel.*.d' -empty -delete find /etc/keydb -maxdepth 1 -type d -name 'keydb-sentinel.*.d' -empty -delete
fi fi
systemctl daemon-reload
exit 0 exit 0

View File

@ -11,4 +11,6 @@ fi
#DEBHELPER# #DEBHELPER#
systemctl daemon-reload
exit 0 exit 0

View File

@ -0,0 +1,12 @@
#!/bin/sh
set -e
# Automatically added by dh_installinit/11.1.6ubuntu1
if [ -x "/etc/init.d/keydb-sentinel" ]; then
invoke-rc.d keydb-sentinel stop || exit 1
fi
# End automatically added section
# Automatically added by dh_installsystemd/11.1.6ubuntu1
if [ -d /run/systemd/system ] && [ "$1" = remove ]; then
deb-systemd-invoke stop 'keydb-sentinel.service' >/dev/null || true
fi
# End automatically added section

View File

@ -0,0 +1 @@
debian/keydb-pro-server.1

View File

@ -21,4 +21,6 @@ then
find /etc/keydb -maxdepth 1 -type d -name 'keydb-server.*.d' -empty -delete find /etc/keydb -maxdepth 1 -type d -name 'keydb-server.*.d' -empty -delete
fi fi
systemctl daemon-reload
exit 0 exit 0

View File

@ -11,4 +11,6 @@ fi
#DEBHELPER# #DEBHELPER#
systemctl daemon-reload
exit 0 exit 0

View File

@ -0,0 +1,12 @@
#!/bin/sh
set -e
# Automatically added by dh_installinit/11.1.6ubuntu1
if [ -x "/etc/init.d/keydb-server" ]; then
invoke-rc.d keydb-server stop || exit 1
fi
# End automatically added section
# Automatically added by dh_installsystemd/11.1.6ubuntu1
if [ -d /run/systemd/system ] && [ "$1" = remove ]; then
deb-systemd-invoke stop 'keydb-server.service' >/dev/null || true
fi
# End automatically added section

View File

@ -3,5 +3,5 @@ src/keydb-benchmark /usr/bin
src/keydb-check-aof /usr/bin src/keydb-check-aof /usr/bin
src/keydb-check-rdb /usr/bin src/keydb-check-rdb /usr/bin
src/keydb-cli /usr/bin src/keydb-cli /usr/bin
src/keydb-server /usr/bin src/keydb-pro-server /usr/bin
src/keydb-sentinel /usr/bin src/keydb-sentinel /usr/bin

View File

@ -1,8 +0,0 @@
# keydb-sentinel configure options
# ULIMIT: Call ulimit -n with this argument prior to invoking KeyDB Sentinel
# itself. This may be required for high-concurrency environments. KeyDB
# Sentinel itself cannot alter its limits as it is not being run as root.
# (default: 65536)
#
ULIMIT=65536

View File

@ -1,89 +0,0 @@
#! /bin/sh
### BEGIN INIT INFO
# Provides: keydb-sentinel
# Required-Start: $syslog $remote_fs
# Required-Stop: $syslog $remote_fs
# Should-Start: $local_fs
# Should-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: keydb-sentinel - Persistent key-value db monitor
# Description: keydb-sentinel - Persistent key-value db monitor
### END INIT INFO
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/bin/keydb-sentinel
DAEMON_ARGS=/etc/keydb/sentinel.conf
NAME=keydb-sentinel
DESC=keydb-sentinel
RUNDIR=/var/run/sentinel
PIDFILE=$RUNDIR/keydb-sentinel.pid
test -x $DAEMON || exit 0
if [ -r /etc/default/$NAME ]
then
. /etc/default/$NAME
fi
. /lib/lsb/init-functions
set -e
if [ "$(id -u)" != "0" ]
then
log_failure_msg "Must be run as root."
exit 1
fi
case "$1" in
start)
echo -n "Starting $DESC: "
mkdir -p $RUNDIR
touch $PIDFILE
chown keydb:keydb $RUNDIR $PIDFILE
chmod 755 $RUNDIR
if [ -n "$ULIMIT" ]
then
ulimit -n $ULIMIT || true
fi
if start-stop-daemon --start --quiet --oknodo --umask 007 --pidfile $PIDFILE --chuid keydb:keydb --exec $DAEMON -- $DAEMON_ARGS
then
echo "$NAME."
else
echo "failed"
fi
;;
stop)
echo -n "Stopping $DESC: "
if start-stop-daemon --stop --retry forever/TERM/1 --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
then
echo "$NAME."
else
echo "failed"
fi
rm -f $PIDFILE
sleep 1
;;
restart|force-reload)
${0} stop
${0} start
;;
status)
status_of_proc -p ${PIDFILE} ${DAEMON} ${NAME}
;;
*)
echo "Usage: /etc/init.d/$NAME {start|stop|restart|force-reload|status}" >&2
exit 1
;;
esac
exit 0

View File

@ -1,2 +0,0 @@
debian/keydb-sentinel.service /lib/systemd/system
pkg/deb/conf/sentinel.conf /etc/keydb

View File

@ -1 +0,0 @@
debian/keydb-sentinel.1

View File

@ -1,7 +0,0 @@
# keydb-server configure options
# ULIMIT: Call ulimit -n with this argument prior to invoking Redis itself.
# This may be required for high-concurrency environments. KeyDB itself cannot
# alter its limits as it is not being run as root. (default: 65536)
#
ULIMIT=65536

View File

@ -1,89 +0,0 @@
#! /bin/sh
### BEGIN INIT INFO
# Provides: keydb-server
# Required-Start: $syslog $remote_fs
# Required-Stop: $syslog $remote_fs
# Should-Start: $local_fs
# Should-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: keydb-server - Persistent key-value db
# Description: keydb-server - Persistent key-value db
### END INIT INFO
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/bin/keydb-server
DAEMON_ARGS=/etc/keydb/keydb.conf
NAME=keydb-server
DESC=keydb-server
RUNDIR=/var/run/keydb
PIDFILE=$RUNDIR/keydb-server.pid
test -x $DAEMON || exit 0
if [ -r /etc/default/$NAME ]
then
. /etc/default/$NAME
fi
. /lib/lsb/init-functions
set -e
if [ "$(id -u)" != "0" ]
then
log_failure_msg "Must be run as root."
exit 1
fi
case "$1" in
start)
echo -n "Starting $DESC: "
mkdir -p $RUNDIR
touch $PIDFILE
chown keydb:keydb $RUNDIR $PIDFILE
chmod 755 $RUNDIR
if [ -n "$ULIMIT" ]
then
ulimit -n $ULIMIT || true
fi
if start-stop-daemon --start --quiet --oknodo --umask 007 --pidfile $PIDFILE --chuid keydb:keydb --exec $DAEMON -- $DAEMON_ARGS
then
echo "$NAME."
else
echo "failed"
fi
;;
stop)
echo -n "Stopping $DESC: "
if start-stop-daemon --stop --retry forever/TERM/1 --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON
then
echo "$NAME."
else
echo "failed"
fi
rm -f $PIDFILE
sleep 1
;;
restart|force-reload)
${0} stop
${0} start
;;
status)
status_of_proc -p ${PIDFILE} ${DAEMON} ${NAME}
;;
*)
echo "Usage: /etc/init.d/$NAME {start|stop|restart|force-reload|status}" >&2
exit 1
;;
esac
exit 0

View File

@ -1,2 +0,0 @@
debian/keydb-server.service /lib/systemd/system
pkg/deb/conf/keydb.conf /etc/keydb

View File

@ -1 +0,0 @@
debian/keydb-server.1

View File

@ -32,9 +32,9 @@ override_dh_auto_install:
override_dh_auto_test: override_dh_auto_test:
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS))) ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
# Avoid race conditions in upstream testsuite. # Avoid race conditions in upstream testsuite.
# ./runtest --clients 1 || true ./runtest --clients 1 || true
# ./runtest-cluster || true ./runtest-cluster || true
# ./runtest-sentinel || true ./runtest-sentinel || true
endif endif
override_dh_auto_clean: override_dh_auto_clean:

View File

@ -1,2 +1,3 @@
keydb_5.0.6.orig.tar.gz keydb-pro_5.0.6.orig.tar.gz
keydb_5.0.6-1chl1~bionic1.debian.tar.xz keydb-pro_5.0.6-1~bionic1.debian.tar.xz

View File

@ -1,2 +1,2 @@
# Upstream do not provide signed tarballs. # Upstream do not provide signed tarballs.
keydb source: debian-watch-does-not-check-gpg-signature keydb-pro source: debian-watch-does-not-check-gpg-signature

View File

@ -1 +1,2 @@
extend-diff-ignore = "^\.travis\.yml$" extend-diff-ignore = "^\.travis\.yml$"

View File

@ -1,3 +1,3 @@
version=4 version=6
opts=uversionmangle=s/-?(alpha|beta|rc)/~$1/ \ opts=uversionmangle=s/-?(alpha|beta|rc)/~$1/ \
https://github.com/JohnSully/KeyDB/releases .*/archive/(.*).tar.gz https://github.com/JohnSully/KeyDB-Pro/releases .*/archive/(.*).tar.gz

View File

@ -1,14 +1,16 @@
keydb (6:6.0.9-1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (6:6.0.9-1distribution_placeholder) codename_placeholder; urgency=medium
* 6.0.9 Addressing issues 187 - cpu lockup with subkey expire, 190 - missing sentinel binary in keydb-tools. * 6.0.9 Addressing issues 187 - cpu lockup with subkey expire, 190 - missing sentinel binary in keydb-tools.
* FLASH performance updates, including updating client handling to mitigate SSD overload behavior on heavy writes.
* flash_memory parameter has been added to INFO memory
-- Ben Schermel <ben@eqalpha.com> Sun, 07 Jun 2020 18:00:37 +0000 -- Ben Schermel <ben@eqalpha.com> Sun, 07 Jun 2020 18:00:37 +0000
keydb (6:6.0.8-1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (6:6.0.8-1distribution_placeholder) codename_placeholder; urgency=medium
* This is our first release to fully support all Redis 6.0.4 features, including but not limited to: TLS Support (fully supports multithreading!), Client side caching, RESP 3 Support * This is our first release to fully support all Redis 6.0.4 features, including but not limited to: TLS Support (fully supports multithreading!), Client side caching, RESP 3 Support
* KeyDB Has also added the following new features: Improved memory efficiency for short strings, Fastlock autotuning, KeyDB.HRENAME (rename a member of a hash)In addition we've spent a lot of time focussing on stability. * KeyDB Has also added the following new features: Improved memory efficiency for short strings, Fastlock autotuning, KeyDB.HRENAME (rename a member of a hash)In addition we've spent a lot of time focussing on stability.
* The following bug fixes are resolved: 150 - Deadlock in ReplicationFeedMonitors, 170 - KeyDB dying via SIGABORT, 180 - crash after setting maxclients via cmd line, 169 - Write performance of a master dropped sharply when a slave is added * The following bug fixes are resolved: #150 - Deadlock in ReplicationFeedMonitors, #170 - KeyDB dying via SIGABORT, #180 - crash after setting maxclients via cmd line, #169 - Write performance of a master dropped sharply when a slave is added
* In addition untracked issues were resolved: Potential deadlock when entering futex sleep, Pub/Sub Async messages may not be sent in a timely manner when load is low, Excessive logging during failed RREPLAY, KeyDB unresponsive handling clients on different threads during RDB load * In addition untracked issues were resolved: Potential deadlock when entering futex sleep, Pub/Sub Async messages may not be sent in a timely manner when load is low, Excessive logging during failed RREPLAY, KeyDB unresponsive handling clients on different threads during RDB load
* Updated deb package builds to build from source and phasing out init.d. dh_installsystemd from deb helper 11 used where applicable * Updated deb package builds to build from source and phasing out init.d. dh_installsystemd from deb helper 11 used where applicable
* Naming conventions are now updated [ keydbpackage_version-build~distribution_architecture] and master changelog included and maintained * Naming conventions are now updated [ keydbpackage_version-build~distribution_architecture] and master changelog included and maintained
@ -16,34 +18,28 @@ keydb (6:6.0.8-1distribution_placeholder) codename_placeholder; urgency=medium
-- Ben Schermel <ben@eqalpha.com> Mon, 1 Jun 2020 8:00:37 +0000 -- Ben Schermel <ben@eqalpha.com> Mon, 1 Jun 2020 8:00:37 +0000
keydb (5:5.3.3-1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (5:5.1.12-1chl1distribution_placeholder) codename_placeholder; urgency=medium
* 5.3.3 Updating deb source package, naming conventions, and build scripts.
-- Ben Schermel <ben@eqalpha.com> Wed, 06 May 2020 8:00:37 +0000
keydb (5:5.1.12-1chl1distribution_placeholder) codename_placeholder; urgency=medium
* 5.1.1 update. This update fixes several rare deadlock scenarios. Deadlock detection is also added. * 5.1.1 update. This update fixes several rare deadlock scenarios. Deadlock detection is also added.
-- Ben Schermel <ben@eqalpha.com> Fri, 25 Oct 2019 8:00:37 +0000 -- Ben Schermel <ben@eqalpha.com> Fri, 25 Oct 2019 8:00:37 +0000
keydb (5:5.1.11-1chl1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (5:5.1.11-1chl1distribution_placeholder) codename_placeholder; urgency=medium
* 5.1 release. This release includes subkey expires (EXPIREMEMBER/EXPIREMEMBERAT), with updates to PTTL/TTL accordingly. New OBJECT LASTMODIFIED, BITIOP LSHIFT & BITOP RSHIFT commands. See https://docs.keydb.dev/blog/2019/10/20/blog-post/ for detailed review of release. * 5.1 release. This release includes subkey expires (EXPIREMEMBER/EXPIREMEMBERAT), with updates to PTTL/TTL accordingly. New OBJECT LASTMODIFIED, BITIOP LSHIFT & BITOP RSHIFT commands. See https://docs.keydb.dev/blog/2019/10/20/blog-post/ for detailed review of release.
-- Ben Schermel <ben@eqalpha.com> Mon, 21 Oct 2019 8:00:37 +0000 -- Ben Schermel <ben@eqalpha.com> Mon, 21 Oct 2019 8:00:37 +0000
keydb (5:5.0.1-1chl1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (5:5.0.1-1chl1distribution_placeholder) codename_placeholder; urgency=medium
* Arm build now included for bionic package * Arm build now included for bionic package
-- Ben Schermel <ben@eqalpha.com> Wed, 21 Aug 2019 22:58:37 +0000 -- Ben Schermel <ben@eqalpha.com> Wed, 21 Aug 2019 22:58:37 +0000
keydb (5:5.0.0-1chl1distribution_placeholder) codename_placeholder; urgency=medium keydb-pro (5:5.0.0-1chl1distribution_placeholder) codename_placeholder; urgency=medium
* Initial release of KeyDB PPA. This PPA was originally derived from https://launchpad.net/~chris-lea/+archive/ubuntu/redis-server * Initial release of KeyDB PPA. This PPA was originally derived from https://launchpad.net/~chris-lea/+archive/ubuntu/redis-server

View File

@ -88,4 +88,4 @@ ENTRYPOINT ["docker-entrypoint.sh"]
# Expose container port and start KeyDB by default on running container # Expose container port and start KeyDB by default on running container
EXPOSE 6379 EXPOSE 6379
CMD ["keydb-server", "/etc/keydb/keydb.conf"] CMD ["keydb-pro-server", "/etc/keydb/keydb.conf"]

View File

@ -1,6 +1,6 @@
### Generate RPM files for the generated binaries ### Generate RPM files for the generated binaries
After running make to produce keydb binaries you can run the following script to create rpm package After making the binaries you can run the following script
Usage: Usage:
``` ```

View File

@ -30,8 +30,9 @@ sed -i -E "1a\Version : $version" $DIR/keydb_build/keydb.spec
sed -i '3d' $DIR/keydb_build/keydb.spec sed -i '3d' $DIR/keydb_build/keydb.spec
sed -i -E "2a\Release : $release%{?dist}" $DIR/keydb_build/keydb.spec sed -i -E "2a\Release : $release%{?dist}" $DIR/keydb_build/keydb.spec
mkdir -p /root/rpmbuild/BUILDROOT/keydb-$version-$release.$dist.$arch # yum install -y scl-utils centos-release-scl rpm-build
cp -r $DIR/keydb_build/keydb_rpm/* /root/rpmbuild/BUILDROOT/keydb-$version-$release.$dist.$arch/ mkdir -p /root/rpmbuild/BUILDROOT/keydb-pro-$version-$release.$dist.$arch
cp -r $DIR/keydb_build/keydb_rpm/* /root/rpmbuild/BUILDROOT/keydb-pro-$version-$release.$dist.$arch/
rpmbuild -bb $DIR/keydb_build/keydb.spec rpmbuild -bb $DIR/keydb_build/keydb.spec
mv /root/rpmbuild/RPMS/$arch/* $DIR/rpm_files_generated mv /root/rpmbuild/RPMS/$arch/* $DIR/rpm_files_generated

View File

@ -1,5 +1,5 @@
Name : keydb Name : keydb-pro
Version : 5.3.3 Version : 6.0.5
Release : 1%{?dist} Release : 1%{?dist}
Group : Unspecified Group : Unspecified
License : BSD License : BSD
@ -8,7 +8,6 @@ Packager : EQ Alpha Technology
URL : https://keydb.dev URL : https://keydb.dev
Summary : A persistent key-value database Summary : A persistent key-value database
Requires: /bin/awk Requires: /bin/awk
Requires: logrotate Requires: logrotate
Requires(pre): shadow-utils Requires(pre): shadow-utils
@ -28,7 +27,7 @@ getent group keydb &> /dev/null || \
groupadd -r keydb &> /dev/null groupadd -r keydb &> /dev/null
getent passwd keydb &> /dev/null || \ getent passwd keydb &> /dev/null || \
useradd -r -g keydb -d /var/lib/keydb -s /sbin/nologin \ useradd -r -g keydb -d /var/lib/keydb -s /sbin/nologin \
-c 'KeyDB Database Server' keydb &> /dev/null -c 'KeyDB Professional Database Server' keydb &> /dev/null
exit 0 exit 0
#postinstall scriptlet (using /bin/sh): #postinstall scriptlet (using /bin/sh):

View File

@ -1,7 +1,7 @@
[Unit] [Unit]
Description=Advanced key-value store Description=Advanced key-value store
After=network.target After=network.target
Documentation=https://docs.keydb.dev, man:keydb-sentinel(1) Documentation=http://keydb.io/documentation, man:keydb-sentinel(1)
[Service] [Service]
Type=forking Type=forking

View File

@ -5,7 +5,7 @@ Documentation=https://docs.keydb.dev, man:keydb-server(1)
[Service] [Service]
Type=forking Type=forking
ExecStart=/usr/bin/keydb-server /etc/keydb/keydb.conf ExecStart=/usr/bin/keydb-pro-server /etc/keydb/keydb.conf
ExecStop=/bin/kill -s TERM $MAINPID ExecStop=/bin/kill -s TERM $MAINPID
PIDFile=/var/run/keydb/keydb-server.pid PIDFile=/var/run/keydb/keydb-server.pid
TimeoutStopSec=0 TimeoutStopSec=0

View File

@ -92,8 +92,8 @@ public:
for (int hashset = 0; hashset < 2; ++hashset) // rehashing may only be 1 resize behind, so we check up to two slots for (int hashset = 0; hashset < 2; ++hashset) // rehashing may only be 1 resize behind, so we check up to two slots
{ {
if (m_data[itr.idxPrimary] == nullptr) if (m_data[itr.idxPrimary] != nullptr)
continue; {
const auto &vecBucket = *m_data[itr.idxPrimary]; const auto &vecBucket = *m_data[itr.idxPrimary];
auto itrFind = std::find(vecBucket.begin(), vecBucket.end(), key); auto itrFind = std::find(vecBucket.begin(), vecBucket.end(), key);
@ -102,6 +102,7 @@ public:
itr.idxSecondary = itrFind - vecBucket.begin(); itr.idxSecondary = itrFind - vecBucket.begin();
return itr; return itr;
} }
}
// See if we have to check the older slot // See if we have to check the older slot
size_t mask = (hashmask() >> 1); size_t mask = (hashmask() >> 1);
@ -333,7 +334,8 @@ private:
{ {
if (m_data[idxRehash] == nullptr) if (m_data[idxRehash] == nullptr)
continue; continue;
CowPtr<vector_type> spvecT = std::make_shared<vector_type>();
CowPtr<vector_type> spvecT;
std::swap(m_data[idxRehash], spvecT); std::swap(m_data[idxRehash], spvecT);
for (const auto &v : *spvecT) for (const auto &v : *spvecT)