Depend on doctrine/dbal instead of cakephp/database
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 4.5k
- Forks
- 884
- PR merge metrics
- No merged PRs in 30d
Description
Hello guys, I would like to propose change database abstraction to doctrine/dbal.
Look at cakephp/database's (v5) dependency tree:
/var/www/html $ composer show cakephp/database --tree
cakephp/database 5.0.0 Flexible and powerful Database abstraction library with a familiar PDO-like API
├──cakephp/chronos ^3.0
│ └──php >=8.1
├──cakephp/core ^5.0
│ ├──cakephp/utility ^5.0
│ │ ├──cakephp/core ^5.0 (circular dependency aborted here)
│ │ └──php >=8.1
│ ├──league/container ^4.2
│ │ ├──php ^7.2 || ^8.0
│ │ └──psr/container ^1.1 || ^2.0
│ │ └──php >=7.4.0
│ ├──php >=8.1
│ └──psr/container ^2.0
│ └──php >=7.4.0
├──cakephp/datasource ^5.0
│ ├──cakephp/core ^5.0
│ │ ├──cakephp/utility ^5.0
│ │ │ ├──cakephp/core ^5.0 (circular dependency aborted here)
│ │ │ └──php >=8.1
│ │ ├──league/container ^4.2
│ │ │ ├──php ^7.2 || ^8.0
│ │ │ └──psr/container ^1.1 || ^2.0
│ │ │ └──php >=7.4.0
│ │ ├──php >=8.1
│ │ └──psr/container ^2.0
│ │ └──php >=7.4.0
│ ├──php >=8.1
│ └──psr/simple-cache ^2.0 || ^3.0
│ └──php >=8.0.0
├──php >=8.1
└──psr/log ^3.0
└──php >=8.0.0
vs DBAL's:
/var/www/html $ composer show doctrine/dbal --tree
doctrine/dbal 3.6.6 Powerful PHP database abstraction layer (DBAL) with many features for database schema introspection and management.
├──composer-runtime-api ^2
├──doctrine/cache ^1.11|^2.0
│ └──php ~7.1 || ^8.0
├──doctrine/deprecations ^0.5.3|^1
│ └──php ^7.1 || ^8.0
├──doctrine/event-manager ^1|^2
│ └──php ^8.1
├──php ^7.4 || ^8.0
├──psr/cache ^1|^2|^3
│ └──php >=8.0.0
└──psr/log ^1|^2|^3
└──php >=8.0.0
For me, it looks like too much dependencies for a database abstraction (for example Cake's core which needs DI container), while DBAL has only what is needed: small deprecations wrapper and lib for events.
Would You consider changing db abstraction to DBAL? I can do a PR.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No files, tests, or entry points are named. Start by reviewing the composer dependency declarations and locating Phinx usage of cakephp/database; determine the compatibility and migration scope for doctrine/dbal, with the work done when the abstraction is replaced without breaking the project's existing behavior and tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- database
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100