Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Rails Caching Basics
Search
David Moulton
November 13, 2012
Programming
0
110
Rails Caching Basics
Delivered at the 11/2012 UV.rb
David Moulton
November 13, 2012
Tweet
Share
More Decks by David Moulton
See All by David Moulton
OpenWest Ionic Presentation
dmoulton
2
81
Faye URUG Presentation
dmoulton
1
92
Other Decks in Programming
See All in Programming
HTTPプロトコル正しく理解していますか? 〜かわいい猫と共に学ぼう。ฅ^•ω•^ฅ ニャ〜
hekuchan
2
690
Smart Handoff/Pickup ガイド - Claude Code セッション管理
yukiigarashi
0
140
CSC307 Lecture 08
javiergs
PRO
0
670
QAフローを最適化し、品質水準を満たしながらリリースまでの期間を最短化する #RSGT2026
shibayu36
2
4.4k
今から始めるClaude Code超入門
448jp
8
8.7k
15年続くIoTサービスのSREエンジニアが挑む分散トレーシング導入
melonps
2
200
Oxlint JS plugins
kazupon
1
950
AI巻き込み型コードレビューのススメ
nealle
1
250
MUSUBIXとは
nahisaho
0
130
Honoを使ったリモートMCPサーバでAIツールとの連携を加速させる!
tosuri13
1
180
2026年 エンジニアリング自己学習法
yumechi
0
130
LLM Observabilityによる 対話型音声AIアプリケーションの安定運用
gekko0114
2
430
Featured
See All Featured
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
287
14k
Git: the NoSQL Database
bkeepers
PRO
432
66k
The Power of CSS Pseudo Elements
geoffreycrofte
80
6.2k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
310
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.8k
A Modern Web Designer's Workflow
chriscoyier
698
190k
Game over? The fight for quality and originality in the time of robots
wayneb77
1
120
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
VelocityConf: Rendering Performance Case Studies
addyosmani
333
24k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
200
Transcript
Rails Caching Basics
Setup To test caching in dev mode, edit development. rb:
config.action_controller.perform_caching = true Normally this should be false
Page Caching class UsersController < ActionController caches_page :index def index
@users = User.all end ... def create ... expire_page :action => :index end end
Action Caching Can be used when you need to be
authorized to view a page but want to cache it as well.
Fragment Caching cache part of a page <% cache(:action =>
'index', :action_suffix => 'all_users')do %> @users.each do |u| ... <% end %>
Sweepers More centralized location for taking care of cache invalidation
Cache Stores Config config.cache_store = :memory_store config.cache_store = :memory_store, :size
=> 64.megabytes config.cache_store = :file_store, "path/to/cachedir" config.cache_store = :memcache_store, "cache.example.com"