-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[2.0.0-preview1] Remove DbContextFactoryOptions #8314
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
Conversation
/// <returns> An instance of <typeparamref name="TContext" />. </returns> | ||
TContext Create([NotNull] DbContextFactoryOptions options); | ||
TContext Create([NotNull] string[] args); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be IEnumerable<string>
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I think so.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I call ToArray in the templates or push for IEnumerable all the way down?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There might also be value in keeping an array to mirror Main and drive home the point that this is an entry point into the application
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like both WebHost.CreateDefaultBuilder and IConfigurationBuilder.AddCommandLine (which it calls) are string[]
. Given that, I think we should keep it string[]
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm fine with keeping an array for that reason.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/// <returns> An instance of <typeparamref name="TContext" />. </returns> | ||
TContext Create([NotNull] DbContextFactoryOptions options); | ||
TContext Create([NotNull] string[] args); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good.
Part of #8164