Getting 503 error while Restoring Repository 39/6339/1
authorSumit Kaushik <sk00613223@TechMahindra.com>
Fri, 24 Jan 2020 14:34:17 +0000 (20:04 +0530)
committerSumit Kaushik <sk00613223@TechMahindra.com>
Fri, 24 Jan 2020 14:39:07 +0000 (20:09 +0530)
ISSUE-ID : ACUMOS-3918

Getting 503 error while restoring repository

Change-Id: I35098936a503872e91d238ce290bd583f337d845
Signed-off-by: Sumit Kaushik <sk00613223@TechMahindra.com>
elk-client/src/main/java/org/acumos/elk/client/service/SnapshotRepositoryServiceImpl.java

index 1b6e665..56febb8 100644 (file)
@@ -259,7 +259,12 @@ public class SnapshotRepositoryServiceImpl extends AbstractELKClientConnection i
                                        logger.debug("result : {}", result);
                                        resultList.add(result.trim());
                                        logger.debug("resultList.size(): {}", resultList.size());
-
+                                       if (action.equalsIgnoreCase("delete")) {
+                                               ElkRepositoriesRequest elkDeleteRepositoriesRequest= new ElkRepositoriesRequest();
+                                               elkDeleteRepositoriesRequest.setNodeTimeout(ElkClientConstants.TIME_ONE_MINT_OUT);
+                                               elkDeleteRepositoriesRequest.setRepositoryName(repoName);
+                                               deleteElkRepository(elkDeleteRepositoriesRequest);
+                    }
                                        
                                }
                        } catch (Exception ex) {