OPTION(filestore_blackhole, OPT_BOOL, false) // drop any new transactions on the floor
OPTION(filestore_dump_file, OPT_STR, "") // file onto which store transaction dumps
OPTION(filestore_kill_at, OPT_INT, 0) // inject a failure at the n'th opportunity
+OPTION(filestore_inject_stall, OPT_INT, 0) // artificially stall for N seconds in op queue thread
OPTION(filestore_fail_eio, OPT_BOOL, true) // fail/crash on EIO
OPTION(journal_dio, OPT_BOOL, true)
OPTION(journal_aio, OPT_BOOL, false)
void FileStore::_do_op(OpSequencer *osr)
{
+ // inject a stall?
+ if (g_conf->filestore_inject_stall) {
+ int orig = g_conf->filestore_inject_stall;
+ dout(5) << "_do_op filestore_inject_stall " << orig << ", sleeping" << dendl;
+ for (int n = 0; n < g_conf->filestore_inject_stall; n++)
+ sleep(1);
+ g_conf->set_val("filestore_inject_stall", "0");
+ dout(5) << "_do_op done stalling" << dendl;
+ }
+
osr->apply_lock.Lock();
Op *o = osr->peek_queue();
apply_manager.op_apply_start(o->op);