io.netty.handler.traffic.GlobalTrafficShapingHandler will handle traffic shaping.
| Modifier and Type | Field and Description |
|---|---|
| private long | |
| private TimeUnit | |
| public static final long | DEFAULT_CHECK_INTERVAL
Default check interval for stats = 1 second. |
| public static final long | DEFAULT_INBOUND_GLOBAL_BANDWIDTH_LIMIT
Default inbound bandwidth limit in bytes/sec = 0 (0 implies unthrottled) |
| public static final long | DEFAULT_MAX_TIME
Default max delay to wait = 15 seconds. |
| public static final long | DEFAULT_OUTBOUND_GLOBAL_BANDWIDTH_LIMIT
Default outbound bandwidth limit in bytes/sec = 0 (0 implies unthrottled) |
| public static final long | DEFAULT_PEAK_OUTBOUND_GLOBAL_BANDWIDTH
Default peak outbound bandwidth limit in bytes/sec = 400 Mbps (aligns with netty's default in
|
| private long | |
| private long | |
| private TimeUnit | |
| private long | |
| private long |
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public | TrafficShapingOptions(JsonObject json)
References Deprecated
JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.
|
| Modifier and Type | Method and Description |
|---|---|
| public boolean | equals(Object
the reference object with which to compare. obj)Overrides java. Indicates whether some other object is "equal to" this one. |
| public long | |
| public TimeUnit | |
| public long | |
| public long | |
| public TimeUnit | |
| public long | |
| public long | |
| public int | |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlydelay between two computations of performances checkIntervalForStats)Set the delay between two computations of performances for channels |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlycheck interval for stats time unit checkIntervalForStatsTimeUnit)Set time unit for check interval for stats. |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlybandwidth limit inboundGlobalBandwidth)Set bandwidth limit in bytes per second for inbound connections |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlymaximum delay time for waiting maxDelayToWaitTime)Set the maximum delay to wait in case of traffic excess |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlymaximum delay time's unit maxDelayToWaitTimeUnit)Set the maximum delay to wait time unit |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlybandwidth limit outboundGlobalBandwidth)Set bandwidth limit in bytes per second for outbound connections |
| public TrafficShapingOptions | Returns: a reference to this, so the API can be used fluentlypeak outbound bandwidth peakOutboundGlobalBandwidth)Set the maximum global write size in bytes per second allowed in the buffer globally for all channels before write suspended is set. |
| public JsonObject | toJson()
References Deprecated
JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.
|
| checkIntervalForStats | back to summary |
|---|---|
| private long checkIntervalForStats | |
| checkIntervalForStatsTimeUnit | back to summary |
|---|---|
| private TimeUnit checkIntervalForStatsTimeUnit | |
| DEFAULT_CHECK_INTERVAL | back to summary |
|---|---|
| public static final long DEFAULT_CHECK_INTERVAL Default check interval for stats = 1 second. The units are in milliseconds. (Aligns with netty's
default in | |
| DEFAULT_INBOUND_GLOBAL_BANDWIDTH_LIMIT | back to summary |
|---|---|
| public static final long DEFAULT_INBOUND_GLOBAL_BANDWIDTH_LIMIT Default inbound bandwidth limit in bytes/sec = 0 (0 implies unthrottled) | |
| DEFAULT_MAX_TIME | back to summary |
|---|---|
| public static final long DEFAULT_MAX_TIME Default max delay to wait = 15 seconds. The units are in milliseconds. (Aligns with netty's
default in | |
| DEFAULT_OUTBOUND_GLOBAL_BANDWIDTH_LIMIT | back to summary |
|---|---|
| public static final long DEFAULT_OUTBOUND_GLOBAL_BANDWIDTH_LIMIT Default outbound bandwidth limit in bytes/sec = 0 (0 implies unthrottled) | |
| DEFAULT_PEAK_OUTBOUND_GLOBAL_BANDWIDTH | back to summary |
|---|---|
| public static final long DEFAULT_PEAK_OUTBOUND_GLOBAL_BANDWIDTH Default peak outbound bandwidth limit in bytes/sec = 400 Mbps (aligns with netty's default in
| |
| inboundGlobalBandwidth | back to summary |
|---|---|
| private long inboundGlobalBandwidth | |
| maxDelayToWait | back to summary |
|---|---|
| private long maxDelayToWait | |
| maxDelayToWaitTimeUnit | back to summary |
|---|---|
| private TimeUnit maxDelayToWaitTimeUnit | |
| outboundGlobalBandwidth | back to summary |
|---|---|
| private long outboundGlobalBandwidth | |
| peakOutboundGlobalBandwidth | back to summary |
|---|---|
| private long peakOutboundGlobalBandwidth | |
| TrafficShapingOptions | back to summary |
|---|---|
| public TrafficShapingOptions() | |
| TrafficShapingOptions | back to summary |
|---|---|
| public TrafficShapingOptions(TrafficShapingOptions other) | |
| TrafficShapingOptions | back to summary |
|---|---|
| public TrafficShapingOptions(JsonObject json)
References Deprecated
See corresponding docs for further information. | |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| getCheckIntervalForStats | back to summary |
|---|---|
public long getCheckIntervalForStats()
| |
| getCheckIntervalForStatsTimeUnit | back to summary |
|---|---|
public TimeUnit getCheckIntervalForStatsTimeUnit()
| |
| getInboundGlobalBandwidth | back to summary |
|---|---|
public long getInboundGlobalBandwidth()
| |
| getMaxDelayToWait | back to summary |
|---|---|
public long getMaxDelayToWait()
| |
| getMaxDelayToWaitTimeUnit | back to summary |
|---|---|
public TimeUnit getMaxDelayToWaitTimeUnit()
| |
| getOutboundGlobalBandwidth | back to summary |
|---|---|
public long getOutboundGlobalBandwidth()
| |
| getPeakOutboundGlobalBandwidth | back to summary |
|---|---|
public long getPeakOutboundGlobalBandwidth()
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| setCheckIntervalForStats | back to summary |
|---|---|
| public TrafficShapingOptions setCheckIntervalForStats(long checkIntervalForStats) Set the delay between two computations of performances for channels
| |
| setCheckIntervalForStatsTimeUnit | back to summary |
|---|---|
| public TrafficShapingOptions setCheckIntervalForStatsTimeUnit(TimeUnit checkIntervalForStatsTimeUnit) Set time unit for check interval for stats.
| |
| setInboundGlobalBandwidth | back to summary |
|---|---|
| public TrafficShapingOptions setInboundGlobalBandwidth(long inboundGlobalBandwidth) Set bandwidth limit in bytes per second for inbound connections
| |
| setMaxDelayToWait | back to summary |
|---|---|
| public TrafficShapingOptions setMaxDelayToWait(long maxDelayToWaitTime) Set the maximum delay to wait in case of traffic excess
| |
| setMaxDelayToWaitUnit | back to summary |
|---|---|
| public TrafficShapingOptions setMaxDelayToWaitUnit(TimeUnit maxDelayToWaitTimeUnit) Set the maximum delay to wait time unit
| |
| setOutboundGlobalBandwidth | back to summary |
|---|---|
| public TrafficShapingOptions setOutboundGlobalBandwidth(long outboundGlobalBandwidth) Set bandwidth limit in bytes per second for outbound connections
| |
| setPeakOutboundGlobalBandwidth | back to summary |
|---|---|
| public TrafficShapingOptions setPeakOutboundGlobalBandwidth(long peakOutboundGlobalBandwidth) Set the maximum global write size in bytes per second allowed in the buffer globally for all channels before write suspended is set. Default value is 400 MB
| |
| toJson | back to summary |
|---|---|
| public JsonObject toJson()
References Deprecated
See corresponding docs for further information. | |