Loading client/vos_storage +5 −5 Original line number Diff line number Diff line Loading @@ -98,10 +98,6 @@ class VOSStorage(AMQPClient): print("! from the database. !") print("! The mount point on the transfer node will not be removed, you !") print("! must do it manually. !") print("! Anyway, you MUST BE AWARE that all the VOSpace nodes affected !") print("! by this operation will not be accessible anymore from now on. !") print("! We strongly recommend to move all the data to another storage !") print("! location and update the database accordingly. !") print("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!") print() confirm = None Loading @@ -119,8 +115,12 @@ class VOSStorage(AMQPClient): sys.exit("\nFATAL: Malformed response, storage confirmation expected.\n") elif confirmResponse["responseType"] == "STORAGE_DEL_DONE": print("\nStorage location deleted successfully!\n") elif confirmResponse["responseType"] == "ERROR": errorCode = confirmResponse["errorCode"] errorMsg = confirmResponse["errorMsg"] sys.exit(f"\nError code: {errorCode}\nError message: {errorMsg}\n") else: sys.exit("FATAL: Unknown response type.\n") sys.exit("\nFATAL: Unknown response type.\n") elif storeResponse["responseType"] == "ERROR": errorCode = storeResponse["errorCode"] errorMsg = storeResponse["errorMsg"] Loading transfer_service/storage_amqp_server.py +9 −5 Original line number Diff line number Diff line Loading @@ -69,14 +69,18 @@ class StorageAMQPServer(AMQPServer): if self.storageAck: self.storageAck = False self.dbConn.connect() self.dbConn.deleteStorage(self.storageId) result = self.dbConn.deleteStorage(self.storageId) self.dbConn.disconnect() if result: response = { "responseType": "STORAGE_DEL_DONE" } else: response = { "responseType": "ERROR", "errorCode": 4, "errorMsg": "This storage location contains some VOSpace nodes. Please, move them to anoter location." } else: response = { "responseType": "ERROR", "errorCode": 5, "errorMsg": "Store request not acknowledged." } elif requestBody["requestType"] == "STORAGE_LST": Loading @@ -89,7 +93,7 @@ class StorageAMQPServer(AMQPServer): else: response = { "responseType": "ERROR", "errorCode": 5, "errorCode": 6, "errorMsg": "Unkown request type." } return response Loading Loading
client/vos_storage +5 −5 Original line number Diff line number Diff line Loading @@ -98,10 +98,6 @@ class VOSStorage(AMQPClient): print("! from the database. !") print("! The mount point on the transfer node will not be removed, you !") print("! must do it manually. !") print("! Anyway, you MUST BE AWARE that all the VOSpace nodes affected !") print("! by this operation will not be accessible anymore from now on. !") print("! We strongly recommend to move all the data to another storage !") print("! location and update the database accordingly. !") print("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!") print() confirm = None Loading @@ -119,8 +115,12 @@ class VOSStorage(AMQPClient): sys.exit("\nFATAL: Malformed response, storage confirmation expected.\n") elif confirmResponse["responseType"] == "STORAGE_DEL_DONE": print("\nStorage location deleted successfully!\n") elif confirmResponse["responseType"] == "ERROR": errorCode = confirmResponse["errorCode"] errorMsg = confirmResponse["errorMsg"] sys.exit(f"\nError code: {errorCode}\nError message: {errorMsg}\n") else: sys.exit("FATAL: Unknown response type.\n") sys.exit("\nFATAL: Unknown response type.\n") elif storeResponse["responseType"] == "ERROR": errorCode = storeResponse["errorCode"] errorMsg = storeResponse["errorMsg"] Loading
transfer_service/storage_amqp_server.py +9 −5 Original line number Diff line number Diff line Loading @@ -69,14 +69,18 @@ class StorageAMQPServer(AMQPServer): if self.storageAck: self.storageAck = False self.dbConn.connect() self.dbConn.deleteStorage(self.storageId) result = self.dbConn.deleteStorage(self.storageId) self.dbConn.disconnect() if result: response = { "responseType": "STORAGE_DEL_DONE" } else: response = { "responseType": "ERROR", "errorCode": 4, "errorMsg": "This storage location contains some VOSpace nodes. Please, move them to anoter location." } else: response = { "responseType": "ERROR", "errorCode": 5, "errorMsg": "Store request not acknowledged." } elif requestBody["requestType"] == "STORAGE_LST": Loading @@ -89,7 +93,7 @@ class StorageAMQPServer(AMQPServer): else: response = { "responseType": "ERROR", "errorCode": 5, "errorCode": 6, "errorMsg": "Unkown request type." } return response Loading