Skip to content

Commit 76ddb34

Browse files
authored
docs(pubsub): add docs comment to MaxOutstandingBytes (googleapis#12601)
* docs(pubsub): add docs comment to MaxOutstandingBytes * fix grammar
1 parent 5831d99 commit 76ddb34

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

pubsub/subscription.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -926,6 +926,8 @@ type ReceiveSettings struct {
926926
// be treated as if it were DefaultReceiveSettings.MaxOutstandingBytes. If
927927
// the value is negative, then there will be no limit on the number of bytes
928928
// for unprocessed messages.
929+
// This defaults to 1e9 or 1 GB. For machines that have less memory available,
930+
// it is recommended to decrease this value so as to not run into OOM issues.
929931
MaxOutstandingBytes int
930932

931933
// UseLegacyFlowControl disables enforcing flow control settings at the Cloud

pubsub/v2/subscriber.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,8 @@ type ReceiveSettings struct {
133133
// be treated as if it were DefaultReceiveSettings.MaxOutstandingBytes. If
134134
// the value is negative, then there will be no limit on the number of bytes
135135
// for unprocessed messages.
136+
// This defaults to 1e9 or 1 GB. For machines that have less memory available,
137+
// it is recommended to decrease this value so as to not run into OOM issues.
136138
MaxOutstandingBytes int
137139

138140
// NumGoroutines sets the number of StreamingPull streams to pull messages

0 commit comments

Comments
 (0)