Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document Migration Bundles #3527

Merged
merged 1 commit into from
Nov 8, 2021
Merged

Document Migration Bundles #3527

merged 1 commit into from
Nov 8, 2021

Conversation

bricelam
Copy link
Contributor

@bricelam bricelam commented Nov 2, 2021

Resolves #3437

@bricelam bricelam requested a review from a team November 2, 2021 20:43
@@ -348,3 +363,4 @@ dotnet ef migrations script 20180904195021_InitialCreate

* [Migrations](xref:core/managing-schemas/migrations/index)
* [Reverse Engineering](xref:core/managing-schemas/scaffolding)
* [Compiled models](../performance/advanced-performance-topics.md#compiled-models)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know this is just a reference, but should we link to the appropriate doc page for each (relevant) option? That seems more helpful than some generic "additional resources" links

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use xref to page uid instead of referencing md file.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also do that.

The see also section is to help guide users who still have questions about a related topic after reaching the end of an article.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use xref to page uid instead of referencing md file.


* Executing SQL scripts requires additional tools.
* The transaction handling and continue-on-error behavior of these tools are inconsistent and sometimes unexpected.
* Bundles can be generated as part of your CI process and executed later as part of your deployment process.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is true of SQL scripts though too, right? Not that we shouldn't mention it, but it doesn't seem like a reason to prefer bundles over SQL scripts per se...

@@ -156,6 +159,76 @@ Note that this can be used to roll back to an earlier migration as well.

For more information on applying migrations via the command-line tools, see the [EF Core tools reference](xref:core/cli/index).

## Bundles
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So at least thinking like a clueless newcomer, this kinda begs the question of why we SQL scripts are still "the recommended way" to apply migrations (above). It may be good to add a point or two about where SQL scripts are still better (e.g. allow inspection of the SQL before application, etc.).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's why I left SQL scripts first in the document. Those points are made there and are still just as valid after the introduction of bundles.

@bricelam bricelam merged commit 0957207 into dotnet:main Nov 8, 2021
@@ -310,3 +326,4 @@ Update-Database 20180904195021_InitialCreate -Connection your_connection_string

* [Migrations](xref:core/managing-schemas/migrations/index)
* [Reverse Engineering](xref:core/managing-schemas/scaffolding)
* [Compiled models](../performance/advanced-performance-topics.md#compiled-models)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use xref to page uid instead of referencing md file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Document migrations bundles
4 participants