$args[] = (string)$this->serialize( $item );
}
static $script =
+ /** @lang Lua */
<<<LUA
local kUnclaimed, kSha1ById, kIdBySha1, kDelayed, kData, kQwJobs = unpack(KEYS)
-- First argument is the queue ID
*/
protected function popAndAcquireBlob( RedisConnRef $conn ) {
static $script =
+ /** @lang Lua */
<<<LUA
local kUnclaimed, kSha1ById, kIdBySha1, kClaimed, kAttempts, kData = unpack(KEYS)
local rTime = unpack(ARGV)
$conn = $this->getConnection();
try {
static $script =
+ /** @lang Lua */
<<<LUA
local kClaimed, kAttempts, kData = unpack(KEYS)
local id = unpack(ARGV)
private function getGlobalKey( $name ) {
$parts = [ 'global', 'jobqueue', $name ];
foreach ( $parts as $part ) {
- if ( !preg_match( '/[a-zA-Z0-9_-]+/', $part ) ) {
- throw new InvalidArgumentException( "Key part characters are out of range." );
- }
+ if ( !preg_match( '/[a-zA-Z0-9_-]+/', $part ) ) {
+ throw new InvalidArgumentException( "Key part characters are out of range." );
+ }
}
return implode( ':', $parts );