From 4eafce998d36bce9d3a662f2a784009137600d88 Mon Sep 17 00:00:00 2001 From: shimon Date: Sun, 3 Nov 2024 14:58:09 +0200 Subject: [PATCH] Rollback cross regions connections --- src/Appwrite/Event/Build.php | 1 - src/Appwrite/Event/Certificate.php | 1 - src/Appwrite/Event/Database.php | 1 - src/Appwrite/Event/Event.php | 9 --------- src/Appwrite/Event/Func.php | 1 - src/Appwrite/Event/Migration.php | 1 - 6 files changed, 14 deletions(-) diff --git a/src/Appwrite/Event/Build.php b/src/Appwrite/Event/Build.php index 237803a7ff..b8cb62a6f8 100644 --- a/src/Appwrite/Event/Build.php +++ b/src/Appwrite/Event/Build.php @@ -115,7 +115,6 @@ class Build extends Event $client = new Client($this->queue, $this->connection); return $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'resource' => $this->resource, 'deployment' => $this->deployment, diff --git a/src/Appwrite/Event/Certificate.php b/src/Appwrite/Event/Certificate.php index 188e6dd27d..85058c96fe 100644 --- a/src/Appwrite/Event/Certificate.php +++ b/src/Appwrite/Event/Certificate.php @@ -77,7 +77,6 @@ class Certificate extends Event $client = new Client($this->queue, $this->connection); return $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'domain' => $this->domain, 'skipRenewCheck' => $this->skipRenewCheck diff --git a/src/Appwrite/Event/Database.php b/src/Appwrite/Event/Database.php index 4b53b71d99..f5f29f5d04 100644 --- a/src/Appwrite/Event/Database.php +++ b/src/Appwrite/Event/Database.php @@ -122,7 +122,6 @@ class Database extends Event try { $result = $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'user' => $this->user, 'type' => $this->type, diff --git a/src/Appwrite/Event/Event.php b/src/Appwrite/Event/Event.php index 9445ea4129..0cf28ebe5c 100644 --- a/src/Appwrite/Event/Event.php +++ b/src/Appwrite/Event/Event.php @@ -111,14 +111,6 @@ class Event return $this->event; } - - - public function getSourceRegion(): string - { - var_dump('event Source Region='.System::getEnv('_APP_REGION')); - return System::getEnv('_APP_REGION'); - } - /** * Set project for this event. * @@ -331,7 +323,6 @@ class Event $client = new Client($this->queue, $this->connection); return $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'user' => $this->user, 'userId' => $this->userId, diff --git a/src/Appwrite/Event/Func.php b/src/Appwrite/Event/Func.php index b14e781750..4dad5802f7 100644 --- a/src/Appwrite/Event/Func.php +++ b/src/Appwrite/Event/Func.php @@ -222,7 +222,6 @@ class Func extends Event $events = $this->getEvent() ? Event::generateEvents($this->getEvent(), $this->getParams()) : null; return $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'user' => $this->user, 'userId' => $this->userId, diff --git a/src/Appwrite/Event/Migration.php b/src/Appwrite/Event/Migration.php index dd8db4097e..e57ac3c87c 100644 --- a/src/Appwrite/Event/Migration.php +++ b/src/Appwrite/Event/Migration.php @@ -79,7 +79,6 @@ class Migration extends Event $client = new Client($this->queue, $this->connection); return $client->enqueue([ - 'sourceRegion' => $this->getSourceRegion(), 'project' => $this->project, 'user' => $this->user, 'migration' => $this->migration,