- commitTransaction(tx);
- } catch (DataValidationFailedException e) {
- log.error("{}: Failed to apply recovery snapshot", shardName, e);
+ store.applyRecoverySnapshot(shardSnapshot);
+ } catch (Exception e) {
+ final File f = writeRoot("snapshot", shardSnapshot.getRootNode().orElse(null));
+ throw new IllegalStateException(String.format(
+ "%s: Failed to apply recovery snapshot %s. Node data was written to file %s",
+ shardName, shardSnapshot, f), e);