Skip to content

Commit

Permalink
Adds debugging information for invalid repository data x-content
Browse files Browse the repository at this point in the history
  • Loading branch information
Ali Beyad committed Jan 11, 2017
1 parent a6fb108 commit 389ffc9
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -620,6 +620,9 @@ public RepositoryData getRepositoryData() {
// EMPTY is safe here because RepositoryData#fromXContent calls namedObject
try (XContentParser parser = XContentHelper.createParser(NamedXContentRegistry.EMPTY, out.bytes())) {
repositoryData = RepositoryData.snapshotsFromXContent(parser, indexGen);
} catch (NotXContentException e) {
logger.warn("[{}] index blob is not valid x-content [{} bytes]", snapshotsIndexBlobName, out.bytes().length());
throw e;
}
}

Expand Down

0 comments on commit 389ffc9

Please sign in to comment.