Skip to content

Commit

Permalink
Enable remote store for all integ tests
Browse files Browse the repository at this point in the history
Signed-off-by: Sachin Kale <kalsac@amazon.com>
  • Loading branch information
Sachin Kale committed Aug 31, 2023
1 parent 228cf7b commit 3b93358
Show file tree
Hide file tree
Showing 8 changed files with 535 additions and 430 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@
import org.opensearch.core.xcontent.ToXContentFragment;
import org.opensearch.core.xcontent.XContentBuilder;
import org.opensearch.discovery.Discovery;
import org.opensearch.indices.replication.common.ReplicationType;

import java.io.IOException;
import java.util.Collections;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -670,8 +670,8 @@ public void apply(Settings value, Settings current, Settings previous) {

// Remote cluster state settings
RemoteClusterStateService.REMOTE_CLUSTER_STATE_ENABLED_SETTING,
RemoteClusterStateService.REMOTE_CLUSTER_STATE_REPOSITORY_SETTING
RemoteStoreService.REMOTE_STORE_MIGRATION_SETTING
RemoteClusterStateService.REMOTE_CLUSTER_STATE_REPOSITORY_SETTING,
//RemoteStoreService.REMOTE_STORE_MIGRATION_SETTING,
RemoteStoreService.REMOTE_STORE_COMPATIBILITY_MODE_SETTING
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2145,8 +2145,10 @@ protected SegmentInfos getLastCommittedSegmentInfos() {

@Override
protected SegmentInfos getLatestSegmentInfos() {
try (final GatedCloseable<SegmentInfos> snapshot = getSegmentInfosSnapshot()) {
return snapshot.get();
OpenSearchDirectoryReader reader = null;
try {
reader = internalReaderManager.acquire();
return ((StandardDirectoryReader) reader.getDelegate()).getSegmentInfos();
} catch (IOException e) {
throw new EngineException(shardId, e.getMessage(), e);
} finally {
Expand Down
Loading

0 comments on commit 3b93358

Please sign in to comment.