From 9de81c5e9e44eb1694b00d3d9bad96161150a3e1 Mon Sep 17 00:00:00 2001 From: Louis Chu Date: Wed, 23 Oct 2024 13:28:09 -0700 Subject: [PATCH] Add more ITs Signed-off-by: Louis Chu --- .../spark/FlintSparkUpdateIndexITSuite.scala | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/integ-test/src/integration/scala/org/opensearch/flint/spark/FlintSparkUpdateIndexITSuite.scala b/integ-test/src/integration/scala/org/opensearch/flint/spark/FlintSparkUpdateIndexITSuite.scala index d03b77d4e..a6f7e0ed0 100644 --- a/integ-test/src/integration/scala/org/opensearch/flint/spark/FlintSparkUpdateIndexITSuite.scala +++ b/integ-test/src/integration/scala/org/opensearch/flint/spark/FlintSparkUpdateIndexITSuite.scala @@ -302,6 +302,26 @@ class FlintSparkUpdateIndexITSuite extends FlintSparkSuite { Map("incremental_refresh" -> "true", "checkpoint_location" -> "s3a://test/")), (Map.empty[String, String], Map("checkpoint_location" -> "s3a://test/"))), "No options can be updated when auto_refresh remains false"), + ( + "update index option when refresh_interval value belows threshold", + Seq( + ( + Map("auto_refresh" -> "true", "checkpoint_location" -> "s3a://test/"), + Map("refresh_interval" -> "4 minutes"))), + "Input refresh_interval is 4 minutes, required above the interval threshold of external scheduler: 5 minutes"), + ( + "update index option when no change on auto_refresh", + Seq( + ( + Map("auto_refresh" -> "true", "checkpoint_location" -> "s3a://test/"), + Map("scheduler_mode" -> "internal", "refresh_interval" -> "4 minutes")), + ( + Map( + "auto_refresh" -> "true", + "scheduler_mode" -> "internal", + "checkpoint_location" -> "s3a://test/"), + Map("refresh_interval" -> "4 minutes"))), + "Altering index when auto_refresh remains true and scheduler_mode is internal only allows changing: Set(scheduler_mode). Invalid options"), ( "update other index option besides scheduler_mode and refresh_interval when auto_refresh is true", Seq(