parent
ee17d004cd
commit
60584ef85a
|
@ -93,7 +93,11 @@ In 2.0 projects, the `Main` method of *Program.cs* has been simplified:
|
|||
|
||||
[!code-csharp[Main](../1x-to-2x/samples/AspNetCoreDotNetCore2.0App/AspNetCoreDotNetCore2.0App/Program.cs?highlight=8-11)]
|
||||
|
||||
The adoption of this new 2.0 pattern is highly recommended and is required in order for product features like [Entity Framework Core Migrations](xref:data/ef-mvc/migrations) to work.
|
||||
The adoption of this new 2.0 pattern is highly recommended and is required for product features like [Entity Framework Core Migrations](xref:data/ef-mvc/migrations) to work. For example, running `Update-Database` from the Package Manager Console window or `dotnet ef database update` from the command line (on projects converted to ASP.NET Core 2.0) generates the following error:
|
||||
|
||||
```
|
||||
Unable to create an object of type '<Context>'. Add an implementation of 'IDesignTimeDbContextFactory<Context>' to the project, or see https://go.microsoft.com/fwlink/?linkid=851728 for additional patterns supported at design time.
|
||||
```
|
||||
|
||||
<a name="view-compilation"></a>
|
||||
|
||||
|
@ -133,4 +137,4 @@ If you are using the Application Insights SDK directly, continue to do so. The 2
|
|||
ASP.NET Core 2.0 has a new authentication model and a number of significant changes to ASP.NET Core Identity. If you created your project with Individual User Accounts enabled, or if you have manually added authentication or Identity, see [Migrating Authentication and Identity to ASP.NET Core 2.0](xref:migration/1x-to-2x/identity-2x).
|
||||
|
||||
## Additional Resources
|
||||
- [Breaking Changes in ASP.NET Core 2.0](https://github.com/aspnet/announcements/issues?page=1&q=is%3Aissue+is%3Aopen+label%3A2.0.0+label%3A%22Breaking+change%22&utf8=%E2%9C%93)
|
||||
- [Breaking Changes in ASP.NET Core 2.0](https://github.com/aspnet/announcements/issues?page=1&q=is%3Aissue+is%3Aopen+label%3A2.0.0+label%3A%22Breaking+change%22&utf8=%E2%9C%93)
|
||||
|
|
Loading…
Reference in New Issue