Skip to content

Commit

Permalink
[ML] Increase close job timeout and lower the max number (#37770)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkyle committed Jan 24, 2019
1 parent d8feff5 commit b32960b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,11 @@ public void testLazyNodeValidation() throws Exception {
}

public void testSingleNode() throws Exception {
verifyMaxNumberOfJobsLimit(1, randomIntBetween(1, 100));
verifyMaxNumberOfJobsLimit(1, randomIntBetween(1, 20));
}

public void testMultipleNodes() throws Exception {
verifyMaxNumberOfJobsLimit(3, randomIntBetween(1, 100));
verifyMaxNumberOfJobsLimit(3, randomIntBetween(1, 20));
}

private void verifyMaxNumberOfJobsLimit(int numNodes, int maxNumberOfJobsPerNode) throws Exception {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ public static void deleteAllJobs(Logger logger, Client client) throws Exception

try {
CloseJobAction.Request closeRequest = new CloseJobAction.Request(MetaData.ALL);
closeRequest.setCloseTimeout(TimeValue.timeValueSeconds(20L));
closeRequest.setCloseTimeout(TimeValue.timeValueSeconds(30L));
logger.info("Closing jobs using [{}]", MetaData.ALL);
CloseJobAction.Response response = client.execute(CloseJobAction.INSTANCE, closeRequest)
.get();
Expand All @@ -327,7 +327,7 @@ public static void deleteAllJobs(Logger logger, Client client) throws Exception
try {
CloseJobAction.Request closeRequest = new CloseJobAction.Request(MetaData.ALL);
closeRequest.setForce(true);
closeRequest.setCloseTimeout(TimeValue.timeValueSeconds(20L));
closeRequest.setCloseTimeout(TimeValue.timeValueSeconds(30L));
CloseJobAction.Response response =
client.execute(CloseJobAction.INSTANCE, closeRequest).get();
assertTrue(response.isClosed());
Expand Down

0 comments on commit b32960b

Please sign in to comment.