@@ -76,7 +76,7 @@ public void testCreatePITSuccess() throws ExecutionException, InterruptedExcepti
7676 request .setIndices (new String [] { "index" });
7777 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
7878 CreatePitResponse pitResponse = execute .get ();
79- PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime ());
79+ PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime (), TimeValue . timeValueDays ( 1 ) );
8080 assertSegments (false , client (), pitResponse .getId ());
8181 client ().prepareIndex ("index" ).setId ("2" ).setSource ("field" , "value" ).setRefreshPolicy (IMMEDIATE ).get ();
8282 SearchResponse searchResponse = client ().prepareSearch ("index" )
@@ -106,7 +106,7 @@ public void testCreatePITWithMultipleIndicesSuccess() throws ExecutionException,
106106
107107 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
108108 CreatePitResponse response = execute .get ();
109- PitTestsUtil .assertUsingGetAllPits (client (), response .getId (), response .getCreationTime ());
109+ PitTestsUtil .assertUsingGetAllPits (client (), response .getId (), response .getCreationTime (), TimeValue . timeValueDays ( 1 ) );
110110 assertSegments (false , client (), response .getId ());
111111 assertEquals (4 , response .getSuccessfulShards ());
112112 assertEquals (4 , service .getActiveContexts ());
@@ -127,7 +127,7 @@ public void testCreatePITWithShardReplicasSuccess() throws ExecutionException, I
127127 request .setIndices (new String [] { "index" });
128128 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
129129 CreatePitResponse pitResponse = execute .get ();
130- PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime ());
130+ PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime (), TimeValue . timeValueDays ( 1 ) );
131131 assertSegments (false , client (), pitResponse .getId ());
132132 client ().prepareIndex ("index" ).setId ("2" ).setSource ("field" , "value" ).setRefreshPolicy (IMMEDIATE ).get ();
133133 SearchResponse searchResponse = client ().prepareSearch ("index" )
@@ -229,7 +229,7 @@ public void testPitSearchOnCloseIndex() throws ExecutionException, InterruptedEx
229229 request .setIndices (new String [] { "index" });
230230 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
231231 CreatePitResponse pitResponse = execute .get ();
232- PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime ());
232+ PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime (), TimeValue . timeValueDays ( 1 ) );
233233 assertSegments (false , client (), pitResponse .getId ());
234234 SearchService service = getInstanceFromNode (SearchService .class );
235235 assertEquals (2 , service .getActiveContexts ());
@@ -412,7 +412,7 @@ public void testPitAfterUpdateIndex() throws Exception {
412412 request .setIndices (new String [] { "test" });
413413 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
414414 CreatePitResponse pitResponse = execute .get ();
415- PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime ());
415+ PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime (), TimeValue . timeValueMinutes ( 2 ) );
416416 SearchService service = getInstanceFromNode (SearchService .class );
417417
418418 assertThat (
@@ -570,7 +570,7 @@ public void testConcurrentSearches() throws Exception {
570570 request .setIndices (new String [] { "index" });
571571 ActionFuture <CreatePitResponse > execute = client ().execute (CreatePitAction .INSTANCE , request );
572572 CreatePitResponse pitResponse = execute .get ();
573- PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime ());
573+ PitTestsUtil .assertUsingGetAllPits (client (), pitResponse .getId (), pitResponse .getCreationTime (), TimeValue . timeValueDays ( 1 ) );
574574 assertSegments (false , client (), pitResponse .getId ());
575575 Thread [] threads = new Thread [5 ];
576576 CountDownLatch latch = new CountDownLatch (threads .length );
0 commit comments