From fc508d716079aa30a097408c86995e3ac0a2891b Mon Sep 17 00:00:00 2001 From: ashmrtn <3891298+ashmrtn@users.noreply.github.com> Date: Mon, 9 Oct 2023 11:38:15 -0700 Subject: [PATCH] Reenable exchange kopia assisted incrementals (#4411) Allow creation of lazy collections and lazy items again thus allowing exchange kopia assisted incrementals. Manually tested that a backup where an email switches folders after enumeration results in an empty file in kopia except for the serialization header which includes the deleted in flight flag. The next backup removes the empty file from the folder in kopia. The item doesn't appear in backup details since it has no data --- #### Does this PR need a docs update or release note? - [ ] :white_check_mark: Yes, it's included - [ ] :clock1: Yes, but in a later PR - [x] :no_entry: No #### Type of change - [x] :sunflower: Feature - [ ] :bug: Bugfix - [ ] :world_map: Documentation - [ ] :robot: Supportability/Tests - [ ] :computer: CI/Deployment - [ ] :broom: Tech Debt/Cleanup #### Issue(s) * #2023 #### Test Plan - [x] :muscle: Manual - [ ] :zap: Unit test - [ ] :green_heart: E2E --- src/internal/m365/collection/exchange/backup.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/internal/m365/collection/exchange/backup.go b/src/internal/m365/collection/exchange/backup.go index 48193f89b..87db96312 100644 --- a/src/internal/m365/collection/exchange/backup.go +++ b/src/internal/m365/collection/exchange/backup.go @@ -160,7 +160,7 @@ func populateCollections( ictx = clues.Add(ictx, "previous_path", prevPath) - added, _, removed, newDelta, err := bh.itemEnumerator(). + added, validModTimes, removed, newDelta, err := bh.itemEnumerator(). GetAddedAndRemovedItemIDs( ictx, qp.ProtectedResource.ID(), @@ -199,9 +199,7 @@ func populateCollections( bh.itemHandler(), added, removed, - // TODO(ashmrtn): Set to value returned by pager when we have deletion - // markers in files. - false, + validModTimes, statusUpdater) collections[cID] = edc