Skip to content

Redis Production Readiness

akshat edited this page Feb 10, 2023 · 4 revisions

We are firm believers in Murphy's law. Here's a checklist to ensure your Redis runs flawlessly in production:

  • Goose stores a Job in Redis until it is successfully processed by using BRPOPLPUSH/BLMOVE command
    • Abrupt worker crash will not cause data to be lost
    • In-progress Jobs during a crash are called Orphan Jobs
    • Orphan Jobs will be recovered & retried within max(60 sec, :graceful-shutdown-sec) + 1 min
    • You need not configure anything for this
  • Goose is designed as a reliable job processor. However, Redis being an in-memory cache, unexpected restarts can cause data loss
    • Based on the nature of Jobs, choose Redis architecture based from following options:
  • Set maxmemory-policy noeviction in redis.conf so Redis doesn't drop any jobs silently
Redis Storage
Strategy
Trade-Off
No persistence
(Single Node)
No Data durability.
High performance.
Snapshotting
(Single Node)
Partial Data durability.
Medium performance.
AOF Persistence
(Single Node)
High Data durability.
Low performance.
Redis Sentinel
(Multi Node)
High availability.
Partial Data durability.
Preferable to Redis Cluster.
Redis Cluster
(Multi Node)
High availability & Data durability.
Not recommended because of
frequently changing data.
Twemproxy Incompatible because it doesn't
support blocking commands
.

Previous: RabbitMQ Production Readiness        Next: Troubleshooting

Clone this wiki locally