S3- Cache

alt=
DannyA
@dannya
9 years ago
584 posts
Couple of random questions.

Does the cache folder on s3 automatically clear out expired files? This probably applies to local fs as well.

Is there any problems with SSL since objects are coming from s3? Shouldn't we get a page security alert?
updated by @dannya: 03/30/15 07:06:06PM
brian
@brian
9 years ago
10,148 posts
DannyA:
Couple of random questions.

Does the cache folder on s3 automatically clear out expired files? This probably applies to local fs as well.

This is just for the resized image cache - there's no concept of "expiration" since it's not a traditional cache type setup. When an image changes, it's "signature" will change, and any previously cached versions of the image will no longer match that signature.

Right now there is no "check" for old files in the S3 cache - it's something I will check out.

Local filesystem you don't need to care about it - it keeps itself clean.

Quote:
Is there any problems with SSL since objects are coming from s3? Shouldn't we get a page security alert?

No - Amazon has a valid SSL cert for S3, so you won't get a cert error.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
alt=
DannyA
@dannya
9 years ago
584 posts
brian:
DannyA:
Couple of random questions.

Does the cache folder on s3 automatically clear out expired files? This probably applies to local fs as well.

This is just for the resized image cache - there's no concept of "expiration" since it's not a traditional cache type setup. When an image changes, it's "signature" will change, and any previously cached versions of the image will no longer match that signature.

Right now there is no "check" for old files in the S3 cache - it's something I will check out.

Local filesystem you don't need to care about it - it keeps itself clean.


I understand where the cache comes into play for caching queries. But, how is a response from the cache folder any faster than a response from the media folder? Aren't you just doubling your storage?

And yes, I think there should be some script that looks at the TTL of cache objects and deletes anything that has expired; otherwise that folder will just grow and grow exponentially to the amount of content you have.
brian
@brian
9 years ago
10,148 posts
DannyA:
I understand where the cache comes into play for caching queries. But, how is a response from the cache folder any faster than a response from the media folder? Aren't you just doubling your storage?

No - it's for cached, resized versions of images. We don't really want to be showing someone a 5mb 4000x3000 version of the image from the media directory when it only needs to be 50x30?

Quote:
And yes, I think there should be some script that looks at the TTL of cache objects and deletes anything that has expired; otherwise that folder will just grow and grow exponentially to the amount of content you have.

It's not as simple as that since S3 has no concept of "last access" (unless you want to deal with logging). No matter how long we go until we "expire", at some point we will start expiring valid objects, which we don't want to do. There is no easy solution to that problem, and so for now you would just want to let it grow and do a manual image cache reset from the tools menu say once a month.

I've got some ideas on something that may partially work, but it's not implemented yet.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
alt=
DannyA
@dannya
9 years ago
584 posts
Does the cloud cache cache and session client use s3 yet?

I assume I have to configure each conversion and cache server with s3 module as well.
updated by @dannya: 02/24/15 05:39:13PM
brian
@brian
9 years ago
10,148 posts
DannyA:
Does the cloud cache cache and session client use s3 yet?

I assume I have to configure each conversion and cache server with s3 module as well.

No - The "Cache and Session Client" communicates directly with a MySQL server - it does not use S3 in any way.

S3 is only used for profile media (images, audio, video, files, etc.).


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net

Tags