filodb / FiloDB

Distributed Prometheus time series database
Apache License 2.0
1.43k stars 225 forks source link

refactor(core): Move common index logic to abstract base class #1816

Closed rfairfax closed 2 months ago

rfairfax commented 3 months ago

In preparation for new index types separate common logic from Lucene specific logic. No functional changes are made as part of this commit, just moving code around and refactoring to accept multiple index implementations.

In most cases this amounts to moving code out of PartKeyLuceneIndex and into PartKeyIndexRaw without further changes. In a few cases things that were instaniating Lucene specific types now use callbacks or other approaches to allow instantiating index specific types.

Pull Request checklist

rfairfax commented 3 months ago

Reviewer notes:

Most changes are bulk copies of code as is. To assist with reviewing I will add comments on every block that isn't a trivial move.