Source:
public DeleteResponse doDelete(DeleteRequest deleteRequest, List<String> fanoutTagBlacklist) throws IngestException, SourceUnavailableException { DeleteStorageRequest deleteStorageRequest = null; DeleteResponse deleteResponse = null; deleteRequest = queryOperations.setFlagsOnRequest(deleteRequest); deleteRequest = validateDeleteRequest(deleteRequest); deleteRequest = validateLocalSource(deleteRequest); try { deleteRequest = populateMetacards(deleteRequest, fanoutTagBlacklist); deleteRequest = preProcessPreAuthorizationPlugins(deleteRequest); deleteStorageRequest = new DeleteStorageRequestImpl( getDeleteMetacards(deleteRequest), deleteRequest.getProperties()); deleteRequest = processPreDeletePolicyPlugins(deleteRequest); deleteRequest = processPreDeleteAccessPlugins(deleteRequest); deleteRequest = processPreIngestPlugins(deleteRequest); deleteRequest = validateDeleteRequest(deleteRequest); LOGGER.debug( "Calling catalog.delete() with entries.", deleteRequest.getAttributeValues().size()); deleteResponse = performLocalDelete(deleteRequest, deleteStorageRequest); deleteResponse = remoteDeleteOperations.performRemoteDelete(deleteRequest, deleteResponse); deleteResponse = postProcessPreAuthorizationPlugins(deleteResponse); deleteRequest = populateDeleteRequestPolicyMap(deleteRequest, deleteResponse); deleteResponse = processPostDeleteAccessPlugins(deleteResponse); deleteResponse = validateFixDeleteResponse(deleteResponse, deleteRequest); } catch (StopProcessingException see) { LOGGER.debug(PRE_INGEST_ERROR + see.getMessage(), see); throw new IngestException(PRE_INGEST_ERROR + see.getMessage()); } catch (RuntimeException re) { LOGGER.info("Exception during runtime while performing delete", re); throw new InternalIngestException("Exception during runtime while performing delete.", re); } finally { if (deleteStorageRequest != null) { try { sourceOperations.getStorage().commit(deleteStorageRequest); } catch (StorageException e) { LOGGER.info("Unable to remove stored content items.", e); } } } if (deleteResponse == null) { throw new IngestException("CatalogProvider returned null DeleteResponse Object."); } deleteResponse = doPostIngest(deleteResponse); return deleteResponse; }

Target:
public DeleteResponse doDelete(DeleteRequest deleteRequest, List<String> fanoutTagBlacklist) throws IngestException, SourceUnavailableException { DeleteStorageRequest deleteStorageRequest = null; DeleteResponse deleteResponse = null; deleteRequest = queryOperations.setFlagsOnRequest(deleteRequest); deleteRequest = validateDeleteRequest(deleteRequest); deleteRequest = validateLocalSource(deleteRequest); try { deleteRequest = populateMetacards(deleteRequest, fanoutTagBlacklist); deleteRequest = preProcessPreAuthorizationPlugins(deleteRequest); deleteStorageRequest = new DeleteStorageRequestImpl( getDeleteMetacards(deleteRequest), deleteRequest.getProperties()); deleteRequest = processPreDeletePolicyPlugins(deleteRequest); deleteRequest = processPreDeleteAccessPlugins(deleteRequest); deleteRequest = processPreIngestPlugins(deleteRequest); deleteRequest = validateDeleteRequest(deleteRequest); LOGGER.debug( "Calling catalog.delete() with entries.", deleteRequest.getAttributeValues().size()); deleteResponse = performLocalDelete(deleteRequest, deleteStorageRequest); deleteResponse = remoteDeleteOperations.performRemoteDelete(deleteRequest, deleteResponse); deleteResponse = postProcessPreAuthorizationPlugins(deleteResponse); deleteRequest = populateDeleteRequestPolicyMap(deleteRequest, deleteResponse); deleteResponse = processPostDeleteAccessPlugins(deleteResponse); deleteResponse = validateFixDeleteResponse(deleteResponse, deleteRequest); } catch (StopProcessingException see) { LOGGER.debug(PRE_INGEST_ERROR + see.getMessage(), see); throw new IngestException(PRE_INGEST_ERROR + see.getMessage()); } catch (RuntimeException re) { LOGGER.info("Exception during runtime while performing delete", re); throw new InternalIngestException("Exception during runtime while performing delete."); } finally { if (deleteStorageRequest != null) { try { sourceOperations.getStorage().commit(deleteStorageRequest); } catch (StorageException e) { LOGGER.info("Unable to remove stored content items.", e); } } } if (deleteResponse == null) { throw new IngestException("CatalogProvider returned null DeleteResponse Object."); } deleteResponse = doPostIngest(deleteResponse); return deleteResponse; }