• Resolved vgibara79

    (@vgibara79)


    I have installed this plugin, and experience variable upload delay… I’m on DigitalOcean.

    I have cron jobs to upload multiples images. This uses media_sideload_image() function.

    Earlier today i experienced 3-6 seconds upload time.

    Now, same function, takes between 80 and 300 seconds to upload.

    What could cause that ?

    • This topic was modified 1 year, 2 months ago by vgibara79.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Masoud Golchin

    (@masoudin)

    Hi @vgibara79,

    Thank you for contacting us.

    Have you tested your bucket with another software or plugin to determine if it’s caused by the plugin, your network, or the bucket region?

    Based on our experience, the issue might be related to the bucket region compared to your location.

    Thread Starter vgibara79

    (@vgibara79)

    Hello ! Wanted to follow up on this.

    I though it was the region that caused problem, as my server and my spaces wasn’t in the same region. I moved all my medias to a new bucket in the same region, but the long delay was still there.

    So i decided to debug every line of code to find out where was the long delay.

    I found out it was a problem caused by the plugin Polylang that is adding a filter on wp_delete_file. This filter has a query into the post_meta table. However, we have a very large post_meta table, and there was no index on the required fields (post_id, meta_key and meta_value), therefore taking about 25 seconds each time, running that specific query.

    Only by adding this index, everything runs in less than 2 seconds, depending on the file size.

    Thanks for your help !

    • This reply was modified 1 year, 2 months ago by vgibara79.
    Plugin Author Masoud Golchin

    (@masoudin)

    Hello @vgibara79

    Thank you for your valuable feedback!

    I appreciate you taking the time to share your thoughts with us.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Very slow upload’ is closed to new replies.