My question for you, as an educated Rails developer, if you were building an application like this, how would you handle the queuing and sending? Would you use cron and write a ruby script to do the sending? Or would you use some job queuing library? I know there are a bunch of job queue libraries out there, but I'm not sure if they are appropriate or overkill for such a simple scenario. I'm curious if you would do things the same or different.
Sorry if this is a silly question. I'm still relatively new to Ruby, and I'm the one with the most Ruby knowledge at work.
--Andrew
--
(Sent from phone; please excuse brevity.)
> --
> You received this message because you are subscribed to the Google Groups "pdxruby" group.
> To post to this group, send email to pdx...@googlegroups.com.
> To unsubscribe from this group, send email to pdxruby+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/pdxruby?hl=en.
>
You may want to log your outgoing mails. In that case, I'd still
simply send them out as soon as they were requested, but log them
after in whichever format you please.
Matthew Boeh
On Mon, Apr 16, 2012 at 10:32 PM, Sam Livingston-Gray <gee...@gmail.com> wrote:
Anyway, depending on what dependencies you're willing to take on, I've found Resque to be the lowest maintenance job queue around. It has a very active developer community to boot. If you're in Rails land, resque_notify (I think that's what it's called?) will automagically queue any ActionMailer for asynchronous delivery. Resque is backed by Redis, which makes some dev ops' hair stand on end but, like Resque itself, Redis has been crazy low maintenance. So much so, in fact, that I've been able to apt-get install redis-server and forget about it in the past!
Or girl_friday, I suppose.
Matthew Boeh
Or services like SendGrid. I've pumped a TON of mail through that service...and it's very cheap. Seems to be very similar to what you guys are making...
I feel like sidekiq (or any background worker system) is overkill for
what we know of this use case. You might want to background SMTP
connections if they're done inline in an existing web app, but if the
service is completely dedicated to that purpose I'd think a threaded
web server would be preferable.
Or girl_friday, I suppose.
Is there a reason you're using MongoDB for this? This kind of job
relies heavily on timestamp-based queries on the database, and SQL
databases generally perform better in that situation.
Matthew Boeh
> --
> You received this message because you are subscribed to the Google Groups
> "pdxruby" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/pdxruby/-/JXHS32OxRYQJ.
--
You received this message because you are subscribed to the Google Groups "pdxruby" group.
To view this discussion on the web visit https://groups.google.com/d/msg/pdxruby/-/JXHS32OxRYQJ.