mirror of
https://github.com/abraunegg/onedrive
synced 2024-06-15 20:25:18 +02:00
Update sync.d
* Update when deltaLinkCache is set * Update logging output when deltaLinkCache is used
This commit is contained in:
parent
4af2420944
commit
26f92b6191
|
@ -886,12 +886,12 @@ class SyncEngine {
|
||||||
|
|
||||||
// Store this currentDeltaLink as latestDeltaLink
|
// Store this currentDeltaLink as latestDeltaLink
|
||||||
latestDeltaLink = deltaChanges["@odata.deltaLink"].str;
|
latestDeltaLink = deltaChanges["@odata.deltaLink"].str;
|
||||||
}
|
|
||||||
|
|
||||||
// Update deltaLinkCache
|
// Update deltaLinkCache
|
||||||
deltaLinkCache.driveId = driveIdToQuery;
|
deltaLinkCache.driveId = driveIdToQuery;
|
||||||
deltaLinkCache.itemId = itemIdToQuery;
|
deltaLinkCache.itemId = itemIdToQuery;
|
||||||
deltaLinkCache.latestDeltaLink = currentDeltaLink;
|
deltaLinkCache.latestDeltaLink = currentDeltaLink;
|
||||||
|
}
|
||||||
|
|
||||||
// We have a valid deltaChanges JSON array. This means we have at least 200+ JSON items to process.
|
// We have a valid deltaChanges JSON array. This means we have at least 200+ JSON items to process.
|
||||||
// The API response however cannot be run in parallel as the OneDrive API sends the JSON items in the order in which they must be processed
|
// The API response however cannot be run in parallel as the OneDrive API sends the JSON items in the order in which they must be processed
|
||||||
|
@ -1738,9 +1738,9 @@ class SyncEngine {
|
||||||
skippedItems.clear();
|
skippedItems.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update the deltaLink in the database for this driveId so that we can reuse this now that jsonItemsToProcess has been fully processed
|
// If deltaLinkCache.latestDeltaLink is not empty, update the deltaLink in the database for this driveId so that we can reuse this now that jsonItemsToProcess has been fully processed
|
||||||
if (!deltaLinkCache.latestDeltaLink.empty) {
|
if (!deltaLinkCache.latestDeltaLink.empty) {
|
||||||
addLogEntry("Updating completed deltaLink in DB to: " ~ latestDeltaLink, ["debug"]);
|
addLogEntry("Updating completed deltaLink for driveID " ~ deltaLinkCache.driveId ~ " in DB to: " ~ deltaLinkCache.latestDeltaLink, ["debug"]);
|
||||||
itemDB.setDeltaLink(deltaLinkCache.driveId, deltaLinkCache.itemId, deltaLinkCache.latestDeltaLink);
|
itemDB.setDeltaLink(deltaLinkCache.driveId, deltaLinkCache.itemId, deltaLinkCache.latestDeltaLink);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue