Ronan Lopes Ronan Lopes - 1 month ago 19
Ruby Question

Ruby on Rails - Base64.encode/decode file size limit

I have to pass some files for processing in background by sidekiq, so I have to serialize then. I'm gonna deal with some PDF's no larger than 10Mb, so I would like to know if it's safe to serialize then using encode/decode from Base64. Thanks!

Answer

Its not safe.

Store the file in common location and pass the file location to sidekiq for processing. In Sidekiq open the file and process it.

Sidekiq uses redis to store job details. Sidekiq recommends to store only small values in job data on redis. Redis is not meant to store large data.

Comments