Examples of ODeleteRecordTask


Examples of com.orientechnologies.orient.server.distributed.task.ODeleteRecordTask

       if (executionModeSynch == null)
         executionModeSynch = iMode == 0;

       if (executionModeSynch) {
         // REPLICATE IT
         final Object result = dManager.sendRequest(getName(), Collections.singleton(clusterName), nodes, new ODeleteRecordTask(
             iRecordId, iVersion), EXECUTION_MODE.RESPONSE);

         if (result instanceof ONeedRetryException)
           throw (ONeedRetryException) result;
         else if (result instanceof Throwable)
           throw new ODistributedException("Error on execution distributed DELETE_RECORD", (Throwable) result);

         return new OStorageOperationResult<Boolean>(true);
       }

       final OStorageOperationResult<Boolean> localResult = wrapped.deleteRecord(iRecordId, iVersion, iMode, iCallback);

       nodes.remove(0);
       if (!nodes.isEmpty())
         asynchronousExecution(new OAsynchDistributedOperation(getName(), Collections.singleton(clusterName), nodes,
             new ODeleteRecordTask(iRecordId, iVersion)));

       return localResult;

     } catch (ONeedRetryException e) {
       // PASS THROUGH
View Full Code Here

Examples of com.orientechnologies.orient.server.distributed.task.ODeleteRecordTask

           task = new OUpdateRecordTask(rid, previousContent.getResult().getBuffer(), previousContent.getResult().version,
               record.toStream(), record.getRecordVersion());
           break;

         case ORecordOperation.DELETED:
           task = new ODeleteRecordTask(rid, record.getRecordVersion());
           break;

         default:
           continue;
         }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.