Commit Graph

24 Commits

Author SHA1 Message Date
Kelvin Mwinuka
8ecb9ab54f Restore multi-database state in FSM in the raft layer 2024-07-01 06:06:51 +08:00
Kelvin Mwinuka
4dd3aa40b2 quit 2024-07-01 06:05:19 +08:00
Kelvin Mwinuka
21aabda04d Moved AUTH command from the acl module to the connection module. Added echo command to the list of commands that are skipped on ACL authorization. 2024-07-01 06:05:07 +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 Clement Mwinuka
ee13c29c9a Removed debug print statements in acl.go file 2024-06-05 21:44:00 +08:00
Kelvin Clement Mwinuka
66b2842e11 Implemented tests for ACL permissions 2024-06-02 22:52:02 +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
dd323f66b5 Renamed config variable name in echovault_test.go 2024-06-02 04:19:11 +08:00
Kelvin Clement Mwinuka
d4506ce54d Added tests for ACL LOAD and ACL SAVE commands. 2024-06-02 04:01:45 +08:00
Kelvin Clement Mwinuka
bdfaf5446a Updated logic for loading acl config. If the config file does not exist, it will be created. 2024-06-01 22:16:16 +08:00
Kelvin Clement Mwinuka
4d56ee9083 Use log.Println instead of log.Fatal upon failing to load ACl config 2024-06-01 20:27:51 +08:00
Kelvin Clement Mwinuka
fdb3b87362 Implemented ACL tests using test suites and server cleanup functions. 2024-06-01 01:08:36 +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
0108444d69 Replaced fmt.Println statements with log.Println.
Return "empty command" error from handleCommand method if an empty command is passed to the server.
Wait until connection is no longer nil in acl package tests.
2024-05-27 11:45:48 +08:00
Kelvin Clement Mwinuka
a9c11adcd6 Fixed users unlock in ACL LOAD command handler 2024-05-19 04:28:06 +08:00
Kelvin Clement Mwinuka
c634b1b20e Return ok boolean instead of OK string in embedded api methods that return ok status. Updated tests to match new return types 2024-05-18 22:49:21 +08:00
Kelvin Clement Mwinuka
193871ec72 Removed test folder and moved all commands tests to their respective internal modules. Moved api tests into echovault package. This change has been made because the speratate test folder is not idiomatic and caused test coverage report to not be generated. 2024-05-04 17:45:10 +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
1d56e9839b Implemented tests for AddCommand, ExecuteCommand and RemoveCommand methods 2024-04-28 10:43:46 +08:00
Kelvin Clement Mwinuka
c241cc07b1 Renamed *AccessKey type to better represent the response on *KeyExtractionFunc types 2024-04-28 07:34:34 +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
Kelvin Clement Mwinuka
6ad3b7baab Exported EchoVault interface now onlu contains the keyspace methods. All other methods are private. Private methods are accessed using the reflect package in the test folder 2024-04-26 02:33:35 +08:00
Kelvin Clement Mwinuka
b6ddb43a49 Removed duplicate imports for set, sorted_set, pubsub and acl modules. Moved /modules from /pkg to /internal. Delted commands package: Commands will now be automatically loaded when an EchoVault instance is initialised. 2024-04-24 22:37:16 +08:00