efficient but unsafe journal file append
This is only for checking performance, it's not safe. Sponsored-by: Dartmouth College's DANDI project
This commit is contained in:
parent
2e6e9876e3
commit
de18d92de6
2 changed files with 14 additions and 8 deletions
|
@ -414,7 +414,7 @@ data ChangeOrAppend t = Change t | Append t
|
|||
-}
|
||||
changeOrAppend :: Journalable content => RegardingUUID -> RawFilePath -> (L.ByteString -> ChangeOrAppend content) -> Annex ()
|
||||
changeOrAppend ru file f = lockJournal $ \jl -> do
|
||||
oldc <- getToChange jl ru file
|
||||
oldc <- getToChange ru file
|
||||
case f oldc of
|
||||
Change newc -> set jl ru file newc
|
||||
Append toappend -> append jl ru file oldc toappend
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue