public Packet read(RecordLocation location)
throws InvalidRecordLocationException, IOException {
try {
LogRecord record = logger.get(null, toLong(location));
return new ByteArrayPacket(record.data);
} catch (InvalidLogKeyException e) {
throw new InvalidRecordLocationException(e.getMessage(), e);
} catch (Exception e) {
throw (IOException) new IOException("Journal write failed: " + e)
.initCause(e);