Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Star tree] Star tree indexing performance optimizations #16218

Closed
bharath-techie opened this issue Oct 7, 2024 · 0 comments
Closed

[Star tree] Star tree indexing performance optimizations #16218

bharath-techie opened this issue Oct 7, 2024 · 0 comments
Labels
enhancement Enhancement or improvement to existing feature or request Indexing Indexing, Bulk Indexing and anything related to indexing

Comments

@bharath-techie
Copy link
Contributor

Is your feature request related to a problem? Please describe

Currently as part of star tree building during indexing, as part of off-heap build, we duplicate the metric field values for each metric stat, so if a metric field has 4 stats (sum, min, max, value_count) - we write 4 values into index output , instead of one.

Secondly we write individual dimension and metrics directly to IndexOutput.

Describe the solution you'd like

We can write only the actual field value from segments for each of the metric fields during flush.

We can buffer each starTreeDocument in memory and write bytes to indexOutput.

Star tree config

Dimensions

* Timestamp
    * Minute
    * Half Hour
* Target status code
* ELB status code

Metrics

* 8 field [ 4 stats each ]

Hers is how time taken to sort and aggregate segment documents to star-tree documents improved after these changes :

  • Baseline - 24 seconds for 1.5 million documents
  • Metric optimization - 10 seconds for 1.5 million documents
  • Star tree document buffer optimization + Metric optimization - 2.5 seconds for 1.5 million documents

Related component

Search:Performance

Describe alternatives you've considered

No response

Additional context

No response

@bharath-techie bharath-techie added enhancement Enhancement or improvement to existing feature or request untriaged labels Oct 7, 2024
@sandeshkr419 sandeshkr419 added Indexing Indexing, Bulk Indexing and anything related to indexing and removed Search:Performance labels Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Enhancement or improvement to existing feature or request Indexing Indexing, Bulk Indexing and anything related to indexing
Projects
None yet
Development

No branches or pull requests

2 participants