# Aspire.Hosting.EntityFrameworkCore

- Module: `Aspire.Hosting.EntityFrameworkCore`
- Version: `17.0.0-preview.1.26565.2`
- Import path: `apphost/modules/aspire`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/bcfa151cdca6d0a573f22d5d9c23f9c727cb3b2f)
- Functions: `7`
- Types: `1`

## Handles

- [EFMigrationResource](/reference/api/go/aspire.hosting.entityframeworkcore/efmigrationresource.md) -- `handle` - 19 members -- Represents an EF Core migration resource associated with a project.

## Functions

- [AddEFMigrations](/reference/api/go/aspire.hosting.entityframeworkcore/addefmigrations.md) -- `method` - on `DotnetProgramResource` -- Adds EF Core migration management for polyglot AppHosts.
- [PublishAsMigrationBundle](/reference/api/go/aspire.hosting.entityframeworkcore/publishasmigrationbundle.md) -- `method` - on `EFMigrationResource` -- Configures the EF migration resource to generate a migration bundle during publishing.
- [PublishAsMigrationScript](/reference/api/go/aspire.hosting.entityframeworkcore/publishasmigrationscript.md) -- `method` - on `EFMigrationResource` -- Configures the EF migration resource to generate a migration script during publishing.
- [RunDatabaseUpdateOnStart](/reference/api/go/aspire.hosting.entityframeworkcore/rundatabaseupdateonstart.md) -- `method` - on `EFMigrationResource` -- Configures the EF migration resource to run database update when the AppHost starts.
- [WithMigrationNamespace](/reference/api/go/aspire.hosting.entityframeworkcore/withmigrationnamespace.md) -- `method` - on `EFMigrationResource` -- Configures the namespace for new migrations created with the Add Migration command.
- [WithMigrationOutputDirectory](/reference/api/go/aspire.hosting.entityframeworkcore/withmigrationoutputdirectory.md) -- `method` - on `EFMigrationResource` -- Configures the output directory for new migrations created with the Add Migration command.
- [WithMigrationsProject](/reference/api/go/aspire.hosting.entityframeworkcore/withmigrationsproject.md) -- `method` - on `EFMigrationResource` -- Configures a separate project containing migrations for polyglot AppHosts.
