void BatchWriteOp::noteBatchError( const TargetedWriteBatch& targetedBatch, const BatchedErrorDetail& error ) { BatchedCommandResponse response; response.setOk( false ); cloneBatchErrorFrom( error, &response ); noteBatchResponse( targetedBatch, response, NULL ); }
void BatchWriteOp::noteBatchError( const TargetedWriteBatch& targetedBatch, const WriteErrorDetail& error ) { // Treat errors to get a batch response as failures of the contained writes BatchedCommandResponse emulatedResponse; toWriteErrorResponse( error, _clientRequest->getOrdered(), targetedBatch.getWrites().size(), &emulatedResponse ); noteBatchResponse( targetedBatch, emulatedResponse, NULL ); }