hasTable('ngb_index')) { $t = $schema->createTable('ngb_index'); $t->addColumn('id', Types::BIGINT, ['autoincrement' => true, 'notnull' => true, 'unsigned' => true]); $t->addColumn('repository_id', Types::STRING, ['notnull' => true, 'length' => 32]); $t->addColumn('pack_id', Types::STRING, ['notnull' => true, 'length' => 32]); // Plain JSON list of blob entries. Blob ids are keyed hashes and reveal no content. $t->addColumn('entries', Types::TEXT, ['notnull' => true]); $t->setPrimaryKey(['id']); $t->addUniqueIndex(['repository_id', 'pack_id'], 'ngb_index_repo_pack'); } return $schema; } }