Feature/data format aware read only engine#21720
Conversation
PR Code Analyzer ❗AI-powered 'Code-Diff-Analyzer' found issues on commit ab301fd.
The table above displays the top 10 most important findings. Pull Requests Author(s): Please update your Pull Request according to the report above. Repository Maintainer(s): You can Thanks. |
2d4cb3c to
0ddec48
Compare
PR Reviewer Guide 🔍(Review updated until commit 5165667)Here are some key observations to aid the review process:
|
0ddec48 to
7bc2965
Compare
PR Code Suggestions ✨Latest suggestions up to 5165667 Explore these optional code suggestions:
Previous suggestionsSuggestions up to commit 4b088ef
Suggestions up to commit ff0459c
Suggestions up to commit a251956
Suggestions up to commit a526ff4
Suggestions up to commit 9035f42
|
7bc2965 to
890d029
Compare
a526ff4 to
a251956
Compare
|
Persistent review updated to latest commit a251956 |
|
❌ Gradle check result for a251956: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
a251956 to
ff0459c
Compare
|
Persistent review updated to latest commit ff0459c |
|
❌ Gradle check result for ff0459c: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
ff0459c to
4b088ef
Compare
|
Persistent review updated to latest commit 4b088ef |
|
❌ Gradle check result for 4b088ef: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
❌ Gradle check result for 4b088ef: null Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Introduces a purpose-built read-only engine for primaries on indices marked with isWarmIndex(). The engine operates on CatalogSnapshot, has no IndexWriter, uses NoOpTranslogManager, and rejects all write operations. Reads route through TieredSubdirectoryAwareDirectory to remote storage. Key changes: - DataFormatAwareReadOnlyEngine implementing Indexer interface - DataFormatAwareIndexerFactory updated to create read-only engine for warm primaries - Unit tests for the read-only engine - Integration test skeleton for warm engine scenarios - run.gradle updated for multi-node warm testing - Test fixes for cherry-picked NRT replication changes Signed-off-by: nishchay21 <nishcha@amazon.com>
…auto_expand_replicas, IndexShard DFA sync fix - TransportPrepareTieringAction: broadcast action for flush+sync on primaries - TransportHotToWarmTierAction: read-only block + prepare + retry + tier flow for DFA - TieringService: auto_expand_replicas during tiering - HotToWarmTieringService: read_only_allow_delete on cancel - WarmToHotTieringService: remove read-only block on warm-to-hot - IndexShard: fix isRemoteSegmentStoreInSync for DFA using CatalogSnapshot - NRT engine: null-check on commitResult (from mgodwan fix) - Unit tests for all changes Signed-off-by: nishchay21 <nishchay21@users.noreply.github.com> Signed-off-by: nishchay21 <nishcha@amazon.com>
Signed-off-by: nishchay21 <nishchay21@users.noreply.github.com> Signed-off-by: nishchay21 <nishcha@amazon.com>
Signed-off-by: nishchay21 <nishcha@amazon.com>
Return NotFound for directory HEAD requests using registry prefix matching instead of hitting remote store. This matches LocalFileSystem behavior and allows DataFusion to fall through to list_with_cache. - try_head_from_registry: prefix match detects directories, returns NotFound - Removed fragile heuristic that used path_str.contains dot - Tests updated to expect NotFound for directory HEAD - list test registers local file in registry (list returns registry only) Signed-off-by: nishchay21 <nishcha@amazon.com>
Signed-off-by: nishchay21 <nishcha@amazon.com>
Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
…pload to remote Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
Signed-off-by: Vishwas Garg <vishwasgarg14@gmail.com>
4b088ef to
5165667
Compare
|
Persistent review updated to latest commit 5165667 |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #21720 +/- ##
============================================
+ Coverage 73.46% 73.49% +0.03%
- Complexity 75254 75299 +45
============================================
Files 6023 6024 +1
Lines 341475 341712 +237
Branches 49141 49162 +21
============================================
+ Hits 250855 251143 +288
+ Misses 70680 70556 -124
- Partials 19940 20013 +73 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Description
This PR introduces a data-format-aware read-only engine for warm (tiered) primaries in OpenSearch, along with the tiering service infrastructure needed to safely transition indices between hot and warm tiers.
Core Engine:
DataFormatAwareReadOnlyEngineisWarmIndex()). The engine operates on aCatalogSnapshot, has noIndexWriter, usesNoOpTranslogManager, and rejects all write operations.TieredSubdirectoryAwareDirectoryto remote (warm) storage.DataFormatAwareIndexerFactoryupdated to create the read-only engine for warm primaries.Tiering Service Improvements
TransportPrepareTieringAction: new broadcast action that flushes and syncs all primaries before tiering begins.TransportHotToWarmTierAction: adds read-only block, prepare step, retry logic, and DFA-aware tiering flow.TieringService: setsauto_expand_replicasduring the tiering transition.HotToWarmTieringService: setsread_only_allow_deleteon cancel to protect segments.WarmToHotTieringService: removes the read-only block when transitioning back to hot.IndexShard: fixesisRemoteSegmentStoreInSyncfor DFA usingCatalogSnapshot.TieredObjectStore: Fix for Warm PPL Queries
try_head_from_registry: uses prefix matching to detect directory HEAD requests and returnsNotFound(matchingLocalFileSystembehavior), allowing DataFusion to fall through tolist_with_cache. Removes the fragilepath_str.contains('.')heuristic.Related Issues
Resolves #
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.