Skip to content

Commit

Permalink
Merge pull request #817 from Nosto/release/7.2.0
Browse files Browse the repository at this point in the history
Release/7.2.0
  • Loading branch information
dairbuirabass authored Jan 9, 2023
2 parents 5eff14c + 35b544d commit e0d316c
Show file tree
Hide file tree
Showing 13 changed files with 11 additions and 400 deletions.
33 changes: 0 additions & 33 deletions Model/Indexer/ProductIndexer.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
use Nosto\Tagging\Model\ResourceModel\Magento\Product\CollectionBuilder;
use Nosto\Tagging\Model\Service\Indexer\IndexerStatusServiceInterface;
use Nosto\Tagging\Model\Service\Update\ProductUpdateService;
use Nosto\Tagging\Util\PagingIterator;
use Symfony\Component\Console\Input\InputInterface;

/**
Expand Down Expand Up @@ -129,38 +128,6 @@ public function doIndex(Store $store, array $ids = [])
$collection,
$store
);
$this->handleDeletedProducts($collection, $store, $ids);
}

/**
* @param ProductCollection $existingCollection
* @param Store $store
* @param array $givenIds
* @throws NostoException
*/
private function handleDeletedProducts(ProductCollection $existingCollection, Store $store, array $givenIds)
{
if (!empty($givenIds)) {
$existingCollection->setPageSize(1000);
$iterator = new PagingIterator($existingCollection);
$present = [];
foreach ($iterator as $page) {
foreach ($page->getItems() as $item) {
/** @noinspection PhpPossiblePolymorphicInvocationInspection */
$id = $item->getId();
$present[$id] = $id;
}
}
$removed = [];
foreach ($givenIds as $productId) {
if (!isset($present[$productId])) {
$removed[] = $productId;
}
}
if (count($removed) > 0) {
$this->productUpdateService->addIdsToDeleteMessageQueue($removed, $store);
}
}
}

/**
Expand Down
93 changes: 0 additions & 93 deletions Model/Service/Sync/Delete/AsyncBulkConsumer.php

This file was deleted.

77 changes: 0 additions & 77 deletions Model/Service/Sync/Delete/AsyncBulkPublisher.php

This file was deleted.

134 changes: 0 additions & 134 deletions Model/Service/Sync/Delete/DeleteService.php

This file was deleted.

Loading

0 comments on commit e0d316c

Please sign in to comment.