final Optional<Exception> preFlightError = preFlightCheckForNoOp(noOp); if (preFlightError.isPresent()) { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), preFlightError.get()); } else { Exception failure = null; noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo()); } else { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), failure); if (noOp.origin().isFromTranslog() == false && noOpResult.getResultType() == Result.Type.SUCCESS) { final Translog.Location location = translog.add(new Translog.NoOp(noOp.seqNo(), noOp.primaryTerm(), noOp.reason())); noOpResult.setTranslogLocation(location); noOpResult.setTook(System.nanoTime() - noOp.startTime()); noOpResult.freeze(); return noOpResult; } finally {
location = innerNoOp(noOp).getTranslogLocation(); } else { location = null;
location = innerNoOp(noOp).getTranslogLocation(); } else { location = null;
location = innerNoOp(noOp).getTranslogLocation(); } else { location = null;
final Optional<Exception> preFlightError = preFlightCheckForNoOp(noOp); if (preFlightError.isPresent()) { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), preFlightError.get()); } else { Exception failure = null; noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo()); } else { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), failure); if (noOp.origin().isFromTranslog() == false && noOpResult.getResultType() == Result.Type.SUCCESS) { final Translog.Location location = translog.add(new Translog.NoOp(noOp.seqNo(), noOp.primaryTerm(), noOp.reason())); noOpResult.setTranslogLocation(location); noOpResult.setTook(System.nanoTime() - noOp.startTime()); noOpResult.freeze(); return noOpResult; } finally {
@Override public NoOpResult noOp(final NoOp noOp) { NoOpResult noOpResult; try (ReleasableLock ignored = readLock.acquire()) { noOpResult = innerNoOp(noOp); } catch (final Exception e) { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), e); } return noOpResult; }
location = innerNoOp(noOp).getTranslogLocation(); } else { location = null;
@Override public NoOpResult noOp(final NoOp noOp) { NoOpResult noOpResult; try (ReleasableLock ignored = readLock.acquire()) { noOpResult = innerNoOp(noOp); } catch (final Exception e) { noOpResult = new NoOpResult(getPrimaryTerm(), noOp.seqNo(), e); } return noOpResult; }