elasticsearch icon indicating copy to clipboard operation
elasticsearch copied to clipboard

Fix BlockHash DirectEncoder

Open dnhatn opened this issue 9 months ago • 3 comments

The DirectEncoder currently returns the incorrect value for the positionCount() method, which should be the number of positions ready in the current batch. We need to keep track of whether a position is loaded via encodeNextBatch() and consumed via the read() method. However, we can always return 1 for positionCount(), indicating that one position is already loaded. Our tests failed to catch this because mv_ordering wasn't enabled when generating test blocks, effectively disabling the DirectEncoders.

Closes #108268

dnhatn avatar May 05 '24 05:05 dnhatn

Hi @dnhatn, I've created a changelog YAML for you.

elasticsearchmachine avatar May 05 '24 06:05 elasticsearchmachine

Pinging @elastic/es-analytical-engine (Team:Analytics)

elasticsearchmachine avatar May 05 '24 23:05 elasticsearchmachine

Hi @dnhatn, I've updated the changelog YAML for you.

elasticsearchmachine avatar May 05 '24 23:05 elasticsearchmachine

Thanks Nik!

dnhatn avatar May 06 '24 16:05 dnhatn

💚 Backport successful

Status Branch Result
8.14
8.13

elasticsearchmachine avatar May 06 '24 16:05 elasticsearchmachine