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

Deprecate AbstractSchemaManager::createSchema() in favor of introspectSchema() #5613

Merged
merged 2 commits into from
Aug 23, 2022

Conversation

morozov
Copy link
Member

@morozov morozov commented Aug 23, 2022

Q A
Type deprecation

The current API has the following problems:

  1. The createSchema() name is misleading since unlike other create*() methods (e.g. createTable()) which create an object in the database, createSchema() creates an internal representation of the schema by introspecting it.
  2. The fact that this method existed didn't allow to introduce a method that would actually create the schema in Replace schema SQL collectors with SQL builders #5416.

This pull request proposes to deprecate AbstractSchemaManager::createSchema() in favor of introspectSchema().

The name of the introspectSchema() method being introduced is slightly inconsistent with AbstractSchemaManager::getTable() recently introduced in #5595. However, instead of naming it getSchema() for consistency, I believe it's not too late to rename getTable() to introspectTable(). That would be more precise.

@morozov morozov marked this pull request as ready for review August 23, 2022 17:31
@morozov morozov added this to the 3.5.0 milestone Aug 23, 2022
@morozov morozov requested a review from greg0ire August 23, 2022 17:32
@morozov morozov merged commit 5f83788 into doctrine:3.5.x Aug 23, 2022
@morozov morozov deleted the deprecate-create-schema branch August 23, 2022 18:20
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants