-
Notifications
You must be signed in to change notification settings - Fork 119
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rework enqueuing system to ensure records got deleted accordingly #75
Comments
That's weird, do you have the associated backtrace? Is it raised from the |
Yes it is raised from |
@redox Here is an example of a failing spec backtrace :
|
Can you just try to run a |
|
Actually, it doesn't work only after I destroy the record and the
|
Could you just try with another (non-algolia) method? From what I understand, your |
I am only using what's suggested in the readme for delayedjob. |
+1. I am having the same problem. |
I ran into the same issue. The workaround I've used is to delete the record by ID from the index in the background job. It seems to work fine def trigger_delayed_job(record, remove)
if remove
index = Algolia::Index.new("#{self.name}_#{Rails.env}")
index.delete_object(record.uuid)
else
obj = self.find(record.id)
obj.index!
end
end |
Hi,
I tried this snippet of code as suggested in the readme for enqueuing Algolia operations :
My application is running rails 3.2.22 with ruby 2.2.2 and DelayedJob 4.0.6
Without delayed job, the auto_remove works perfectly fine.
However, when I try to remove the project with the enqueuing system set, I get the following error :
after further research, I found this DJ related issue : collectiveidea/delayed_job#820
Is there any workaround to this, since I want to remove my model asynchronously from Algolia only after my project has been deleted
The text was updated successfully, but these errors were encountered: