Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
cta
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Harbor Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dCache
cta
Commits
3a2c71a1
Commit
3a2c71a1
authored
10 years ago
by
Giuseppe Lo Presti
Browse files
Options
Downloads
Patches
Plain Diff
Fixed handling of transfers when they complete
parent
7aeb3c59
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
castor/scheduler/diskmanager/moverhandler.py
+10
-6
10 additions, 6 deletions
castor/scheduler/diskmanager/moverhandler.py
with
10 additions
and
6 deletions
castor/scheduler/diskmanager/moverhandler.py
+
10
−
6
View file @
3a2c71a1
...
...
@@ -147,10 +147,14 @@ class MoverReqHandlerThread(threading.Thread):
cksumType
=
'
AD
'
# find transfer in runningTransfers, raise KeyError if not found
t
=
self
.
runningTransfers
.
get
(
transferid
)
if
type
(
t
.
process
)
!=
subprocess
.
Popen
:
# movers for which a process exists need to be kept, so that
# runningTransfers.poll() can clean them up. All others can be
# dropped from the list of running transfers at this time.
if
type
(
t
)
==
TapeTransfer
:
# acknowledge that the transfer completed and return
self
.
runningTransfers
.
remove
(
t
)
return
0
if
t
.
process
==
None
or
t
.
process
==
0
:
# this transfer has no subprocess attached to it (case of xroot and d2d src transfers),
# so it can be dropped from the list of running transfers at this time.
# Others are kept so that runningTransfers.poll() 'bcan clean them up.
self
.
runningTransfers
.
remove
(
t
)
# get the admin timeout
timeout
=
self
.
config
.
getValue
(
'
TransferManager
'
,
'
AdminTimeout
'
,
5
,
float
)
...
...
@@ -184,8 +188,8 @@ class MoverReqHandlerThread(threading.Thread):
timeout
=
timeout
)
t
.
ended
=
True
return
0
elif
t
.
transfer
.
transferType
==
TransferType
.
D2DSRC
or
type
(
t
)
==
TapeTransfer
:
# nothing else to be done for sources
and tape transfers
elif
t
.
transfer
.
transferType
==
TransferType
.
D2DSRC
:
# nothing else to be done for
d2d
sources
return
0
else
:
raise
ValueError
(
'
Invalid transfer type %d for transfer %s
'
%
(
t
.
transfer
.
transferType
,
transferid
))
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment