When I add images to my Media Library they aren't available in the Media Library for about an hour. It seems like there is a queue or some sort of CRON that fires. The image appears in the media library as a transparent image for the hour.
How can I get the image to load when I upload?
The images were working previously but I'm now uploading to S3 with a CRON that fires every minute. Maybe that relates to the issue.
Edit Panel which shows the image correctly:
Media Library which shows break:
I have a CRON that runs a sync with the S3 bucket. I then have a proxy rewrite that serves my local dir from the S3.
so for example ls -lah /var/www/html/example/wp/wp-content/uploads/2018/12/
gives me:
-rw-r--r-- 1 apache apache 5.1K Jan 18 23:32 example-150x150.jpg
-rw-r--r-- 1 apache apache 11K Jan 18 23:32 example-272x182.jpg
-rw-r--r-- 1 apache apache 12K Jan 18 23:32 example-280x280.jpg
-rw-r--r-- 1 apache apache 11K Jan 18 23:32 example-300x169.jpg
-rw-r--r-- 1 apache apache 34K Jan 18 23:32 example-660x370.jpg
-rw-r--r-- 1 apache apache 41K Jan 18 23:32 example-768x432.jpg
-rw-r--r-- 1 apache apache 48K Jan 18 23:32 example-800x542.jpg
-rw-r--r-- 1 apache apache 170K Jan 18 23:32 example.jpg
then:
.jpg
.jpg
.jpg
.jpg
.jpg
.jpg
.jpg
.jpg
all load for me (one minute after the upload).
When I add images to my Media Library they aren't available in the Media Library for about an hour. It seems like there is a queue or some sort of CRON that fires. The image appears in the media library as a transparent image for the hour.
How can I get the image to load when I upload?
The images were working previously but I'm now uploading to S3 with a CRON that fires every minute. Maybe that relates to the issue.
Edit Panel which shows the image correctly:
Media Library which shows break:
I have a CRON that runs a sync with the S3 bucket. I then have a proxy rewrite that serves my local dir from the S3.
so for example ls -lah /var/www/html/example/wp/wp-content/uploads/2018/12/
gives me:
-rw-r--r-- 1 apache apache 5.1K Jan 18 23:32 example-150x150.jpg
-rw-r--r-- 1 apache apache 11K Jan 18 23:32 example-272x182.jpg
-rw-r--r-- 1 apache apache 12K Jan 18 23:32 example-280x280.jpg
-rw-r--r-- 1 apache apache 11K Jan 18 23:32 example-300x169.jpg
-rw-r--r-- 1 apache apache 34K Jan 18 23:32 example-660x370.jpg
-rw-r--r-- 1 apache apache 41K Jan 18 23:32 example-768x432.jpg
-rw-r--r-- 1 apache apache 48K Jan 18 23:32 example-800x542.jpg
-rw-r--r-- 1 apache apache 170K Jan 18 23:32 example.jpg
then:
http://example/wp/wp-content/uploads/2018/12/example-150x150.jpg
http://example/wp/wp-content/uploads/2018/12/example-272x182.jpg
http://example/wp/wp-content/uploads/2018/12/example-280x280.jpg
http://example/wp/wp-content/uploads/2018/12/example-300x169.jpg
http://example/wp/wp-content/uploads/2018/12/example-660x370.jpg
http://example/wp/wp-content/uploads/2018/12/example-768x432.jpg
http://example/wp/wp-content/uploads/2018/12/example-800x542.jpg
http://example/wp/wp-content/uploads/2018/12/example.jpg
all load for me (one minute after the upload).
When I add images to my Media Library they aren't available in the Media Library for about an hour. It seems like there is a queue or some sort of CRON that fires.
WordPress handles uploads immediately, there is no latency, queues, or cron unless you introduce one yourself.
The image appears in the media library as a transparent image for the hour.
The images were working previously but I'm now uploading to S3 with a CRON that fires every minute. Maybe that relates to the issue.
This is the reason why it doesn't work, 100%. At a minimum there will be a minute of latency as a result of what you've done, assuming that the files are served instantly from S3, but that may not be the case. There may be latency on S3, but that's unconnected to WordPress.
So, lets pick that part: