Skip to content

Conversation

@phananh1010
Copy link
Owner

This is a part of elastic#132566

BASE=a31485f6e8f14869de0605e9f6b303b353b772a0
HEAD=be3c1d34ffb0c20f2517b1b81283f7bd311024ac
Branch=main
@phananh1010
Copy link
Owner Author

@codex review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +246 to +250
String previousPath = null;
for (int i = 0; i < numberOfValues; i++) {
Dimension dim = dimensions.get(i);
String path = dim.path();
if (path.equals(previousPath)) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Skip unique fields after large arrays when writing value hashes

The value-similarity loop iterates only numberOfValues = min(MAX_TSID_VALUE_FIELDS, dimensions.size()) entries, but array elements are skipped with continue. If a time series starts with many values for the same path (e.g., an array with >16 items) the loop exhausts its numberOfValues budget before reaching later unique dimensions, so those fields never contribute a value byte to the TSID. Different series that vary only in those later fields will therefore hash to the same value-similarity prefix and cluster together, defeating the stated goal of clustering by up to 16 field values. Consider iterating until 16 distinct paths are processed rather than blindly stopping after the first 16 elements.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants