Closed mmenozzi closed 5 years ago
@kelunik what do you think? Maybe the issue is in some underlying library...
Here is the Travis failed build for the reserved-not-as-put-fix
: https://travis-ci.org/amphp/beanstalk/builds/516073149
@mmenozzi This is probably caused by the maximum job size, see e.g. https://stackoverflow.com/q/35782549/2373138, but given that, BeanstalkD should return an error in that case, which it doesn't.
I don’t think so because the default maximum job size is 65535 bytes and I didn’t changed it. If you change the string length to 65536 you'll receive the proper job too big exception.
@mmenozzi Right, this is some parser bug... fixed it. Should I tag a release or do you want to?
Thank you @kelunik! I’ll tag the new release tomorrow afternoon.
Here we go @kelunik: https://github.com/amphp/beanstalk/releases/tag/v0.2.5 🎉
It seems that for jobs with a big payload (for example a 64k payload) the
reserve
function doesn't return the entire payload which was put. Given the following script:The output is:
But it should be:
It seems a weird buffering issue because if you try to uncomment the
bury
function call the output become:I think this happens because the remaining part of the job payload is then treated as the response of the
bury
command.I pushed the
reserved-not-as-put-fix
branch with a failing test about this issue.