File tree Expand file tree Collapse file tree 3 files changed +19
-3
lines changed
app/code/Magento/Catalog/Model/Indexer/Category/Product
dev/tests/api-functional/testsuite/Magento/GraphQl/PageCache
lib/internal/Magento/Framework/App Expand file tree Collapse file tree 3 files changed +19
-3
lines changed Original file line number Diff line number Diff line change 1313use Magento \Framework \DB \Query \Generator as QueryGenerator ;
1414use Magento \Framework \DB \Select ;
1515use Magento \Framework \EntityManager \MetadataPool ;
16+ use Magento \Framework \ObjectManager \ResetAfterRequestInterface ;
1617use Magento \Store \Api \Data \StoreInterface ;
1718use Magento \Store \Model \Store ;
1819
2526 * @SuppressWarnings(PHPMD.CouplingBetweenObjects)
2627 * @since 100.0.2
2728 */
28- abstract class AbstractAction
29+ abstract class AbstractAction implements ResetAfterRequestInterface
2930{
3031 /**
3132 * Chunk size
@@ -156,6 +157,20 @@ public function __construct(
156157 $ this ->tableMaintainer = $ tableMaintainer ?: ObjectManager::getInstance ()->get (TableMaintainer::class);
157158 }
158159
160+ /**
161+ * @inheritDoc
162+ */
163+ public function _resetState (): void
164+ {
165+ $ this ->nonAnchorSelects = [];
166+ $ this ->anchorSelects = [];
167+ $ this ->productsSelects = [];
168+ $ this ->categoryPath = [];
169+ $ this ->useTempTable = true ;
170+ $ this ->tempTreeIndexTableName = null ;
171+ $ this ->currentStore = null ;
172+ }
173+
159174 /**
160175 * Run full reindex
161176 *
Original file line number Diff line number Diff line change @@ -230,7 +230,7 @@ public function testProductFromSpecificAndDefaultStoreWithMultiCurrency()
230230 $ this ->assertEquals (
231231 'EUR ' ,
232232 $ response ['products ' ]['items ' ][0 ]['price ' ]['minimalPrice ' ]['amount ' ]['currency ' ],
233- 'Currency code EUR in fixture ' . $ storeCodeFromFixture . ' is unexpected '
233+ 'Currency code EUR in fixture ' . $ storeCodeFromFixture . ' is expected '
234234 );
235235
236236 // test cached store + currency header in Euros
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ class ResourceConnection implements ResetAfterRequestInterface
4040 *
4141 * @var array
4242 */
43- protected $ mappedTableNames ;
43+ protected $ mappedTableNames = [] ;
4444
4545 /**
4646 * Resource config.
@@ -89,6 +89,7 @@ public function __construct(
8989 */
9090 public function _resetState () : void
9191 {
92+ $ this ->mappedTableNames = [];
9293 foreach ($ this ->connections as $ connection ) {
9394 if ($ connection instanceof ResetAfterRequestInterface) {
9495 $ connection ->_resetState ();
You can’t perform that action at this time.
0 commit comments