Permalink
Browse files

Aborting on Background Thread I/O errors as well

Upstream commit ID : fb-mysql-5.6.35/0e662d8627a835a180e82602d8ca6b8c56cdffd9
PS-4476 : Merge prod201801

Summary:
When hitting rocksdb::Status != ok, MyRocks aborted
on non-background threads, but did not abort when BG threads hit it.
This may result in data loss, when BG thread hit EIO on fsync but
did succeeded in following attempts. This diff changes the behavior
so that MyRocks aborts as well on BG errors.
Closes facebook/mysql-5.6#816

Differential Revision: D7733224

Pulled By: yoshinorim

fbshipit-source-id: 4a7d3fb
  • Loading branch information...
yoshinorim authored and georgelorchpercona committed Apr 24, 2018
1 parent d188679 commit d0d5635573ebc4f157e36a989d14f7ee6f87c410
Showing with 3 additions and 0 deletions.
  1. +3 −0 storage/rocksdb/ha_rocksdb.cc
@@ -12222,6 +12222,9 @@ void rdb_handle_io_error(const rocksdb::Status status,
}
case RDB_IO_ERROR_BG_THREAD: {
rdb_log_status_error(status, "BG thread failed to write to RocksDB");
/* NO_LINT_DEBUG */
sql_print_error("MyRocks: aborting on BG write error.");
abort();
break;
}
case RDB_IO_ERROR_GENERAL: {

0 comments on commit d0d5635

Please sign in to comment.