You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Objects RxBleInternalScanResult are not collected by GC, in case when phone scans for a long time. The speed of scanning(e.g. passing rxBleScanResult to subscriber) goes down dramatically.
Preconditions
Long lastScanTime = 0;
Subscription scanSubscription = rxBleClient.scanBleDevices()
.subscribe(
rxBleScanResult -> {
// Process scan result here.
long currTime = currentTimeMillis();
Log.i(TAG, "Delay between results: " + (currTime - lastScanTime));
lastScanTime = currTime;
},
throwable -> {
// Handle an error here.
}
);
Steps to reproduce actual result
3-5 BLE services should advertise in one room, Run App, keep Activity active.
See unexpected "Delay between results" after 15-20 min in Logcat
See continues growing of RxBleInternalScanResult objects in Dumped Java Heaps
Actual result
The amount of RxBleInternalScanResult keeps growing, the performance of scanning goes down.
Expected result
GC collects old RxBleInternalScanResult, the performance of scanning is stable.
The text was updated successfully, but these errors were encountered:
Summary
Objects RxBleInternalScanResult are not collected by GC, in case when phone scans for a long time. The speed of scanning(e.g. passing rxBleScanResult to subscriber) goes down dramatically.
Preconditions
Long lastScanTime = 0;
Subscription scanSubscription = rxBleClient.scanBleDevices()
.subscribe(
rxBleScanResult -> {
// Process scan result here.
long currTime = currentTimeMillis();
Log.i(TAG, "Delay between results: " + (currTime - lastScanTime));
lastScanTime = currTime;
},
throwable -> {
// Handle an error here.
}
);
Steps to reproduce actual result
Actual result
The amount of RxBleInternalScanResult keeps growing, the performance of scanning goes down.
Expected result
GC collects old RxBleInternalScanResult, the performance of scanning is stable.
The text was updated successfully, but these errors were encountered: