Storing Arbitrary Data with Redis
Jobly comes bundled with Sidekiq::Status which has a built in ability allowing you to store and use arbitrary data in its Redis database.
class Hello < Jobly::Job def execute(name: 'bob') # Store arbitrary data store vino: 'veritas' # Retrieve data. vino = retrieve :vino end end
- Values are always stored as a
String, so you will need to convert them to other types when appropriate.
retrievedoes not find the key,
- Stored keys are available across jobs.