Skip to content

Commit 40b027a

Browse files
committed
updated keys of the limits map
1 parent 37e52a8 commit 40b027a

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

lib/mongo.ex

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -654,11 +654,13 @@ defmodule Mongo do
654654
Mongo.limits(top)
655655
656656
{:ok, %{
657+
compression: nil,
657658
logical_session_timeout: 30,
658659
max_bson_object_size: 16777216,
659660
max_message_size_bytes: 48000000,
660661
max_wire_version: 8,
661-
max_write_batch_size: 100000
662+
max_write_batch_size: 100000,
663+
read_only: false
662664
}}
663665
"""
664666
@spec limits(pid) :: {:ok, BSON.document} | {:error, Mongo.Error.t}

lib/mongo/topology.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ defmodule Mongo.Topology do
1212
alias Mongo.Session.SessionPool
1313
alias Mongo.Session
1414

15-
@limits [:logical_session_timeout, :max_bson_object_size, :max_message_size_bytes, :max_wire_version, :max_write_batch_size]
15+
@limits [:compression, :logical_session_timeout, :max_bson_object_size, :max_message_size_bytes, :max_wire_version, :max_write_batch_size, :read_only]
1616

1717
# https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#heartbeatfrequencyms-defaults-to-10-seconds-or-60-seconds
1818
@heartbeat_frequency_ms 10_000

0 commit comments

Comments
 (0)