Skip to content

Commit 41e3fbd

Browse files
committed
Merge remote-tracking branch 'origin/docsp-39980-gridfs' into docsp-39980-gridfs
2 parents 2cf2ba5 + ea27460 commit 41e3fbd

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

source/fundamentals/crud/write-operations/insert.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ documents to a MongoDB collection by performing insert operations.
2525

2626
.. note:: 16 MB Size Limit
2727

28-
MongoDB limits BSON documents to 16 MB. If your document is larger than 16 MB,
28+
MongoDB limits individual BSON documents to 16 MB. If your document is larger than 16 MB,
2929
use the :ref:`GridFS <csharp-gridfs>` API instead.
3030

3131
An insert operation inserts one or more documents into a MongoDB collection.

source/fundamentals/gridfs.txt

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ splits files into chunks when storing them and reassembles those files when retr
2626
The driver's implementation of GridFS is an abstraction that manages the operations and
2727
organization of the file storage.
2828

29-
Use GridFS if the size of your files exceeds the BSON document
29+
Use GridFS if the size of any of your files exceeds the BSON document
3030
size limit of 16 MB. For more detailed information about whether GridFS is
3131
suitable for your use case, see :manual:`GridFS </core/gridfs>` in the
3232
{+mdb-server+} manual.
@@ -42,7 +42,7 @@ bucket contains the following collections:
4242
- ``files``: Stores the file metadata
4343

4444
The driver creates the GridFS bucket, if it doesn't already exist, when you first
45-
write data to it. The bucket contains the preceding collections
45+
write data to it. The bucket contains the ``chunks`` and ``files`` collections
4646
prefixed with the default bucket name ``fs``, unless you specify a different
4747
name. To ensure efficient retrieval of the files and related metadata, the driver
4848
creates an index on each collection. The driver ensures that these indexes exist
@@ -91,7 +91,7 @@ Customize the Bucket
9191
~~~~~~~~~~~~~~~~~~~~
9292

9393
You can customize the GridFS bucket configuration by passing an instance
94-
of the ``GridFSBucketOptions class`` class to
94+
of the ``GridFSBucketOptions`` class to
9595
the ``GridFSBucket()`` constructor. The following table describes the properties in the
9696
``GridFSBucketOptions`` class:
9797

@@ -153,7 +153,7 @@ You can upload files to a GridFS bucket by using the following methods:
153153
- ``UploadFromStreamAsync()`` or ``UploadFromStream()``: Uploads the contents of an existing
154154
stream to a GridFS file
155155

156-
The following sections describe these methods in more detail.
156+
The following sections describe how to use these methods.
157157

158158
.. _csharp-gridfs-open-upload-stream:
159159

@@ -183,10 +183,10 @@ stream for a given file name. These methods accept the following parameters:
183183

184184
**Data type**: `CancellationToken <https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken>`__
185185

186-
The following code example demonstrates how to open an upload stream by performing the
186+
This code example demonstrates how to open an upload stream by performing the
187187
following steps:
188188

189-
- Calls the ``OpenUploadStream()`` method to open a writable GridFS stream for a new file
189+
- Calls the ``OpenUploadStream()`` method to open a writable GridFS stream for a file
190190
named ``"my_file"``
191191
- Calls the ``Write()`` method to write data to ``my_file``
192192
- Calls the ``Close()`` method to close the stream that points to ``my_file``
@@ -225,10 +225,10 @@ method. The ``GridFSUploadOptions`` class contains the following properties:
225225
* - Property
226226
- Description
227227
* - ``BatchSize``
228-
- The number of chunks to upload in each batch. The default value is ``16777216``
229-
divided by the value of the following property, ``ChunkSizeBytes``.
230-
231-
**Data type**: ``int?``
228+
- | The number of chunks to upload in each batch. The default value is ``16777216``
229+
divided by the value of the ``ChunkSizeBytes`` property.
230+
|
231+
| **Data type**: ``int?``
232232

233233
* - ``ChunkSizeBytes``
234234
- The maximum size of each chunk.
@@ -307,7 +307,7 @@ contents of a stream to a new GridFS file. These methods accept the following pa
307307

308308
**Data type**: `CancellationToken <https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken>`__
309309

310-
The following code example demonstrates how to open an upload stream by performing the
310+
This code example demonstrates how to open an upload stream by performing the
311311
following steps:
312312

313313
- Opens a file located at ``/path/to/input_file`` as a stream in binary read mode
@@ -553,7 +553,7 @@ on your ``GridFSBucket`` instance. These methods accept the following parameters
553553
The following code example shows how to retrieve and print file metadata
554554
from files in a GridFS bucket. The ``Find()`` method returns an
555555
``IAsyncCursor<GridFSFileInfo>`` instance from
556-
which you can access the results.It uses a ``foreach`` loop to iterate through
556+
which you can access the results. It uses a ``foreach`` loop to iterate through
557557
the returned cursor and display the contents of the files uploaded in the
558558
:ref:`csharp-gridfs-upload-files` examples.
559559

0 commit comments

Comments
 (0)