-
Notifications
You must be signed in to change notification settings - Fork 26.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
28 changed files
with
696 additions
and
484 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
250 changes: 250 additions & 0 deletions
250
dubbo-common/src/main/java/org/apache/dubbo/config/nested/Http3Config.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,250 @@ | ||
/* | ||
* Licensed to the Apache Software Foundation (ASF) under one or more | ||
* contributor license agreements. See the NOTICE file distributed with | ||
* this work for additional information regarding copyright ownership. | ||
* The ASF licenses this file to You under the Apache License, Version 2.0 | ||
* (the "License"); you may not use this file except in compliance with | ||
* the License. You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
package org.apache.dubbo.config.nested; | ||
|
||
import java.io.Serializable; | ||
|
||
public class Http3Config implements Serializable { | ||
|
||
private static final long serialVersionUID = -4443828713331129834L; | ||
|
||
/** | ||
* Enable http3 support | ||
* <p>The default value is false. | ||
*/ | ||
private Boolean enable; | ||
|
||
/** | ||
* See <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_data">set_initial_max_data</a>. | ||
* <p>The default value is 8MiB. | ||
*/ | ||
private Integer initialMaxData; | ||
|
||
/** | ||
* If configured this will enable <a href="https://tools.ietf.org/html/draft-ietf-quic-datagram-01">Datagram support.</a> | ||
*/ | ||
private Integer recvQueueLen; | ||
|
||
/** | ||
* If configured this will enable <a href="https://tools.ietf.org/html/draft-ietf-quic-datagram-01">Datagram support.</a> | ||
*/ | ||
private Integer sendQueueLen; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_stream_data_bidi_local">set_initial_max_stream_data_bidi_local</a>. | ||
* <p>The default value is 1MiB. | ||
*/ | ||
private Integer initialMaxStreamDataBidiLocal; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_stream_data_bidi_remote">set_initial_max_stream_data_bidi_remote</a>. | ||
* <p>The default value is 1MiB. | ||
*/ | ||
private Integer initialMaxStreamDataBidiRemote; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_stream_data_uni">set_initial_max_stream_data_uni</a>. | ||
* <p>The default value is 0. | ||
*/ | ||
private Integer initialMaxStreamDataUni; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_streams_bidi">set_initial_max_streams_bidi</a>. | ||
* <p>The default value is 1B(2^30). | ||
*/ | ||
private Long initialMaxStreamsBidi; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_initial_max_streams_uni">set_initial_max_streams_uni</a>. | ||
* <p> | ||
* <p>The default value is 1B(2^30). | ||
*/ | ||
private Long initialMaxStreamsUni; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_ack_delay_exponent">set_ack_delay_exponent</a>. | ||
* <p>The default value is 3. | ||
*/ | ||
private Integer maxAckDelayExponent; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_max_ack_delay">set_max_ack_delay</a>. | ||
* <p>The default value is 25 milliseconds. | ||
*/ | ||
private Integer maxAckDelay; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.set_disable_active_migration">set_disable_active_migration</a>. | ||
* <p>The default value is {@code false}. | ||
*/ | ||
private Boolean disableActiveMigration; | ||
|
||
/** | ||
* See | ||
* <a href="https://docs.rs/quiche/0.6.0/quiche/struct.Config.html#method.enable_hystart">enable_hystart</a>. | ||
* <p>The default value is {@code true}. | ||
*/ | ||
private Boolean enableHystart; | ||
|
||
/** | ||
* Sets the congestion control algorithm to use. | ||
* <p>Supported algorithms are {@code "RENO"} or {@code "CUBIC"} or {@code "BBR"}. | ||
* <p>The default value is {@code "CUBIC"}. | ||
*/ | ||
private String ccAlgorithm; | ||
|
||
public Boolean getEnable() { | ||
return enable; | ||
} | ||
|
||
public void setEnable(Boolean enable) { | ||
this.enable = enable; | ||
} | ||
|
||
public Integer getInitialMaxData() { | ||
return initialMaxData; | ||
} | ||
|
||
public void setInitialMaxData(Integer initialMaxData) { | ||
this.initialMaxData = initialMaxData; | ||
} | ||
|
||
public Integer getRecvQueueLen() { | ||
return recvQueueLen; | ||
} | ||
|
||
public void setRecvQueueLen(Integer recvQueueLen) { | ||
this.recvQueueLen = recvQueueLen; | ||
} | ||
|
||
public Integer getSendQueueLen() { | ||
return sendQueueLen; | ||
} | ||
|
||
public void setSendQueueLen(Integer sendQueueLen) { | ||
this.sendQueueLen = sendQueueLen; | ||
} | ||
|
||
public Integer getInitialMaxStreamDataBidiLocal() { | ||
return initialMaxStreamDataBidiLocal; | ||
} | ||
|
||
public void setInitialMaxStreamDataBidiLocal(Integer initialMaxStreamDataBidiLocal) { | ||
this.initialMaxStreamDataBidiLocal = initialMaxStreamDataBidiLocal; | ||
} | ||
|
||
public Integer getInitialMaxStreamDataBidiRemote() { | ||
return initialMaxStreamDataBidiRemote; | ||
} | ||
|
||
public void setInitialMaxStreamDataBidiRemote(Integer initialMaxStreamDataBidiRemote) { | ||
this.initialMaxStreamDataBidiRemote = initialMaxStreamDataBidiRemote; | ||
} | ||
|
||
public Integer getInitialMaxStreamDataUni() { | ||
return initialMaxStreamDataUni; | ||
} | ||
|
||
public void setInitialMaxStreamDataUni(Integer initialMaxStreamDataUni) { | ||
this.initialMaxStreamDataUni = initialMaxStreamDataUni; | ||
} | ||
|
||
public Long getInitialMaxStreamsBidi() { | ||
return initialMaxStreamsBidi; | ||
} | ||
|
||
public void setInitialMaxStreamsBidi(Long initialMaxStreamsBidi) { | ||
this.initialMaxStreamsBidi = initialMaxStreamsBidi; | ||
} | ||
|
||
public Long getInitialMaxStreamsUni() { | ||
return initialMaxStreamsUni; | ||
} | ||
|
||
public void setInitialMaxStreamsUni(Long initialMaxStreamsUni) { | ||
this.initialMaxStreamsUni = initialMaxStreamsUni; | ||
} | ||
|
||
public Integer getMaxAckDelayExponent() { | ||
return maxAckDelayExponent; | ||
} | ||
|
||
public void setMaxAckDelayExponent(Integer maxAckDelayExponent) { | ||
this.maxAckDelayExponent = maxAckDelayExponent; | ||
} | ||
|
||
public Integer getMaxAckDelay() { | ||
return maxAckDelay; | ||
} | ||
|
||
public void setMaxAckDelay(Integer maxAckDelay) { | ||
this.maxAckDelay = maxAckDelay; | ||
} | ||
|
||
public Boolean getDisableActiveMigration() { | ||
return disableActiveMigration; | ||
} | ||
|
||
public void setDisableActiveMigration(Boolean disableActiveMigration) { | ||
this.disableActiveMigration = disableActiveMigration; | ||
} | ||
|
||
public Boolean getEnableHystart() { | ||
return enableHystart; | ||
} | ||
|
||
public void setEnableHystart(Boolean enableHystart) { | ||
this.enableHystart = enableHystart; | ||
} | ||
|
||
public String getCcAlgorithm() { | ||
return ccAlgorithm; | ||
} | ||
|
||
public void setCcAlgorithm(String ccAlgorithm) { | ||
this.ccAlgorithm = ccAlgorithm; | ||
} | ||
|
||
public void checkDefault() { | ||
if (initialMaxData == null) { | ||
initialMaxData = 1 << 23; | ||
} | ||
if (initialMaxStreamDataBidiLocal == null) { | ||
initialMaxStreamDataBidiLocal = 1 << 20; | ||
} | ||
if (initialMaxStreamDataBidiRemote == null) { | ||
initialMaxStreamDataBidiRemote = 1 << 20; | ||
} | ||
if (initialMaxStreamDataUni == null) { | ||
initialMaxStreamDataUni = 1 << 20; | ||
} | ||
if (initialMaxStreamsBidi == null) { | ||
initialMaxStreamsBidi = (long) 1 << 30; | ||
} | ||
if (initialMaxStreamsUni == null) { | ||
initialMaxStreamsUni = (long) 1 << 30; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.