mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-04-30 09:18:34 +00:00
SplitHTTP: Rename three options & Reduce server defaults (#3611)
* maxUploadSize -> scMaxEachPostBytes, default is 1MB on both sides (was 2MB on the server) * minUploadIntervalMs -> scMinPostsIntervalMs, default is 30ms on the client (no server support for now) * maxConcurrentUploads -> scMaxConcurrentPosts, default is 100 on both sides (was 200 on the server)
This commit is contained in:
parent
33daa0c94b
commit
30af792777
6 changed files with 85 additions and 99 deletions
|
@ -229,9 +229,9 @@ type SplitHTTPConfig struct {
|
|||
Host string `json:"host"`
|
||||
Path string `json:"path"`
|
||||
Headers map[string]string `json:"headers"`
|
||||
MaxConcurrentUploads Int32Range `json:"maxConcurrentUploads"`
|
||||
MaxUploadSize Int32Range `json:"maxUploadSize"`
|
||||
MinUploadIntervalMs Int32Range `json:"minUploadIntervalMs"`
|
||||
ScMaxConcurrentPosts Int32Range `json:"scMaxConcurrentPosts"`
|
||||
ScMaxEachPostBytes Int32Range `json:"scMaxEachPostBytes"`
|
||||
ScMinPostsIntervalMs Int32Range `json:"scMinPostsIntervalMs"`
|
||||
NoSSEHeader bool `json:"noSSEHeader"`
|
||||
}
|
||||
|
||||
|
@ -249,17 +249,17 @@ func (c *SplitHTTPConfig) Build() (proto.Message, error) {
|
|||
Path: c.Path,
|
||||
Host: c.Host,
|
||||
Header: c.Headers,
|
||||
MaxConcurrentUploads: &splithttp.RandRangeConfig{
|
||||
From: c.MaxConcurrentUploads.From,
|
||||
To: c.MaxConcurrentUploads.To,
|
||||
ScMaxConcurrentPosts: &splithttp.RandRangeConfig{
|
||||
From: c.ScMaxConcurrentPosts.From,
|
||||
To: c.ScMaxConcurrentPosts.To,
|
||||
},
|
||||
MaxUploadSize: &splithttp.RandRangeConfig{
|
||||
From: c.MaxUploadSize.From,
|
||||
To: c.MaxUploadSize.To,
|
||||
ScMaxEachPostBytes: &splithttp.RandRangeConfig{
|
||||
From: c.ScMaxEachPostBytes.From,
|
||||
To: c.ScMaxEachPostBytes.To,
|
||||
},
|
||||
MinUploadIntervalMs: &splithttp.RandRangeConfig{
|
||||
From: c.MinUploadIntervalMs.From,
|
||||
To: c.MinUploadIntervalMs.To,
|
||||
ScMinPostsIntervalMs: &splithttp.RandRangeConfig{
|
||||
From: c.ScMinPostsIntervalMs.From,
|
||||
To: c.ScMinPostsIntervalMs.To,
|
||||
},
|
||||
NoSSEHeader: c.NoSSEHeader,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue