Skip to content

Commit

Permalink
Address review comments
Browse files Browse the repository at this point in the history
Signed-off-by: Suraj Singh <[email protected]>
  • Loading branch information
dreamer-89 committed Aug 29, 2022
1 parent 9048b02 commit 4ba2d80
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ import org.opensearch.action.ActionRequest
import org.opensearch.action.ActionResponse
import org.opensearch.client.Client
import org.opensearch.cluster.NamedDiff
import org.opensearch.cluster.metadata.IndexMetadata.INDEX_REPLICATION_TYPE_SETTING
import org.opensearch.cluster.metadata.IndexNameExpressionResolver
import org.opensearch.cluster.metadata.Metadata
import org.opensearch.cluster.metadata.RepositoryMetadata
Expand Down Expand Up @@ -365,7 +364,7 @@ internal class ReplicationPlugin : Plugin(), ActionPlugin, PersistentTaskPlugin,
return if (indexSettings.settings.get(REPLICATED_INDEX_SETTING.key) != null) {
Optional.of(EngineFactory { config ->
// Use NRTSegmentReplicationEngine for SEGMENT replication type indices replica shards
if (config.isReadOnlyReplica && indexSettings.settings.get(INDEX_REPLICATION_TYPE_SETTING.key) != null && indexSettings.settings.get(INDEX_REPLICATION_TYPE_SETTING.key).equals("SEGMENT")) {
if (config.isReadOnlyReplica) {
NRTReplicationEngine(config)
} else {
ReplicationEngine(config)
Expand Down

0 comments on commit 4ba2d80

Please sign in to comment.