Gitter got replaced by Slack. Please use following invite link https://slack.shopware.com to rejoin the awesome Shopware community! https://www.shopware.com/en/news/an-introduction-to-the-shopware-community-slack/
shopwareBot on 5.7
NTR - Increase PHPStan level an… Merge branch 'ntr/increase-phps… (compare)
shopwareBot on 5.6
SW-25949 - use major version op… Merge branch 'sw-25949/5.7/auto… (compare)
shopwareBot on 5.7
NTR - Update PHPStan and introd… NTR - Update cs-fixer NTR - Remove unnecessary cs-fix… and 2 more (compare)
shopwareBot on 5.6
SW-18275 - Close off canvas ele… Merge branch 'sw-18275/5.6/clos… (compare)
shopwareBot on 5.7
NTR - fix all defect migrations… NTR - fix unit tests SW-25897 - Fix wrong demo data and 2 more (compare)
if (!$shop) {
$shop = Shopware()->Container()->get('models')->getRepository(\Shopware\Models\Shop\Shop::class)->getActiveDefault();
}
Holy shit, this was an annoying bug to find:
So, the other day I asked if anyone ever had similar problems like me: having 12k+ articles and suddenly new keywords not being added to the search index.
After an annoyingly long debugging session, I now know why new words weren't added to the index anymore.
Turns out, the s_search_keywords
table is "updated" with loooooots of INSERT IGNORE
s (about 150k per index refresh in our case).
Fun fact: INSERT IGNORE
increases the AUTO_INCREMENT
counter.
Another fun fact: s_search_keywords.id
is unsigned int(11)
- but the column s_search_index.keywordId
which references this column is a SIGNED int(11)
.
Result: the index refreshing job is trying to add $newword to both tables, but silently fails because it can't reference the ID 4240317481 with only a signed int(11)
$container->addCompilerPass(new EventListenerCompilerPass(), PassConfig::TYPE_BEFORE_REMOVING);
$container->addCompilerPass(new EventSubscriberCompilerPass(), PassConfig::TYPE_BEFORE_REMOVING);
$container->addCompilerPass(new DoctrineEventSubscriberCompilerPass());
$container->addCompilerPass(new FormPass());
$container->addCompilerPass(new AddConstraintValidatorsPass());
$container->addCompilerPass(new StaticResourcesCompilerPass());
$container->addCompilerPass(new AddConsoleCommandPass());
$container->addCompilerPass(new MatcherCompilerPass());
$container->addCompilerPass(new LegacyApiResourcesPass());
$container->addCompilerPass(new ConfigureApiResourcesPass(), PassConfig::TYPE_OPTIMIZE, -500);
$container->addCompilerPass(new RegisterFieldsCompilerPass(), PassConfig::TYPE_BEFORE_OPTIMIZATION, 500);
$container->addCompilerPass(new RegisterDynamicController());
$container->addCompilerPass(new RegisterTypeRepositories());
$container->addCompilerPass(new ControllerCompilerPass());
$container->addCompilerPass(new RegisterControllerArgumentLocatorsPass('argument_resolver.service', 'shopware.controller'));
$container->addCompilerPass(new VersionCompilerPass());
How can I add a compiler pass without having to touch Kernel.php