Files
grafana/pkg/setting
Rafael Paulovic aa90ac7ccc feat(unified-storage): add sub-index sharding infrastructure for 1M scale
Phase 1 of unified storage search sharding implementation:

- Add SubIndexKey type extending NamespacedResource with SubIndexID
- Add new settings: sub_indexes_per_namespace, large_folder_threshold
- Add subIndexCache to bleveBackend for sharded index storage
- Add GetSubIndexForDocument() using FNV32a hash for consistent distribution
- Add GetAllSubIndexKeys() for scatter-gather queries
- Implement compositeIndex wrapper that:
  - Routes BulkIndex to correct sub-index based on document key hash
  - Uses Bleve IndexAlias for unified search across sub-indexes
  - Aggregates DocCount across all sub-indexes
  - Delegates UpdateIndex to all sub-indexes

This enables horizontal scaling for namespaces with 1M+ resources by
distributing documents across multiple sub-indexes (recommended: 64).
2026-01-12 13:57:09 +01:00
..