1
0
This commit is contained in:
Scott E. Graves
2017-02-24 14:28:50 -06:00
parent 5ea1909493
commit 6135c1ffc9

View File

@@ -261,16 +261,11 @@ UploadStatus CUploadManager::GetUploadStatus(const String& siaPath)
// real source path. The process will then start over again as if the file was new.
// If the file has been fully uploaded, the hidden file should not exist, so rename will not occur; however, the file
// will be deleted from Sia and treated as new.
// Uploads will always use the real file. User i/o will occur against the hidden file only temporarily. Since upload will take
// Uploads will always use the real file. User i/o will occur against the hidden file temporarily. Since upload will take
// longer to handle than a normal file copy, this seems to be the best compromise for performance.
//
// ERROR SCENARIOS
// While copy is active, point to normal file.
// After copy, use temp file as real file until upload is complete
// This allows modifications to the file to occur in a more timely manner.
// Error Scenarios:
// Crash before db update to status copying - file will be re-uploaded automatically, if complete; otherwise, deleted
// Need to keep track of files as being copied and then there status
// Crash before copy begins - on startup, check for copying status with no .siadrive
// Crash during copy - on startup, check for copying status and delete .siadrive
// Crash after copy but before db update - on startup, check for copying status and delete .siadrive