-
@Internal() public final class InternalCronetChannelBuilder
Internal CronetChannelBuilder accessor. This is intended for usage internal to the gRPC team. If you *really* think you need to use this, contact the gRPC team first.
-
-
Method Summary
Modifier and Type Method Description static void
setTrafficStatsTag(CronetChannelBuilder builder, int tag)
Sets android.net.TrafficStats tag to use when accounting socket traffic caused by thischannel. static void
setTrafficStatsUid(CronetChannelBuilder builder, int uid)
Sets specific UID to use when accounting socket traffic caused by this channel. -
-
Method Detail
-
setTrafficStatsTag
static void setTrafficStatsTag(CronetChannelBuilder builder, int tag)
Sets android.net.TrafficStats tag to use when accounting socket traffic caused by thischannel. See android.net.TrafficStats for more information. If no tag is set (e.g. thismethod isn't called), then Android accounts for the socket traffic caused by this channel as ifthe tag value were set to 0.
NOTE:Setting a tag disallows sharing of sockets with channels with other tags, whichmay adversely effect performance by prohibiting connection sharing. In other words use ofmultiplexed sockets (e.g. HTTP/2 and QUIC) will only be allowed if all channels have the samesocket tag.
-
setTrafficStatsUid
static void setTrafficStatsUid(CronetChannelBuilder builder, int uid)
Sets specific UID to use when accounting socket traffic caused by this channel. See for more information. Designed for use when performing an operationon behalf of another application. Caller must hold permission. By default traffic isattributed to UID of caller.
NOTE:Setting a UID disallows sharing of sockets with channels with other UIDs, whichmay adversely effect performance by prohibiting connection sharing. In other words use ofmultiplexed sockets (e.g. HTTP/2 and QUIC) will only be allowed if all channels have the sameUID set.
-
-
-
-