mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 17:08:45 +00:00
Iterator messages
This commit is contained in:
parent
46d5159fd0
commit
371f195f3a
1 changed files with 7 additions and 4 deletions
|
|
@ -52,15 +52,15 @@ class V19 extends Migration
|
|||
private function migrateDatabases(): void
|
||||
{
|
||||
foreach ($this->documentsIterator('databases') as $database) {
|
||||
$databaseTable = "database_{$database->getInternalId()}";
|
||||
Console::log("Migrating Collections of {$database->getId()} ({$database->getAttribute('name')})");
|
||||
|
||||
Console::info("Migrating Collections of {$database->getId()} ({$database->getAttribute('name')})");
|
||||
$databaseTable = "database_{$database->getInternalId()}";
|
||||
|
||||
$this->alterPermissionIndex($databaseTable);
|
||||
|
||||
foreach ($this->documentsIterator($databaseTable) as $collection) {
|
||||
$collectionTable = "{$databaseTable}_collection_{$collection->getInternalId()}";
|
||||
|
||||
Console::log("Migrating Collections of {$collectionTable} {$collection->getId()} ({$collection->getAttribute('name')})");
|
||||
$this->alterPermissionIndex($collectionTable);
|
||||
}
|
||||
}
|
||||
|
|
@ -78,7 +78,9 @@ class V19 extends Migration
|
|||
|
||||
Console::log("Migrating Collection \"{$id}\"");
|
||||
|
||||
$this->alterPermissionIndex($id);
|
||||
if (!in_array($id, ['files', 'collections'])) {
|
||||
$this->alterPermissionIndex($id);
|
||||
}
|
||||
|
||||
usleep(50000);
|
||||
}
|
||||
|
|
@ -171,6 +173,7 @@ class V19 extends Migration
|
|||
{
|
||||
foreach ($this->documentsIterator('buckets') as $bucket) {
|
||||
$id = "bucket_{$bucket->getInternalId()}";
|
||||
Console::log("Migrating Bucket {$id} {$bucket->getId()} ({$bucket->getAttribute('name')})");
|
||||
$this->alterPermissionIndex($id);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue