Hello everyone !
Here some context :
I'm managing multiple PrestaShop for different customers. For now I'm migrating an old version to the latest 1.7.6.4. After the migration, I have to generate all the Thumbnails using the option on the BO.
When the PrestaShop is on a dedicated server, I'm increasing the max_execution_time and let the server take as long as it wants to generate the thumbnails. It's not perfect… However, it works.
On the other hand, when the store is on a shared hosting, it's impossible to increase the value of max_execution_time. So I have to reload the page each time after the timeout... It takes time and I think this could be scary for unexperienced site owners.
The thumbnail generations could be handled in another way in order to not trigger a timeout.
Sadly, I do not have enough experience with PrestaShop development to work on the PR myself
Have a nice day
I've searched if there is any similar issues and I haven't found one. If I missed it, I'm sorry about the duplicate.
+1 on this
It could check the PHP's execution time limit and if the regeneration script was reaching this limit, it would redirect to a new instance. Then the script would continue from where it stopped, it could be saved to database or to some "LOCKFILE".
@chrisvanberg Thanks for your suggestion.
@PrestaShop/prestashop-product-team what do you think ?
@PrestaShop/prestashop-core-developers what do you think about @Hlavtox technical suggestion ?
Thanks
If it helps, even is the script throw a 500 error, if you reload the page, it already continues where it left.
It makes me think that if the process was handled in the back end (not on the actual page) we could make a timer (as @Hlavtox stated before) or launch the generation for a fixed number of products and then repeat it until it finished.
Hello,
I have a similar issue on PS 1.7.6.1
I have an error 500 with each regeneration of images on a large catalog.... ( Database crash ) and does anyone have an issue so far ?
Thank you
Hello,
We encounter often this problem.
Ideally, it must a command line to regenerate thumbnails.
@PrestaShop/prestashop-core-developers, could you have a look at this suggestion? What do you think?
It could check the PHP's execution time limit and if the regeneration script was reaching this limit, it would redirect to a new instance. Then the script would continue from where it stopped, it could be saved to database or to some "LOCKFILE".
Most helpful comment
Hello,
I have a similar issue on PS 1.7.6.1
I have an error 500 with each regeneration of images on a large catalog.... ( Database crash ) and does anyone have an issue so far ?
Thank you