I'm using ruby 2.5.0 and gpgme 2.0.16 with rails and sidekiq. I'm spinning up about 40 GPG decryption jobs, processing about 10 jobs (using threads) * 3 processes concurrently.
Searching for a private key randomly raises GPGME::Error Bad file descriptor randomly in my jobs:
I'm using ruby
2.5.0
and gpgme2.0.16
with rails and sidekiq. I'm spinning up about 40 GPG decryption jobs, processing about 10 jobs (using threads) * 3 processes concurrently.Searching for a private key randomly raises
GPGME::Error Bad file descriptor
randomly in my jobs:Two questions: When would using
GPGME::Key.find
trigger this error? Is this gem thread-safe?Any insight would be much appreciated.