• Mikel Astiz's avatar
    Avoid recycling sync tabs if commit pending · 62414cfc
    Mikel Astiz authored
    When a tab is closed, it's possible that the corresponding history
    hasn't been committed yet, and hence there is a risk that synced history
    is lost if the entity is recycled (for another tab that is opened).
    
    In this patch, and behind a feature toggle, this issue is prevented by
    *not* freeing tab nodes while the sync entity is unsynced. Old tabs are
    excluded from this (to avoid problems with expired history) and a max
    cap is also introduced to the number of tabs in this state, in order to
    avoid memory regressions.
    
    Bug: 882489
    Change-Id: I6dd796642f9553f2713a0814731897a4ffb13f0b
    Reviewed-on: https://chromium-review.googlesource.com/c/1356541
    Commit-Queue: Mikel Astiz <mastiz@chromium.org>
    Reviewed-by: default avatarMarc Treib <treib@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#612971}
    62414cfc
session_sync_bridge.h 5.46 KB