assistant: Run transferkeys as batch jobs.
This commit is contained in:
parent
4882a611e5
commit
2711d13d55
2 changed files with 5 additions and 1 deletions
|
@ -12,6 +12,7 @@ module Assistant.TransferrerPool where
|
||||||
import Assistant.Common
|
import Assistant.Common
|
||||||
import Assistant.Types.TransferrerPool
|
import Assistant.Types.TransferrerPool
|
||||||
import Logs.Transfer
|
import Logs.Transfer
|
||||||
|
import Utility.Batch
|
||||||
|
|
||||||
#ifndef mingw32_HOST_OS
|
#ifndef mingw32_HOST_OS
|
||||||
import qualified Command.TransferKeys as T
|
import qualified Command.TransferKeys as T
|
||||||
|
@ -63,9 +64,11 @@ mkTransferrer program = do
|
||||||
, Param "--readfd", Param $ show tread
|
, Param "--readfd", Param $ show tread
|
||||||
, Param "--writefd", Param $ show twrite
|
, Param "--writefd", Param $ show twrite
|
||||||
]
|
]
|
||||||
|
{- It runs as a batch job. -}
|
||||||
|
(program', params') <- toBatchCommand (program, params)
|
||||||
{- It's put into its own group so that the whole group can be
|
{- It's put into its own group so that the whole group can be
|
||||||
- killed to stop a transfer. -}
|
- killed to stop a transfer. -}
|
||||||
(_, _, _, pid) <- createProcess (proc program $ toCommand params)
|
(_, _, _, pid) <- createProcess (proc program' $ toCommand params')
|
||||||
{ create_group = True }
|
{ create_group = True }
|
||||||
closeFd twrite
|
closeFd twrite
|
||||||
closeFd tread
|
closeFd tread
|
||||||
|
|
1
debian/changelog
vendored
1
debian/changelog
vendored
|
@ -4,6 +4,7 @@ git-annex (5.20131131) UNRELEASED; urgency=low
|
||||||
it will read the full contents of files in the tree.
|
it will read the full contents of files in the tree.
|
||||||
* assistant: Batch jobs are now run with ionice and nocache, when
|
* assistant: Batch jobs are now run with ionice and nocache, when
|
||||||
those commands are available.
|
those commands are available.
|
||||||
|
* assistant: Run transferkeys as batch jobs.
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Sun, 01 Dec 2013 13:57:58 -0400
|
-- Joey Hess <joeyh@debian.org> Sun, 01 Dec 2013 13:57:58 -0400
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue