Commit fe92da8c authored by Manuela Kuhn's avatar Manuela Kuhn
Browse files

Merge branch 'hotfix-2.1.3' into develop

Conflicts:
	src/sender/dataFetchers/getFromFile.py
parents 6684e2f0 583e4bc9
# API to communicate with a data transfer unit
__version__ = '2.1.2'
__version__ = '2.1.3'
import zmq
import socket
......
......@@ -94,13 +94,13 @@ def getMetadata (log, metadata, chunkSize, localTarget = None):
def sendData (log, targets, sourceFile, targetFile, metadata, openConnections, context, prop):
if not targets:
prop["removeFlag"] = False
return
targets_data = [i for i in targets if i[2] == "data"]
chunkSize = metadata[ "chunkSize" ]
if not targets_data:
prop["removeFlag"] = True
return
targets_data = [i for i in targets if i[2] == "data"]
chunkSize = metadata[ "chunkSize" ]
chunkNumber = 0
sendError = False
......@@ -134,17 +134,16 @@ def sendData (log, targets, sourceFile, targetFile, metadata, openConnections, c
except:
log.error("Unable to pack multipart-message for file " + str(sourceFile), exc_info=True)
if targets_data:
#send message to data targets
try:
__sendToTargets(log, targets_data, sourceFile, targetFile, openConnections, None, chunkPayload, context)
log.debug("Passing multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")...done.")
#send message to data targets
try:
__sendToTargets(log, targets_data, sourceFile, targetFile, openConnections, None, chunkPayload, context)
log.debug("Passing multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")...done.")
except DataHandlingError:
log.error("Unable to send multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")", exc_info=True)
sendError = True
except:
log.error("Unable to send multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")", exc_info=True)
except DataHandlingError:
log.error("Unable to send multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")", exc_info=True)
sendError = True
except:
log.error("Unable to send multipart-message for file " + str(sourceFile) + " (chunk " + str(chunkNumber) + ")", exc_info=True)
chunkNumber += 1
......
__version__ = '2.1.2'
__version__ = '2.1.3'
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment