Categories
- Active Record
- Active Resource
- Active Support
- Administration
- Ajax
- APIs
- Authentication
- Authorization
- Background Jobs
- Caching
- Code Walkthrough
- Controllers
- Debugging
- Deployment
- eCommerce
- Forms
- Mailing
- Models
- Performance
- Plugins
- Production
- Rack
- Rails 2.0
- Rails 2.1
- Rails 2.2
- Rails 2.3
- Rails 3.0
- Rails 3.1
- Rails 3.2
- Rails 4.0
- Refactoring
- Routing
- Search
- Security
- Testing
- Tools
- Views
Applied Filters:
Caching x
Autocomplete Search Terms
Learn how to add autocompletion to a search form and improve performance using Rack middleware, caching and switching from SQL to Redis.
(17 minutes)
Cache Digests
The cache_digests gem (also included in Rails 4) will automatically add a digest to the fragment cache key based on the template. If a template changes the cache will auto-expire. But watch out for the gotchas!
(7 minutes)
Memcached & Dalli
Memcached is an excellent cache store, and Dalli is the best way to interact with it through Ruby. Here I show various ways to use Memcached in a Rails app including how to set it up in production.
(12 minutes)
Memoization (revised)
Memoization is a convenient way to cache a method's response. Here I show several ways to accomplish this from scratch since the ActiveSupport::Memoizable module has been deprecated.
(9 minutes)
Fragment Caching (revised)
If you need to cache a certain section of a page instead of the entire page, fragment caching is the way to go. Learn how caching is stored, how to create auto expiring caches, and more.
(9 minutes)
Dynamic Page Caching (revised)
Page caching is great for speeding up the performance of a page, but what if it contains user-specific content? Learn how to load content in dynamically through JavaScript in this episode.
(7 minutes)
Page Caching (revised)
Page caching is an efficient way to cache full content to be served by the front-end web server. Learn how to deal with pagination, expiration with sweepers, and user-specific content in this episode.
(9 minutes)
HTTP Caching
With HTTP response headers you can the cache in the user's browser and proxies. Etags, Last-Modified, Cache-Control and Rack::Cache are all covered here
(15 minutes)
Touch and Cache
Rails 2.3.3 brings us a new feature called "touch". See how to use this to auto-expire associated caches in this episode.
(6 minutes)
Dynamic Page Caching
Use JavaScript to allow dynamic content in a page cache. In this episode I show you how to insert the user-specific content into a page through JavaScript.
(11 minutes)