camptocamp/odoo-cloud-platform

[all versions] attachment_s3: low performance for /shop

jjscarafia opened this issue · 5 comments

This issue is a problem between lower performance accessing s3 objects + some kind of odoo issue.

The problem is that on /shop routes, odoo is calling the method _get_combination_info. And on this method big files are read just to know if they are there (bool(product.image_1920))

For now, we've open odoo/odoo#81767 with a patch to odoo (actually is not a suitable patch)

Anyone else having same issue?

Just changing those lines in odoo we've reduce more that 70% time for /shop route

@ayushin maybe this is what you face in #203

@yvaucher just in case you have any info

@max3903 just in case you face similar issue

One more thing, same thing here
1920 image is called on /shop routes just to check if they exist
Maybe there should be a different kind of implementation when checking if the attachment exists rather than when getting the content

I believe that using image_128 instead of image_1920 could be the proper solution (check changes on PR)

@max3903 @simahawk
Just to let you know that odoo has merged and improvement for this odoo/odoo#81767 (comment)
Closing

thanks!