This commit implements file locks for unix-based systems and windows
systems. This is done by using platform-specific `__sys` modules for
locking, trying to lock and unlocking files.
A build script was added for unix-systems that make use of the
flock-posix.c file
This commit removes the fscposix.c file and begins implementing native
file locking mechanisms for each platform (supported platforms)
BSD-style `flock`s were added
This commit adds a basic implementation of POSIX advisory record locking
which sets a lock on the `data.bin` file when the database server starts
and releases the lock when it terminates. This is just done for
compliance to let other processes know that we don't want them to use
the file.
However, the result depends entirely on the process that wants to do
'something' with the file. It is the responsibility of the process to
ensure that it respects the file lock.
Also, exclusive locks aren't perfect on Linux, so we can't rely on them.
See discussion #123 for more information.
Instead of unwrapping furiously right away, this commit makes sky-bench
first run a ping test (HEYA) to check if everything is all right.
If that is the case indeed, then we continue to run the benches, else
we terminate the program.
This has been discussed in #119
This variant is absolutely redundant as we're just ignoring the entire
buffer and not just a part of it
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
This closes#107, closes#108 and closes#109.
The configuration template was updated to include TLS/SSL and the
corresponding tests were also updated.
It also renames `sdb` to `skyd` for streamlining binary names.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
As per the runner docs Perl is already installed on the runners.
This is why explicit setup is not required.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
* Checkout the PR branch if triggered by a PR
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
* Use `cmd` as the shell on Windows to fix builds
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
#104 did this for pushes; this will do it for releases.
* Fix Windows release script
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
* No need to checkout to head.ref for PRs
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
This commit uses a Regex match iterator along with a few replace
operations to enable the parsing of quoted strings from arguments.
Previously, we simply ran a `split_whitespace()` to get the parts of the
ActionGroup, but now we're using this new Regex which enables arguments
like: 'SET me "sayan spaced"' to be passed and validated.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
This commit now checks if the second value passed to MKSNAP points
to any parent/root directory before performing any action.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
This call is necessary as SUPDATE returns Nil even if one of the keys
don't exist.
Also, this was note added to the actiondoc.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
Just like fd139a9dda, this skip is not
needed as we're already breaking from the loop.
Also, all remaining unsafe blocks that were left in
2e85fbb831 have been explained.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
The skipping of the next value is absolutely unneeded as we're already
exiting the loop when the hash table contains the key.
Thus, this op was removed.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>
Dependencies were upgraded
A mirror sync badge was added. Also README was revised and workflow badge was fixed.
Signed-off-by: Sayan Nandan nandansayan@outlook.com
`openssl-sys` isn't required anymore; it was added in the `ssl` branch
during the development phase.
Signed-off-by: Sayan Nandan <nandansayan@outlook.com>