@param $id

@return bool
@throws QueueException
557134
public function kickJob($id)
    {
        $payload = $this->getPayload($id);

        if ($payload[self::JOB_PAYLOAD_STATE] !== self::STATE_BURIED) {
            throw new QueueException(' Cannot kick state unsupported!' . $payload[self::JOB_PAYLOAD_STATE]);
        }

        $keyReady = $this->getKeyReady($payload[self::JOB_PAYLOAD_QUEUE]);
        $keyBuried = $this->getKeyBuried($payload[self::JOB_PAYLOAD_QUEUE]);
        $redisJobNamespace = $this->getRedisJobNamespace();

        $result = $this->getRedis()->transaction(
            function ($tx) use ($id, $payload, $keyBuried, $keyReady, $redisJobNamespace) {
                /** @var $tx \Predis\Client */
                $tx->zrem($keyBuried, $id);
                $payload = self::buildPayload($payload[self::JOB_PAYLOAD_QUEUE], self::STATE_READY);
                $tx->hset($redisJobNamespace, $id, $payload);
                $tx->rpush($keyReady, $id);
            }
        );

        return !in_array(false, $result);
    }
256287
public function has($id)
    {
        try {
             $em = $this->entityManager->getDoctrineEntityManager();
             $data = $em->getRepository($this->getEntityClass())->findOneBy(array(
                 'id' => $id,
             ));
             
             if ($data !== null) {
                 return true;
             }
             
             return false;
        } catch (\Exception $e) {
            throw new Exception('Cannot check if there is an entity for the given id "' . $id . '".', 0, $e);
        }
    }
323425
public function has($id) {
		try {
			$result = $this->getBackend()->exists($this->prepareId($id));
		}
		catch (PhalconCacheException $exception) {
			if ($this->operationsExceptions) {
				throw new OperationFailed('Checking of the data exiting in the cache failed due to the backend exception occurred: "' . $exception->getMessage() . '"', 0, $exception);
			} else {
				return false;
			}
		}
		
		return $result;
	}
451548
public function exists($id) {
        return (bool) $this->select()->where($this->getPrimaryKey(), $id)->count();
    }
1142911
public function get($id) {
		if (! $this->connectionCheckStatus) {
			$this->addServer();
		}
		
		$result = $this->getClient()->get($this->prepareId($id));
		
		return $result === false ? null : $result;
	}
916899
public function byId($id)
    {
        if ($user = $this->sentinel->getUserRepository()->findById($id)) {
            $this->sentinel->setUser($user);

            return true;
        }

        return false;
    }
983463
public function setId($id)
    {
        if ($this->hasData(self::P_ID)) {
            throw new JobException('Cant set id cause it is already sets!');
        }

        return $this->setData(self::P_ID, $id);
    }
104040
public function lock($id)
    {
        $id = (int) $id;
        if ($id <= 0) {
            throw new Exception('Invalid param id');
        }
        return $this->rest->put("$this->action/$id/lock");
    }
371526
public function fulfil($id)
	{
		$endpoint = new Fulfil($this->getTransport());
		$endpoint->setId($id);

		try {
			$result = $endpoint->performRequest();
		} catch (ResourceNotFoundException $e) {
			return false;
		}

		return $result['status'] == 204;
	}
446357
public function remove($id)
    {
        try {
            return $this->resource->hDel(static::CACHE_KEY, $id);
        } catch (ConnectionException $e) {
            return false;
        }
    }
415930
public function delete($id = null): bool
	{
		$instance = $this->read($id);

		return $instance->delete();
	}
774694
public function delete( $id ) {

		if ( $this->contains( $id ) ) {
			$this->count--;
			$this->cacheDeletes++;
			unset( $this->cache[ $id ] );
			unset( $this->ttl[ $id ] );
			return true;
		}

		return false;
	}
1272573
private function exists($id)
    {
        $query = 'SELECT ' . self::DIAGNOSTIC_ID . ' FROM ' . self::DIAGNOSTIC_TABLE . ' WHERE ' . self::DIAGNOSTIC_ID . ' = ?';
        $statement = $this->persistence->query($query, array($id));
        return (boolean)$statement->rowCount();
    }
53806
public function load($id)
    {
        $this->checkDB();
        $row = $this->loadInternal($id);

        if ($row === null) {
            return false;
        }

        $this->initFromRow($row);
        $this->generatePropertyHashes();
        return true;
    }
816938
public function deleteReserved($queue, $id)
    {
        $this->database->transaction(
            function () use ($id) {
                $this->database->createCommand()->delete($this->table, ['id' => $id])->execute();
            }
        );
    }
309597
public function has($id)
    {
        foreach ($this->containers as $container) {
            if ($container->has($id)) {
                return true;
            }
        }

        return false;
    }
231395
public function check_result($id)
  {
    if ( $d = $this->get($id) ){
      $t = new bbn\util\timer();
      $t->start();
      $res = $this->_exec($d['request'], $d['params']);
      $duration = (int)ceil($t->stop() * 1000);
      if ( $res !== $d['result'] ){
        $this->db->update('bbn_observers', [
          'result' => $res,
          'duration' => $duration
        ], [
          'id' => $id
        ]);
        return false;
      }
      return true;
    }
  }