/** * @param exec Striped executor. * @param applyError Check error reference. */ private void awaitApplyComplete( StripedExecutor exec, AtomicReference<IgniteCheckedException> applyError ) throws IgniteCheckedException { if (applyError.get() != null) throw applyError.get(); // Fail-fast check. else { try { // Await completion apply tasks in all stripes. exec.awaitComplete(); } catch (InterruptedException e) { throw new IgniteInterruptedException(e); } // Checking error after all task applied. if (applyError.get() != null) throw applyError.get(); } }