Kelvin Mwinuka
59143b4cd5
Added multi-database support for loggin and restoring in log engine.
...
Added multi-database support for preamble snapshots and restoration in preamble engine.
Added multi-database support for aof engine.
Removed buffered channel from log and aof engines. Command logging is now synchronous.
Added multi-database support for the raft layer's data replication.
2024-07-01 06:06:26 +08:00
Kelvin Mwinuka
182195ebc3
Added multi-database support to snapshot module
2024-07-01 06:05:46 +08:00
Kelvin Mwinuka
93a165e9f9
Added support for HELLO command.
...
Load modules build from Dockerfile.dev into instances from docker-compose.yml.
Fixed user loading from config file in ACL module.
2024-07-01 06:05:07 +08:00
Kelvin Mwinuka
ddea7ab127
Added tracking for embedded client connection info. Moved logic to determine which connection info to use into the handleCommand function.
2024-07-01 06:05:07 +08:00
Kelvin Clement Mwinuka
c4b42854b1
Initialise volatile key tracker on startup. Create a database if it does not exist when trying to set a value.
2024-07-01 06:05:07 +08:00
Kelvin Mwinuka
295ef9dd52
Added multi-database support in updateKeysInCache method
2024-07-01 06:04:31 +08:00
Kelvin Mwinuka
663c097be8
Added support for multiple databases on the evictKeysWithExpiredTTL function
2024-07-01 06:04:31 +08:00
Kelvin Mwinuka
33d7eb2f6e
Caches and volatile key tracking slices for each database.
2024-07-01 06:04:31 +08:00
Kelvin Mwinuka
d6162b23f6
Added database support for keyspace methods. Commented cache methods and standalone persistence initialisation until their implementations support databases as well.
2024-07-01 06:04:31 +08:00
Kelvin Clement Mwinuka
9745270b40
Added placeholders for adding protocol and database version in raft replication flow
2024-07-01 06:04:31 +08:00
Kelvin Clement Mwinuka
cb99ff8993
rewriteAOF method in echovault.go now handles the rewrite synchronously. Removed newline character in Write method of append store. Added test case for REWRITEAOF command and restore from AOF.
2024-06-09 02:28:03 +08:00
Kelvin Clement Mwinuka
7661ab1c92
Close TTL ticker after shutdown
2024-06-08 23:23:26 +08:00
Kelvin Clement Mwinuka
ee13c29c9a
Removed debug print statements in acl.go file
2024-06-05 21:44:00 +08:00
Kelvin Clement Mwinuka
bc6537ad8f
Replaces use of time.Sleep with time.Ticker in echovault and echovault tests
2024-06-02 17:34:20 +08:00
Kelvin Clement Mwinuka
166e9a81fb
Shutdown raft nodes from the last one to the first one in echovault tests. This is to ensure the leader node is shutdown last.
2024-06-02 15:44:09 +08:00
Kelvin Clement Mwinuka
bbc53ffee5
Use time.After instead of custom clock wrappet for TTL key eviction when creating a new EchoVault instance.
2024-06-02 15:29:22 +08:00
Kelvin Clement Mwinuka
99be0fd4f0
Fixed data race issue when reading and writing ACL user data. Now, a write-lock is acquired before modifying the connection object as well in addition to the users list.
2024-06-02 15:06:12 +08:00
Kelvin Clement Mwinuka
393700b71d
Updated TLS/mTLS listener log
2024-05-31 19:47:11 +08:00
Kelvin Clement Mwinuka
c7560ce9dd
Updated all test suites to include connection and server shutdown on cleanup.
2024-05-31 01:30:18 +08:00
Kelvin Clement Mwinuka
6f8511632e
Close client connection on quit command
2024-05-30 20:01:24 +08:00
Kelvin Clement Mwinuka
502e804459
Removed logic to get unexported methods from the echovault package in all tests.
2024-05-30 19:33:01 +08:00
Kelvin Clement Mwinuka
93a616c5c1
Updated RAFT layer to use new keyspace methods. Fixed API methods for HSET and SINTERCARD to match new key overwriting behaviour.
2024-05-26 15:49:51 +08:00
Kelvin Clement Mwinuka
abee9ea858
Uncommented AddCommand method
2024-05-26 15:26:04 +08:00
Kelvin Clement Mwinuka
e3ecc42454
Updated string commands package to use new keyspace methods and resp connection for tests
2024-05-26 15:04:57 +08:00
Kelvin Clement Mwinuka
edf82886bd
Updated sorted_set commands package to use new keyspace methods and its tests to use resp connection instead of calling handler directly
2024-05-26 14:48:13 +08:00
Kelvin Clement Mwinuka
15191dccee
Implemented new param methods and testing through resp connection in set commands package
2024-05-26 08:41:29 +08:00
Kelvin Clement Mwinuka
af8a002ba5
Updated list command tests to use resp connection instead of directly invoking internal method
2024-05-26 01:59:44 +08:00
Kelvin Clement Mwinuka
926a008c23
Updated generic and hash package tests to use tcp connection instead of calling the handler directly
2024-05-24 13:40:40 +08:00
Kelvin Clement Mwinuka
43361cdd42
Updated keyspace methods' signatures and made them all private. Ditched lock-per-key for a store-wide rwmutex. Updated HandlerFuncParams to match new keyspace method signatures.
2024-05-22 22:44:59 +08:00
Kelvin Clement Mwinuka
d28bda98bb
Added makefile command to build modules for admins module tests.
...
Implemented more sensible logic for testing the COMMANDS command instead of just printing each returned command.
Implemented tests for MODULE LOAD, MODULE UNLOAD, and MODULE LIST commands.
Implemented testdata folder cleanup after finishing admin command tests.
2024-05-08 23:17:45 +08:00
Kelvin Clement Mwinuka
baf5f3d5da
Return error from preamble restore method instead of just logging it. Implemented test for AOF engine persist and restore flow.
2024-05-05 01:30:04 +08:00
Kelvin Clement Mwinuka
0f6ae1c8ac
Implemented LoadModules method to load external modules at runtime.
...
Implemented UnloadModules method to remove modules at runtime.
Implemented ListModules method to list the current loaded modules.
Implemented "MODULE LOAD", "MODULE UNLOAD", and "MODULE LIST" commands.
2024-05-03 11:57:21 +08:00
Kelvin Clement Mwinuka
276ca0fb63
Trigger LoadModule methods in NewEchovault function using module paths from the configuration
2024-05-02 09:35:43 +08:00
Kelvin Clement Mwinuka
1a7951f262
Removed EchoVault interface param from raft Opts
2024-04-30 09:36:28 +08:00
Kelvin Clement Mwinuka
281c4f27a7
Added godoc commends for embedded methods and types to extend commands. Moved constants to internal directory
2024-04-29 15:20:10 +08:00
Kelvin Clement Mwinuka
972cbe0a4f
Renamed command API methods to use CamelCase
2024-04-28 07:22:39 +08:00
Kelvin Clement Mwinuka
97f4617d86
Moved all packages from /pkg directory to the root directory. Deleted /pkg directory. Pass keyspace functions to raft package instead of an EchoVault instance. This removes dependency on the echovault pakage from the raft package.
2024-04-28 00:37:45 +08:00