Ran
|
Jobs
1
|
Files
18
|
Run time
1s
|
Badge
Embed ▾
README BADGES
|
push
travis-ci
MB-20494 - optional mossStore StorePersistOptions.NoSync flag When an application calls Store.Persist() with StorePersistOptions.NoSync of false (the default), then both before and after the bytes of a file-footer have been written/appended to the end of a moss store file, mossStore will invoke the file's Sync() method. This helps ensure that all the bytes of the file (including key-val segments), up to and including the last written file-footer, have been fsync'ed to disk. In contrast, for the case when StorePersistOptions.NoSync is true (e.g., skip the fsync), then mossStore's append-only approach *might* seem like it's safe. After all, previously written/appended bytes in the file are never mutated by mossStore. However, potential filesystem reordering of written blocks might affect which bytes are physically written down to disk first. Imagine, for example, if the filesystem chooses to write the blocks of a file-footer first, before writing out any key-val segment data. Then, imagine there's a power loss and server restart. On reopening the file, mossStore will encounter a valid file-footer, but that file-footer is referring to file positions of data that have not actually been written yet. Using StorePersistOptions.NoSync of false avoids that corruption case. Change-Id: I12ce33395 Reviewed-on: http://review.couchbase.org/67449 Reviewed-by: Marty Schoch <marty.schoch@gmail.com> Tested-by: Steve Yen <steve.yen@gmail.com>
1976 of 2306 relevant lines covered (85.69%)
10713.8 hits per line
ID | Job ID | Ran | Files | Coverage | |
---|---|---|---|---|---|
1 | 97.1 | 18 |
85.69 |
Travis Job 97.1 |
Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
---|