Skip to content

Commit

Permalink
[Python] Use values from the environment for add_job defaults
Browse files Browse the repository at this point in the history
  • Loading branch information
amadio committed Nov 1, 2024
1 parent c838699 commit 70e0fc9
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions bindings/python/libs/client/copyprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
from pyxrootd import client
from XRootD.client.url import URL
from XRootD.client.responses import XRootDStatus
from .env import EnvGetInt, EnvGetString

class ProgressHandlerWrapper(object):
"""Internal progress handler wrapper to convert parameters to friendly
Expand Down Expand Up @@ -83,17 +84,17 @@ def add_job(self,
checksumtype = '',
checksumpreset = '',
dynamicsource = False,
chunksize = 8388608,
parallelchunks = 4,
inittimeout = 600,
tpctimeout = 1800,
chunksize = EnvGetInt('CPChunkSize'),
parallelchunks = EnvGetInt('CPParallelChunks'),
inittimeout = EnvGetInt('CPInitTimeout'),
tpctimeout = EnvGetInt('CPTPCTimeout'),
rmBadCksum = False,
cptimeout = 0,
xrateThreshold = 0,
cptimeout = EnvGetInt('CPTimeout'),
xrateThreshold = EnvGetInt('XRateThreshold'),
xrate = 0,
retry = 0,
retry = EnvGetInt('CpRetry'),
cont = False,
rtrplc = "force" ):
rtrplc = EnvGetString('CpRetryPolicy') ):
"""Add a job to the copy process.
:param source: original source URL
Expand Down

0 comments on commit 70e0fc9

Please sign in to comment.