Skip to content

Commit 249535c

Browse files
committed
DOCSP-35933: Upgrade version guide
1 parent 8a7c780 commit 249535c

File tree

1 file changed

+61
-5
lines changed

1 file changed

+61
-5
lines changed

docs/upgrade.txt

Lines changed: 61 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
.. _laravel-upgrading:
22

3-
=========
4-
Upgrading
5-
=========
3+
===================
4+
Upgrade ODM Version
5+
===================
66

77
.. facet::
88
:name: genre
@@ -11,11 +11,67 @@ Upgrading
1111
.. meta::
1212
:keywords: php framework, odm, code example
1313

14+
Overview
15+
--------
16+
17+
On this page, you can learn how to upgrade {+odm-short+} to a new version. This page also
18+
includes the changes you must make to your application to upgrade your ODM version
19+
without losing functionality, if applicable.
20+
1421
The PHP library uses `semantic versioning <https://semver.org/>`__. Upgrading
1522
to a new major version may require changes to your application.
1623

17-
Upgrading from version 3 to 4
18-
-----------------------------
24+
How to Upgrade
25+
--------------
26+
27+
Before you upgrade, perform the following actions:
28+
29+
- Ensure the new driver version is compatible with the {+mdb-server+} version
30+
your application connects to and the version of Node.js that your
31+
application runs on. See the :ref:`<node-compatibility>`
32+
page for this information.
33+
- Address any breaking changes between the version of the driver
34+
your application currently uses and your planned upgrade version in the
35+
:ref:`<node-breaking-changes>` section of this guide. To learn
36+
more about the {+mdb-server+} release compatibility changes, see the
37+
:ref:`<node-server-support-changes>` section.
38+
39+
.. tip::
40+
41+
You can minimize the amount of changes that you need to make to your
42+
application when upgrading driver versions by using the
43+
:ref:`{+stable-api+} <nodejs-stable-api>`.
44+
45+
To upgrade your driver version, run the following command in your application's
46+
directory:
47+
48+
.. code-block:: bash
49+
50+
npm install mongodb@{+version+}
51+
52+
To upgrade to a different version of the driver, replace the information after the
53+
``@`` symbol with your preferred version number. For more information about the
54+
``npm install`` command, see the `npm-install <https://docs.npmjs.com/cli/v10/commands/npm-install?v=true>`__
55+
npm documentation.
56+
57+
.. _laravel-breaking-changes:
58+
59+
Breaking Changes
60+
----------------
61+
62+
A breaking change is a modification in a convention or behavior in
63+
a specific version of {+odm-short+} that may prevent your application from
64+
working as expected.
65+
66+
The breaking changes in this section are categorized by the major
67+
version releases that introduced them. When upgrading ODM versions,
68+
address all the breaking changes between your current version and the
69+
planned upgrade version.
70+
71+
.. _laravel-breaking-changes-v4.x:
72+
73+
Version 4.x Breaking Changes
74+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1975

2076
- Laravel 10.x is required
2177

0 commit comments

Comments
 (0)