Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Purchase, Purchase Items and Product Variants Feed not working #44

Closed
pip77 opened this issue Mar 20, 2024 · 10 comments
Closed

Purchase, Purchase Items and Product Variants Feed not working #44

pip77 opened this issue Mar 20, 2024 · 10 comments

Comments

@pip77
Copy link

pip77 commented Mar 20, 2024

Hi,

We have activated the plugin and were able to do the initial import of the Products and Customer Feeds, but unfortunately the Initial Imports of Purchase, Purchase Items and Product Variants Feed are not working. After starting the feeds, they are stuck at PROCESSING and not showing anything inside the Progress Log. Also I was not able to find any errors in the cron.log, exception.log or bloomreach/debug.log.

Is there a way to have a more detailed log or do you have an idea where I can look for errors? Are the three stuck feeds maybe connected? Maybe the product_id? As far as I can see the product_id is not used in the Customer and Products Feed.

We are using Magento ver. 2.4.3.

Appreciate your help!

image
image

@pip77
Copy link
Author

pip77 commented Mar 21, 2024

It seems like the jobs stop after 5 min. Is there any execution limit we need to configure?

@vlmed
Copy link
Collaborator

vlmed commented Mar 21, 2024

@pip77
it seems to be memory issue.

Check server logs (nginx or apache) for relevant errors. Like: Fatal error: Allowed memory size of 134217728 bytes exhausted.

The fix has been already implemented and will be available in the next release.
As a temporary solution you can manually apply a fix:
https://patch-diff.githubusercontent.com/raw/exponea/bloomreach-magento2-integration/pull/42.patch

Please share if fix is helpful for you after testing

@pip77
Copy link
Author

pip77 commented Mar 21, 2024

@vlmed also, if I set the PAGE_SIZE to 1 for example?

@vlmed
Copy link
Collaborator

vlmed commented Mar 21, 2024

@pip77
You can try, but I don't think it will help.
There are 2 causes of memory issue:

  • Script processes all entities per one execution
  • Order objects are not removed from memory. And in case when you have a lot of orders it can cause the memory issue.

You can find more detail in magento/magento2#34851

@pip77
Copy link
Author

pip77 commented Mar 21, 2024

@vlmed what makes me curious is that it is working for 120k Customers, but not for 50k Product Variants. And I played around with the PAGE_SIZE and it stops at different amount of rows, but always at around 5 mins. Customers and Products is faster than 5 min.

@eduard13
Copy link
Collaborator

eduard13 commented Mar 21, 2024

Hi @pip77, thank you for reaching us. Seeing the amount of orders you have, I'm assuming that you are getting out of memory, that you can only see this in your server's logs. We've already a fix for this problem (see #42), so you can apply it as a patch.

However, today we have released a new 1.1.0 version, that includes that fix, so you can upgrade to the latest version.

Soon, the new version should be also available on the Adobe Marketplace.

Thank you.

@vlmed
Copy link
Collaborator

vlmed commented Mar 21, 2024

@pip77
Actually this is an interesting question.
It might be related to some customizations or third party modules or whatever.
We tested the extension with more than 1 million products and the import went well.
Please try to apply the fix and run the import again. Most likely, this will solve the problem.

@pip77
Copy link
Author

pip77 commented Mar 21, 2024

Thank you both. We will try.

@pip77
Copy link
Author

pip77 commented Mar 21, 2024

@vlmed @eduard13 thank you for your help. We have found the problem. The crons where killed after 5 minutes by the server. We have adjusted this configuration.

After increasing the allowed memory, the max runtime of the crons and fixing and fixing the error below, everything seems to work as expected.

Return value of Bloomreach\EngagementConnector\Model\DataMapping\FieldValueRenderer\Order\ProductList::getProductSku() must be of the type string, null returned

I have created a new issue for the error above: #46

We can close this issue here I guess.

@pip77 pip77 closed this as completed Mar 21, 2024
@pip77
Copy link
Author

pip77 commented Mar 21, 2024

Maybe it is worth to mention the max runtime for crons inside the docs, because it was hard to find within the logs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants