@@ -143,10 +143,8 @@ public Map<DocumentKey, MutableDocument> getAll(
143
143
.performNextSubquery ()
144
144
.forEach (
145
145
row -> {
146
- QueryContext singleCounter = new QueryContext ();
147
- processRowInBackground (
148
- backgroundQueue , results , row , /*filter*/ null , singleCounter );
149
- counter .fullScanCount += singleCounter .fullScanCount ;
146
+ processRowInBackground (backgroundQueue , results , row , /*filter*/ null );
147
+ counter .fullScanCount ++;
150
148
});
151
149
}
152
150
backgroundQueue .drain ();
@@ -234,8 +232,8 @@ private Map<DocumentKey, MutableDocument> getAll(
234
232
.forEach (
235
233
row -> {
236
234
QueryContext singleCounter = new QueryContext ();
237
- processRowInBackground (backgroundQueue , results , row , filter , singleCounter );
238
- counter .fullScanCount += singleCounter . fullScanCount ;
235
+ processRowInBackground (backgroundQueue , results , row , filter );
236
+ counter .fullScanCount ++ ;
239
237
});
240
238
backgroundQueue .drain ();
241
239
return results ;
@@ -253,8 +251,7 @@ private void processRowInBackground(
253
251
BackgroundQueue backgroundQueue ,
254
252
Map <DocumentKey , MutableDocument > results ,
255
253
Cursor row ,
256
- @ Nullable Function <MutableDocument , Boolean > filter ,
257
- QueryContext counter ) {
254
+ @ Nullable Function <MutableDocument , Boolean > filter ) {
258
255
byte [] rawDocument = row .getBlob (0 );
259
256
int readTimeSeconds = row .getInt (1 );
260
257
int readTimeNanos = row .getInt (2 );
@@ -266,7 +263,6 @@ private void processRowInBackground(
266
263
() -> {
267
264
MutableDocument document =
268
265
decodeMaybeDocument (rawDocument , readTimeSeconds , readTimeNanos );
269
- counter .fullScanCount ++;
270
266
if (filter == null || filter .apply (document )) {
271
267
synchronized (results ) {
272
268
results .put (document .getKey (), document );
0 commit comments