I am using Soulmate in production, and I am facing weird performance issues. The Soulmate sinatra app doesn't respond to some queries at all, whereas for other queries the performance is pretty good.
Thanks a lot Ryan for this and the other Railscasts that you have done on deployment.
On Capistrano's from-the-beginning wiki, there is a section on avoiding deploy:cold which says
First of all, deploy:cold was a bad idea. It attempted to do what I have described in this tutorial, but without enough opinions, and without enough options for configuration. I’ve come to the conclusion that setting up a new app on a new machine is not something that can be generically automated.
Great episode Ryan. The Devise Omniauth documentation isn't much detailed now and I was having trouble understanding the code samples.
In the episode, you mention that adding a separate Authentications model is 'a complexity that is not always needed'. If one requires to associate the user account with multiple providers, should we make a separate authentications model or add different keys to user model like twitter_uid, facebook_uid as Adam Sunderland mentions in an earlier comment?
Why not use Postgres' full-text search @@ operator rather than LIKE?
Thanks a lot. I wasted a couple of hours doing all sorts of things around this.
I am using Soulmate in production, and I am facing weird performance issues. The Soulmate sinatra app doesn't respond to some queries at all, whereas for other queries the performance is pretty good.
Anyways, if you decide to use Soulmate, you should go through http://patshaughnessy.net/2011/11/23/finding-your-soulmate-autocomplete-with-redis-in-rails-3-1 and Salvatore's original post on doing autocomplete with redis - http://oldblog.antirez.com/post/autocomplete-with-redis.html
@Ryan It will be great if you can add these to the show notes.
The way soulmate does this is to add a
after_save
hook to load the term in to redis.If you are getting a
gem not installed
error, then do checkout the railscasts on zero downtime deployment. You need to send aUSR2 signal
and setpreload_app=true
. More details here at stackoverflowThanks a lot Ryan for this and the other Railscasts that you have done on deployment.
On Capistrano's from-the-beginning wiki, there is a section on avoiding
deploy:cold
which saysRyan, would you suggest to avoid
deploy:cold
?Didn't know this. Neat!
Can you elaborate on what you mean by n+1 problems?
For accessing the total number of votes for a haiku, we need to use
haiku.reputation_for(:votes)
instead ofhaiku.reputation_value_for(:votes)
.Great episode Ryan. The Devise Omniauth documentation isn't much detailed now and I was having trouble understanding the code samples.
In the episode, you mention that adding a separate Authentications model is 'a complexity that is not always needed'. If one requires to associate the user account with multiple providers, should we make a separate authentications model or add different keys to user model like twitter_uid, facebook_uid as Adam Sunderland mentions in an earlier comment?