|Issue tags:||needs backport to D7|
Discussion with Queue system maintainer Mark Sonnabaum while trying to use the core queue API for more complex tasks, I'm running into a couple bugs/flaws.
The more annoying is that the createItem() method returns a boolean instead of the ID of the queue item, for no useful reason. This makes it hard to create an item in the queue an watch for it's appearance again in a worker function, for example.
All likely back-ends (SQL, redis, beanstalk) support returning an ID, and the change from bool to int/FALSE shouldn't break any existing code.
The other problem is that the properties of the $item fro claimItem are not clearly specified or documented. It's not even documented that the data is in $item-data! We should document a minimal set of properties as part of the APi so code can know what to expect to be present in all cases.
These changes should be back-portable to 7.x