diff options
author | Daniel Black <daniel@mariadb.org> | 2022-03-10 18:15:25 +1100 |
---|---|---|
committer | Daniel Black <daniel@mariadb.org> | 2022-03-12 09:47:53 +1100 |
commit | d78173828e9f69ab3f6a406cb38f323261171076 (patch) | |
tree | 0b36de9fc5bef5753e1fb35d5ca6fdf33385a439 /include | |
parent | 4cfb6eddcd1b5d09be706bf558927624586af051 (diff) | |
download | mariadb-git-d78173828e9f69ab3f6a406cb38f323261171076.tar.gz |
MDEV-27900: aio handle partial reads/writes
As btrfs showed, a partial read of data in AIO /O_DIRECT circumstances can
really confuse MariaDB.
Filipe Manana (SuSE)[1] showed how database programmers can assume
O_DIRECT is all or nothing.
While a fix was done in the kernel side, we can do better in our code by
requesting that the rest of the block be read/written synchronously if
we do only get a partial read/write.
Per the APIs, a partial read/write can occur before an error, so
reattempting the request will leave the caller with a concrete error to
handle.
[1] https://lore.kernel.org/linux-btrfs/CABVffENfbsC6HjGbskRZGR2NvxbnQi17gAuW65eOM+QRzsr8Bg@mail.gmail.com/T/#mb2738e675e48e0e0778a2e8d1537dec5ec0d3d3a
Also spell synchronously correctly in other files.
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions