Fixed
Status Update
Comments
da...@google.com <da...@google.com>
ap...@google.com <ap...@google.com> #2
Project: platform/frameworks/support
Branch: androidx-main
commit 1b9ae441be4de3443b138e789c85722bba29c356
Author: Clara F <clarafok@google.com>
Date: Mon Mar 14 15:26:56 2022
[GH] Add room-paging-guava module to Room
Create module for integrating Guava into Room Paging
Test: n/a
Bug: 203666906
This is an imported pull request fromhttps://github.com/androidx/androidx/pull/337 .
Resolves #337
Relnote: "Added a new artifact, room-paging-guava, for ListenableFuturePagingSource in
room-paging."
Github-Pr-Head-Sha: f62df108d6d5dd765c43b1e75472ddd0a097f9de
GitOrigin-RevId: 8c86aaa8e3a856614cbdccabe07c0d658efb0407
Change-Id: Ie14a1beef5d3b7ba07f3acc3fdd1f7bfc6fd1b9e
A room/room-paging-guava/src/androidTest/AndroidManifest.xml
A room/room-paging-guava/api/public_plus_experimental_current.txt
M settings.gradle
M docs-tip-of-tree/build.gradle
A room/room-paging-guava/api/restricted_current.txt
A room/room-paging-guava/api/res-current.txt
A room/room-paging-guava/src/main/AndroidManifest.xml
A room/room-paging-guava/api/current.txt
A room/room-paging-guava/build.gradle
https://android-review.googlesource.com/2025245
Branch: androidx-main
commit 1b9ae441be4de3443b138e789c85722bba29c356
Author: Clara F <clarafok@google.com>
Date: Mon Mar 14 15:26:56 2022
[GH] Add room-paging-guava module to Room
Create module for integrating Guava into Room Paging
Test: n/a
Bug: 203666906
This is an imported pull request from
Resolves #337
Relnote: "Added a new artifact, room-paging-guava, for ListenableFuturePagingSource in
room-paging."
Github-Pr-Head-Sha: f62df108d6d5dd765c43b1e75472ddd0a097f9de
GitOrigin-RevId: 8c86aaa8e3a856614cbdccabe07c0d658efb0407
Change-Id: Ie14a1beef5d3b7ba07f3acc3fdd1f7bfc6fd1b9e
A room/room-paging-guava/src/androidTest/AndroidManifest.xml
A room/room-paging-guava/api/public_plus_experimental_current.txt
M settings.gradle
M docs-tip-of-tree/build.gradle
A room/room-paging-guava/api/restricted_current.txt
A room/room-paging-guava/api/res-current.txt
A room/room-paging-guava/src/main/AndroidManifest.xml
A room/room-paging-guava/api/current.txt
A room/room-paging-guava/build.gradle
Description
Version used: 2.0.0
Devices/Android versions reproduced on: Any
We recently started seeing a lot of lock contention upon subscription to Observables provided by Room. At first we thought that the problem was caused by `syncTriggers` doing DB work on the main thread (a known issue here:
It seems that the close lock is unintentionally being used to obtain an exclusive lock on the entire database, blocking any other subscriptions while there is either another subscription happening at the same time or the refresh runnable is running. I'm not sure why the protection against closing is required in the first place, but maybe a `ReentrantReadWriteLock` could accomplish the intended goal without the exclusiveness.