diff options
author | zachh <zachh@google.com> | 2018-01-23 15:56:00 -0800 |
---|---|---|
committer | Copybara-Service <copybara-piper@google.com> | 2018-01-23 18:04:54 -0800 |
commit | 5de80a5c9a25f8f952c3c1309ae6e5b77f0d7974 (patch) | |
tree | 2377566efdf5d60f9b39d7615f2f40a4718fc55c /java/com/android/newbubble | |
parent | 813fa56b9a21551feb506dd5d695fee5e513ad94 (diff) |
Don't garbage collect voicemails in AnnotatedCallLog.
We currently limit the size of AnnotatedCallLog to 999 via a trigger, but it doesn't exclude voicemails. Since we don't want to ever garbage collect the user's voicemails, exclude them from the trigger.
This means that we can no longer assume a maximum size for the table (the user culd have more than 999 voicemails) so I've updated the places in the code where we did that before.
Finally, I changed AnnotatedCallLog's CALL_TYPE column to be non-null. This is so that we can have more confidence that the trigger will work as intended. Null values cannot be compared in SQLite, so an expression like "where call_type != 4" won't actually match a null call type. Rather than implicitly fail to clean up such rows, we just crash completely when encountering such rows (even though I don't expect that to happen).
Bug: 70989634
Test: unit
PiperOrigin-RevId: 183006714
Change-Id: I9f4394a4812afe4b65c1e8427c355d825356557c
Diffstat (limited to 'java/com/android/newbubble')
0 files changed, 0 insertions, 0 deletions