diff options
author | Eric Milkie <milkie@10gen.com> | 2012-06-06 16:25:07 -0400 |
---|---|---|
committer | Eric Milkie <milkie@10gen.com> | 2012-06-07 08:54:22 -0400 |
commit | 5e41dd2b7bde5cfb48e9e90817aa76348d08b14c (patch) | |
tree | 15728a9d3733b5df3cea886edf773929c75c8e39 /src/mongo/db/commands/fsync.h | |
parent | 9af1f00e6d9b7696cb78460885ece9fd790dcee9 (diff) | |
download | mongo-5e41dd2b7bde5cfb48e9e90817aa76348d08b14c.tar.gz |
SERVER-4243 prevent write lock in network rs thread from blocking readers during fsync
Diffstat (limited to 'src/mongo/db/commands/fsync.h')
-rw-r--r-- | src/mongo/db/commands/fsync.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/mongo/db/commands/fsync.h b/src/mongo/db/commands/fsync.h new file mode 100644 index 00000000000..2e57cbda403 --- /dev/null +++ b/src/mongo/db/commands/fsync.h @@ -0,0 +1,22 @@ +/** + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ + +#pragma once + +namespace mongo { + // Use this for blocking during an fsync-and-lock + extern SimpleMutex filesLockedFsync; + bool lockedForWriting(); +} |