Commit 8b084148 authored by Randall Hauch's avatar Randall Hauch Committed by GitHub
Browse files

Merge pull request #117 from rhauch/cc-1096

CC-1096 Added ES error message when unable to create an index
parents 1ef6b352 74e5c0fa
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -247,7 +247,8 @@ public class ElasticsearchWriter {
        try {
          JestResult result = client.execute(createIndex);
          if (!result.isSucceeded()) {
            throw new ConnectException("Could not create index:" + index);
            String msg = result.getErrorMessage() != null ? ": " + result.getErrorMessage() : "";
            throw new ConnectException("Could not create index '" + index + "'" + msg);
          }
        } catch (IOException e) {
          throw new ConnectException(e);