File tree Expand file tree Collapse file tree 1 file changed +4
-0
lines changed
google-cloud-pubsub/src/main/java/com/google/cloud/pubsub/v1 Expand file tree Collapse file tree 1 file changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,9 @@ public class Subscriber extends AbstractApiService implements SubscriberInterfac
9393 private static final int MAX_INBOUND_MESSAGE_SIZE =
9494 20 * 1024 * 1024 ; // 20MB API maximum message size.
9595
96+ private static final int MAX_INBOUND_METADATA_SIZE =
97+ 4 * 1024 * 1024 ; // 4MB API maximum metadata size
98+
9699 @ InternalApi static final Duration DEFAULT_MAX_ACK_EXTENSION_PERIOD = Duration .ofMinutes (60 );
97100
98101 @ InternalApi
@@ -480,6 +483,7 @@ public static final class Builder {
480483 private TransportChannelProvider channelProvider =
481484 SubscriptionAdminSettings .defaultGrpcTransportProviderBuilder ()
482485 .setMaxInboundMessageSize (MAX_INBOUND_MESSAGE_SIZE )
486+ .setMaxInboundMetadataSize (MAX_INBOUND_METADATA_SIZE )
483487 .setKeepAliveTime (Duration .ofMinutes (5 ))
484488 .build ();
485489 private HeaderProvider headerProvider = new NoHeaderProvider ();
You can’t perform that action at this time.
0 commit comments