DEV Community

Discussion on: The Rails Ecosystem is Healthier than Ever

Collapse
 
juanmanuelramallo profile image
Juan Manuel Ramallo • Edited

😄 A shout-out to ActiveStorage! Rest in peace paperclip, carrierwave and others 💀

Collapse
 
ben profile image
Ben Halpern

dev.to is still on carrierwave 😱

Promise we'll get to 5.2 soon!

Collapse
 
shobhitic profile image
Shobhit🎈✨

Carrierwave is still much better than ActiveStorage in some circumstance. You don't need two extra queries to get assets of an object, f.e.

Collapse
 
matteojoliveau profile image
Matteo Joliveau

I love ActiveStorage too, I use it on my personal website and on all new projects at work.
But one major shortcoming I found, and something I hope will be addressed/changed in future versions, is that images cannot be cached by CDNs. I have CloudFront and CloudFlare caching static assets, but I had to exclude images because ActiveStorage generates 5 minutes-lived URLs from the backing service, and after 5 minutes if the cache tries to refresh itself it returns a 404 error.

As you can see in this issue on GitHub, it is a common concern.

Collapse
 
juanmanuelramallo profile image
Juan Manuel Ramallo

Yeah I faced the same issue with no success :(
How did you work around it?
Seems like ActiveStorage was planned for files rather than for images :/

Thread Thread
 
matteojoliveau profile image
Matteo Joliveau

Well... I didn't ahah
We're just avoiding caching images, inefficient but at least it works. I hope they'll fix it soon