Skip to content

Commit 641330b

Browse files
chasengreg0ire
andauthored
Add doctrine/dbal to project composer.json (#9152)
As discussed in #9078 when entities utilize data mappings which are provided by the dbal lib it is expected behavior that users will explicitly define their dependency on the package. Co-authored-by: Grégoire Paris <postmaster@greg0ire.fr>
1 parent 35e680c commit 641330b

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

docs/en/tutorials/getting-started.rst

+10-1
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ that directory with the following contents:
8181

8282
{
8383
"require": {
84-
"doctrine/orm": "^2.6.2",
84+
"doctrine/orm": "^2.10.2",
85+
"doctrine/dbal": "^3.1.1",
8586
"symfony/yaml": "2.*",
8687
"symfony/cache": "^5.3"
8788
},
@@ -112,6 +113,14 @@ Add the following directories:
112113
.. note::
113114
The YAML driver is deprecated and will be removed in version 3.0.
114115
It is strongly recommended to switch to one of the other mappings.
116+
.. note::
117+
It is strongly recommended that you require ``doctrine/dbal`` in your
118+
``composer.json`` as well, because using the ORM means mapping objects
119+
and their fields to database tables and their columns, and that
120+
requires mentioning so-called types that are defined in ``doctrine/dbal``
121+
in your application. Having an explicit requirement means you control
122+
when the upgrade to the next major version happens, so that you can
123+
do the necessary changes in your application beforehand.
115124

116125
Obtaining the EntityManager
117126
---------------------------

0 commit comments

Comments
 (0)