Added code to record remote file sizes early to reduce deletion of files that are uploaded correctly.
This commit is contained in:
@@ -557,13 +557,13 @@ namespace Duplicati.Library.Main.Operation
|
||||
m_database.UpdateRemoteVolume(m_blockvolume.RemoteFilename, RemoteVolumeState.Uploading, -1, null, m_transaction);
|
||||
m_blockvolume.Close();
|
||||
UpdateIndexVolume();
|
||||
|
||||
|
||||
m_backend.Put(m_blockvolume, m_indexvolume);
|
||||
|
||||
using(new Logging.Timer("CommitUpdateRemoteVolume"))
|
||||
m_transaction.Commit();
|
||||
m_transaction = m_database.BeginTransaction();
|
||||
|
||||
m_backend.Put(m_blockvolume, m_indexvolume);
|
||||
|
||||
|
||||
m_blockvolume = null;
|
||||
m_indexvolume = null;
|
||||
}
|
||||
@@ -604,12 +604,12 @@ namespace Duplicati.Library.Main.Operation
|
||||
else
|
||||
{
|
||||
m_database.UpdateRemoteVolume(m_filesetvolume.RemoteFilename, RemoteVolumeState.Uploading, -1, null, m_transaction);
|
||||
m_backend.Put(m_filesetvolume);
|
||||
|
||||
using(new Logging.Timer("CommitUpdateRemoteVolume"))
|
||||
m_transaction.Commit();
|
||||
m_transaction = m_database.BeginTransaction();
|
||||
|
||||
m_backend.Put(m_filesetvolume);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1038,13 +1038,14 @@ namespace Duplicati.Library.Main.Operation
|
||||
m_backend.FlushDbMessages(m_database, m_transaction);
|
||||
m_backendLogFlushTimer = DateTime.Now.Add(FLUSH_TIMESPAN);
|
||||
|
||||
m_backend.Put(m_blockvolume, m_indexvolume);
|
||||
m_blockvolume = null;
|
||||
m_indexvolume = null;
|
||||
|
||||
using(new Logging.Timer("CommitAddBlockToOutputFlush"))
|
||||
m_transaction.Commit();
|
||||
m_transaction = m_database.BeginTransaction();
|
||||
|
||||
m_backend.Put(m_blockvolume, m_indexvolume);
|
||||
m_blockvolume = null;
|
||||
m_indexvolume = null;
|
||||
}
|
||||
|
||||
m_blockvolume = new BlockVolumeWriter(m_options);
|
||||
|
||||
Reference in New Issue
Block a user