Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,6 @@ Parameters

.. versionadded:: 1.17

* - disableMD5
- boolean
- Whether to disable automatic MD5 generation when storing files.

Defaults to ``false``. Only ``true`` will be supported in 2.0.

.. versionadded:: 1.4

* - readConcern
- :php:`MongoDB\Driver\ReadConcern <class.mongodb-driver-readconcern>`
- The default read concern to use for bucket operations. Defaults to the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,6 @@ Parameters
- The chunk size in bytes. Defaults to the bucket's ``chunkSizeBytes``
option.

* - disableMD5
- boolean
- Whether to disable automatic MD5 generation when storing files.

Defaults to ``false``. Only ``true`` will be supported in 2.0.

.. versionadded:: 1.4

* - metadata
- array|object
- User data for the ``metadata`` field of the file document. If not
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,6 @@ Parameters
- The chunk size in bytes. Defaults to the bucket's ``chunkSizeBytes``
option.

* - disableMD5
- boolean
- Whether to disable automatic MD5 generation when storing files.

Defaults to ``false``. Only ``true`` will be supported in 2.0.

.. versionadded:: 1.4

* - metadata
- array|object
- User data for the ``metadata`` field of the file document. If not
Expand Down
8 changes: 0 additions & 8 deletions source/reference/method/MongoDBGridFSBucket__construct.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,6 @@ Parameters

.. versionadded:: 1.17

* - disableMD5
- boolean
- Whether to disable automatic MD5 generation when storing files.

Defaults to ``false``. Only ``true`` will be supported in 2.0.

.. versionadded:: 1.4

* - readConcern
- :php:`MongoDB\Driver\ReadConcern <class.mongodb-driver-readconcern>`
- The default read concern to use for bucket operations. Defaults to the
Expand Down
37 changes: 37 additions & 0 deletions source/whats-new.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ What's New
Learn about new features, improvements, and fixes introduced in the
following versions of the {+php-library+}:

* :ref:`Version 2.0 <php-lib-version-2.0>`

* :ref:`Version 1.20 <php-lib-version-1.20>`

* :ref:`Version 1.19 <php-lib-version-1.19>`
Expand All @@ -32,6 +34,26 @@ following versions of the {+php-library+}:

* :ref:`Version 1.15 <php-lib-version-1.15>`

.. _php-lib-version-2.0:

What's New in 2.0
-----------------

The {+library-short+} v2.0 release includes the following features,
improvements, and fixes:

- Removal of deprecated fields in GridFS types.

- The library does not calculate the ``md5`` field when a file is
uploaded to GridFS. If your application requires a file digest, you
must implement this process outside GridFS and store the values in
metadata.

- The fields ``contentType`` and ``aliases`` are no longer stored in
the ``files`` GridFS collection. If your application requires this
information, you must store it in metadata. To learn mor about
GridFS, see the :ref:`php-gridfs` guide.

.. _php-lib-version-1.20:

What's New in 1.20
Expand All @@ -42,6 +64,9 @@ What's New in 1.20
Support for {+mdb-server+} v3.6 is removed in this release of the
library.

The {+library-short+} v1.20 release includes the following features,
improvements, and fixes:

- Adds support for {+mdb-server+} v8.0.

- Adds support for Queryable Encryption (QE) range queries. To use this
Expand Down Expand Up @@ -75,6 +100,9 @@ and was added to keep version parity with the {+extension-short+}.
What's New in 1.18
------------------

The {+library-short+} v1.18 release includes the following features,
improvements, and fixes:

- Adds a new GridFS API to make it more convenient to work with files using PHP's
existing filesystem functions. The :phpmethod:`MongoDB\GridFS\Bucket::registerGlobalStreamWrapperAlias()`
method may be used to register a global alias for a GridFS bucket. After
Expand All @@ -96,6 +124,9 @@ To learn more about this release, see the `v1.18 Release Notes
What's New in 1.17
------------------

The {+library-short+} v1.17 release includes the following features,
improvements, and fixes:

- Introduces a new "codec" API for converting BSON to and from PHP objects.
More information on this feature may be found in the
:ref:`Codecs tutorial <php-codecs>`.
Expand Down Expand Up @@ -125,6 +156,9 @@ To learn more about this release, see the `v1.17 Release Notes
What's New in 1.16
------------------

The {+library-short+} v1.16 release includes the following features,
improvements, and fixes:

- Introduces support for :v7.0:`MongoDB 7.0 </release-notes/7.0>`.

- Introduces :phpmethod:`MongoDB\Database::createEncryptedCollection()`.
Expand All @@ -141,6 +175,9 @@ To learn more about this release, see the `v1.16 Release Notes
What's New in 1.15
------------------

The {+library-short+} v1.15 release includes the following features,
improvements, and fixes:

- Adds new ``examples/`` and ``tools/`` directories to the library repository,
which contain code snippets and scripts that may prove useful when writing
or debugging applications. These directories are intended to
Expand Down
6 changes: 3 additions & 3 deletions source/write/gridfs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -237,10 +237,10 @@ the returned cursor and display the contents of the files uploaded in the
:visible: false

{ "_id" : { "$oid" : "..." }, "chunkSize" : 261120, "filename" : "my_file",
"length" : 13, "uploadDate" : { ... }, "metadata" : { "contentType" : "text/plain" },
"md5" : "6b24249b03ea3dd176c5a04f037a658c" }
"length" : 13, "uploadDate" : { ... }, "metadata" : {
"contentType" : "text/plain" } }
{ "_id" : { "$oid" : "..." }, "chunkSize" : 261120, "filename" : "new_file",
"length" : 13, "uploadDate" : { ... }, "md5" : "6b24249b03ea3dd176c5a04f037a658c" }
"length" : 13, "uploadDate" : { ... } }

The ``find()`` method accepts various query specifications. You can use its
``$options`` parameter to specify the sort order, maximum number of documents to return,
Expand Down