Asynchronous Process in Ruby on Rails

1

I have a process that makes a match between the items [books, movies, songs and games] of a certain user on Facebook with the items registered in my database. The problem is that the whole process takes around 18 ~ 25 seconds and I would not want to leave the user waiting that long. I was thinking of how to log in with your Facebook account, trigger type a thread (I do not know if it is possible in RoR) and redirect it to root_path and when the process ends up displaying a div some message .

How should this be done in Ruby On Rails, that is, is there any gem for this purpose or some good practice for it?

Thank you in advance ..

    
asked by anonymous 01.06.2014 / 02:59

2 answers

3

There are several alternatives to back end processes. Take a look at the link I believe should resolve and while the user expects you make calls in ajax p know if the thread has already been completed. There is a gem that only checks job status in sidekiq

    
01.06.2014 / 05:12
0

Here is a list of possible gems for this:

link

    
01.06.2014 / 05:42