Commit e60efe2
authored
Fix data race with AbstractPageMappingToIteratorOperator (elastic#130963) (elastic#130972)
We need to release the blocks of the page in
AbstractPageMappingToIteratorOperator immediately in single-iteration
cases, instead of delaying to the next iteration. This is because the
blocks of the page are now shared with the output page. The output page
can be passed to a separate driver, which may run concurrently with this
driver, leading to data races in AbstractNonThreadSafeRefCounted, which
is not thread-safe.
An alternative would be to make RefCounted for Vectors/Blocks
thread-safe when they are about to be shared with other drivers via
Relates elastic#130573
Closes elastic#130959
Closes elastic#130958
Closes elastic#130950
Closes elastic#130925
Closes elastic#130881
Closes elastic#1307961 parent 79cc270 commit e60efe2
File tree
1 file changed
+14
-2
lines changed- x-pack/plugin/esql/compute/src/main/java/org/elasticsearch/compute/operator
1 file changed
+14
-2
lines changedLines changed: 14 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
321 | 321 | | |
322 | 322 | | |
323 | 323 | | |
| 324 | + | |
324 | 325 | | |
325 | 326 | | |
326 | 327 | | |
| |||
348 | 349 | | |
349 | 350 | | |
350 | 351 | | |
351 | | - | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
352 | 361 | | |
353 | 362 | | |
354 | 363 | | |
| |||
368 | 377 | | |
369 | 378 | | |
370 | 379 | | |
371 | | - | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
372 | 384 | | |
373 | 385 | | |
374 | 386 | | |
0 commit comments