-
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
Fix ActiveJob::DeserializationError issue #369
Conversation
I suppose it has some breaking changes because if you have enqueued some |
Any timeline for review of this? |
Could this (or a similar fix) please be merged? Right now the gem is basically broken when it comes to removing records from the index. |
Hi @marckohlbrugge , @lukad03 and @zhukovpe ! Thanks for your understanding! |
@chloelbn does this library have a pattern to remove objects from an algolia index after the record has been deleted from the db? Specifically, is there a good way to get the object id of a record in a particular index after that record has been deleted from the db? |
Describe your change
Change job arguments to receive a record identifier and a model class name (for index info) as a parameter instead of a model instance. Add a method to remove a record from algolia index by id.
What problem is this fixing?
Asynchronous index update enqueues a job with the specific object instance as a parameter. This specific object cannot be deserialised from the parameter during job processing for the deleted record. An asynchronous index update job for the deleted record will always fail.
Breaking changes
Previously deployed AlgoliaJob will fail if executed with the new version