diff --git a/src/EFCore.PG/Migrations/Internal/NpgsqlMigrator.cs b/src/EFCore.PG/Migrations/Internal/NpgsqlMigrator.cs index 8691f9322..e8a0bea28 100644 --- a/src/EFCore.PG/Migrations/Internal/NpgsqlMigrator.cs +++ b/src/EFCore.PG/Migrations/Internal/NpgsqlMigrator.cs @@ -126,7 +126,7 @@ public override async Task MigrateAsync(string? targetMigration, CancellationTok await _connection.OpenAsync(cancellationToken).ConfigureAwait(false); try { - await npgsqlConnection.ReloadTypesAsync().ConfigureAwait(false); + await npgsqlConnection.ReloadTypesAsync(cancellationToken).ConfigureAwait(false); } catch { diff --git a/src/EFCore.PG/Storage/Internal/NpgsqlDatabaseCreator.cs b/src/EFCore.PG/Storage/Internal/NpgsqlDatabaseCreator.cs index db12255d0..4034f5ef2 100644 --- a/src/EFCore.PG/Storage/Internal/NpgsqlDatabaseCreator.cs +++ b/src/EFCore.PG/Storage/Internal/NpgsqlDatabaseCreator.cs @@ -394,7 +394,7 @@ await Dependencies.MigrationCommandExecutor.ExecuteNonQueryAsync(commands, conne await npgsqlConnection.OpenAsync(cancellationToken).ConfigureAwait(false); try { - await npgsqlConnection.ReloadTypesAsync().ConfigureAwait(false); + await npgsqlConnection.ReloadTypesAsync(cancellationToken).ConfigureAwait(false); } catch {