Fire a "error" event

@param Hoa\Event\Bucket $bucket
359001
public function onError(Bucket $bucket)
    {
        $data = $bucket->getData();

        if (isset($data['exception']) && $data['exception'] instanceof Quit) {
            throw $data['exception'];
        }

        $this->onEvent('error', $bucket);
    }
413395
protected function fireAttemptingEvent($username, $password)
    {
        if (isset($this->events)) {
            $this->events->fire(new Attempting($this->connection, $username, $password));
        }
    }
114074
protected function triggerError($status, \ErrorException $exception)
    {
        $this->result = false;
        $this->errorStatus = $status;
        $this->errorException = $exception;
        $this->error && call_user_func($this->error, $this, $status, $exception);
    }
1201238
public synchronized void invalidateBucket(String bucket) {
    PrefixKey key = new PrefixKey(bucket, "");

    getPrefixSubMap(itemMap, key).clear();
    getPrefixSubMap(prefixMap, key).clear();
  }
1098032
protected void fireMPDErrorEvent(String message) {
        ErrorEvent ee = new ErrorEvent(this, message);

        for (ErrorListener el : errorListeners) {
            el.errorEventReceived(ee);
        }
    }
549481
public function onError(ErrorEvent $event){
        \Yii::error($event->sender." ".$event->errstr." ".$event->code, 'beyod');
    }
1117911
public function onError(ErrorEvent $event)
    {
        $request = $event->getRequest();
        $response = $event->getResponse();

        // Only sign requests using "auth"="oauth"
        if ('oauth' !== $request->getConfig()['auth']) {
            return;
        }

        // Only deal with Unauthorized response.
        if ($response && $response->getStatusCode() != 401) {
            return;
        }

        // If we already retried once, give up.
        if ($request->getHeader('X-Guzzle-Retry')) {
            return;
        }

        // Delete the previous access token, if any
        $this->deleteAccessToken();

        // Acquire a new access token, and retry the request.
        $accessToken = $this->getAccessToken();
        if ($accessToken != null) {
            $newRequest = clone $request;
            $newRequest->setHeader('X-Guzzle-Retry', '1');

            $this->accessTokenSigner->sign($newRequest, $accessToken);

            $event->intercept(
                $event->getClient()->send($newRequest)
            );
        }
    }
1310723
private function fireEvent($event)
    {
        $env = $this->formatEventName($event);

        if (emitter()->bound($env)) {
            emitter()->emit($env, $this);
        }
    }
17954
protected function setOwnerError()
    {
        if (strlen($this->getMessage()) && !$this->owner->getError()) {
            $this->owner->setError($this->getMessage());
        }
    }
287619
public function setError($error, $key=null)
	{
		if ($key !== null)
		{
			$this->_errors[$key] = $error;
		}
		else
		{
			array_push($this->_errors, $error);
		}
		return $this;
	}
1284990
function(bucket, callback) {
    deleteObjects(bucket, function(err, data) {
      if (err) callback(err);
      deleteBucket(bucket, callback);
    });
  }
1301703
private function setError($error) {
		
		$this->errors[] = $error;
		$app = Application::getInstance();
		$app->logError($error);
		
	}
277623
protected function handleError($event)
    {
        if (error_reporting() & $event->code) {
            $this->getSentryClient()->captureException(
                $this->createErrorException($event->message, $event->code, $event->file, $event->line)
            );
        }
        parent::handleError($event);
    }
371298
public function fire()
	{
		$configurator = new Configurator($this);
		$configurator->configure(
			$this->argument('app-id'),
			$this->option('config'),
			$this->option('bucket'));
	}
393537
public function connectCommand(string $bucket): void
    {
        try {
            $storageClient = $this->storageFactory->create();
        } catch (\Exception $e) {
            $this->outputLine('<error>%s</error>', [$e->getMessage()]);
            exit(1);
        }

        $bucketName = $bucket;
        $bucket = $storageClient->bucket($bucketName);

        $this->outputLine('Writing test object into bucket (%s) ...', [$bucketName]);
        $bucket->upload(
            'test',
            [
                'name' => 'Flownative.Google.CloudStorage.ConnectionTest.txt',
                'metadata' => [
                    'test' => true
                ]
            ]
        );

        $this->outputLine('Retrieving test object from bucket ...');
        $this->outputLine('<em>' . $bucket->object('Flownative.Google.CloudStorage.ConnectionTest.txt')->downloadAsString() . '</em>');

        $this->outputLine('Deleting test object from bucket ...');
        $bucket->object('Flownative.Google.CloudStorage.ConnectionTest.txt')->delete();

        $this->outputLine('OK');
    }
1124581
private void fireConnectionError(SQLException e) {
    Code code = Code.UNKNOWN;
    if (e instanceof CloudSpannerSQLException) {
      code = ((CloudSpannerSQLException) e).getCode();
    }
    if (!isFatalState(code)) {
      return;
    }
    fireConnectionFatalError(e);
  }
1266839
public function dropBucket($bucket)
    {
        $path = "/drop/".$bucket;
        list(, $error) = $this->rsPost($path);
        return $error;
    }