3 ms·
Nice! We keep a single connection open using the standalone gem. But yeah you're right it would be an issue if you were connecting to Apple's servers in a resq
by vanstee 14y ago
Nice! We keep a single connection open using the standalone gem.
But yeah you're right it would be an issue if you were connecting to Apple's servers in a resque worker for example, since the socket would be opened in a new child for each job. I bet you could get around this though by opening a socket in the parent and using it in each child process. Reconnecting might be a little trickier though.
apnmachine looks pretty sweet. I'll have to check it out if I need something like that in the future.
- juliennakache 14y agoDon't know the standalone gem, I'll have to check that out. I'll be glad to get some feedback on apnmachine :)
- stevenharman 14y ago> the standalone gem @vanstee is referring the Grocer being a RubyGem and not needing other dependencies like Resque.