Download & Extend

presence of $view object in parameters array chokes job_queue table

Project:Views Bulk Operations (VBO)
Version:6.x-1.x-dev
Component:Documentation
Category:bug report
Priority:critical
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I have a VBO of users to whom I send an email with the Tokenized email action. This is set to use job queue to prevent batch API memory problems.

The job queue page reports errors about unserializing arrays. Upon investigation, it turns out this is because the serialized job arguments in the {job_queue}.arguments table column are truncated -- the string is simply too long, it seems.

The problem is caused partly by the view itself -- the entire $view object -- being passed in to job_queue_add, where it gets serialized into the job's arguments -- this creates way too much data to fit.

Comments

#1

Status:active» needs review
AttachmentSize
703750.vbo_.unset-view-param.patch 983 bytes

#2

Version:6.x-1.8» 6.x-1.x-dev
Status:needs review» fixed

Thanks for your report. I've committed your fix, even though it is not ideal because actions that rely on the presence of this parameter will break if used with job_queue. A better fix would be to save just enough info in the job parameters to recreate the view when the job function is called. I'll keep it as is for now because I want to make a new release.

#3

Maybe set a 'view_name' key in the parameters array? Though I suppose you need to set arguments, display, and filter values too...

#4

Yes that's the general idea. However, I don't want to have to recreate the view for every single job instance.

#5

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.