Score:0

Warning when repeating migrate:import process

in flag

I created source and data process plugins for mongo db. And when I run import for the first time it works well. But if I run it again, immediately after that I get warning:

[warning] Could not load the following items on index Content index: "entity:node/104:en", "entity:node/105:en", "entity:node/106:en", "entity:node/107:en", "entity:node/108:en".

Where those are the ids of previously imported nodes. Found that this warning is triggered in web/modules/contrib/search_api/src/Entity/Index.php , row 903, but have no idea what is causing it. In drupal's database node records created in migration process looks similar to "old" ones, like they all have "en" language set..

Any idea what causes that warning?

in flag
When the index is configured to "index on save" (see your index settings, it's somewhere in the bottom), it also includes the save/update operations caused by migrations. It's recommended to uncheck this box and leave indexing happening during cron. However, if the preference is to leave it enabled, I usually write migrations to programmatically uncheck that box before migration, and re-enable it after. Also, this is really a problem between the index and content, and not related to migrations (i.e. it can happen even if migration isn't involved). I'd solve that separately.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.