- Lets you look at queries that have been run
- average time it takes
- number of times it's been run
- You can see the expensive queries and where to optimize
- Which do I use?
- Use with multiple values in one column
- Arrays, JSON
- Similarity
- Good for phone numbers
- Space-partitioned GIN index?
- Do something to data and make an index on that result
- Cool
- Slower
- Non-locking
- Currently just text validation
- Gonna be better in 9.4
- JSONB = hstore2 with JSON and indexes
- One-deep hash
- Works with indexes
- Application/Framework layer
- Standalone daemon
- pgbouncer
- pgpool
- Wal-e
- pg_dump
- <50GB
- Has load on DB
- Bytes on disk
- Limited system load
- Use above 50GB
- Web apps
- Ensure bulk of data is cached
- pg_bouncer
- Heavy write load?
- Run postgres with unlocked tables
- Don't overuse indexes