소스 검색

Tune buffer limits to 32kb by default

tags/v1.0.4^2
9seconds 6 년 전
부모
커밋
289e8f5945
2개의 변경된 파일4개의 추가작업 그리고 4개의 파일을 삭제
  1. 2
    2
      README.md
  2. 2
    2
      main.go

+ 2
- 2
README.md 파일 보기

@@ -194,8 +194,8 @@ supported environment variables:
194 194
 | `MTG_STATSD_PREFIX`           | `--statsd-prefix`            | `mtg`                             | Which bucket prefix we should use. For example, if you set `mtg`, then metric `traffic.ingress` would be send as `mtg.traffic.ingress`.                                                                                                                                         |
195 195
 | `MTG_STATSD_TAGS_FORMAT`      | `--statsd-tags-format`       |                                   | Which tags format we should use. By default, we are using default vanilla statsd tags format but if you want to send directly to InfluxDB or Datadog, please specify it there. Possible options are `influxdb` and `datadog`.                                                   |
196 196
 | `MTG_STATSD_TAGS`             | `--statsd-tags`              |                                   | Which tags should we send to statsd with our metrics. Please specify them as `key=value` pairs.                                                                                                                                                                                 |
197
-| `MTG_BUFFER_WRITE`            | `-w`, `--write-buffer`       | `24KB`                            | The size of TCP write buffer in bytes. Write buffer is the buffer for messages which are going from client to Telegram.                                                                                                                                                         |
198
-| `MTG_BUFFER_READ`             | `-r`, `--read-buffer`        | `24KB`                            | The size of TCP read buffer in bytes. Read buffer is the buffer for messages from Telegram to client.                                                                                                                                                                           |
197
+| `MTG_BUFFER_WRITE`            | `-w`, `--write-buffer`       | `32KB`                            | The size of TCP write buffer in bytes. Write buffer is the buffer for messages which are going from client to Telegram.                                                                                                                                                         |
198
+| `MTG_BUFFER_READ`             | `-r`, `--read-buffer`        | `32KB`                            | The size of TCP read buffer in bytes. Read buffer is the buffer for messages from Telegram to client.                                                                                                                                                                           |
199 199
 | `MTG_ANTIREPLAY_MAXSIZE`      | `--anti-replay-max-size`     | `128MB`                           | Max size of antireplay cache.                                                                                                                                                                                                                                                   |
200 200
 | `MTG_CLOAK_PORT`              | `--cloak-port`               | `443`                             | Which port we should use to connect to cloaked host in FakeTLS mode.                                                                                                                                                                                                            |
201 201
 | `MTG_MULTIPLEX_PERCONNECTION` | `--multiplex-per-connection` | `50`                              | How many client connections can share a single Telegram connection in adtag mode                                                                                                                                                                                                |

+ 2
- 2
main.go 파일 보기

@@ -92,13 +92,13 @@ var (
92 92
 		"Write buffer size. You can think about it as a buffer from client to Telegram.").
93 93
 		Short('w').
94 94
 		Envar("MTG_BUFFER_WRITE").
95
-		Default("24KB").
95
+		Default("32KB").
96 96
 		Bytes()
97 97
 	runReadBufferSize = runCommand.Flag("read-buffer",
98 98
 		"Read buffer size. You can think about it as a buffer from Telegram to client.").
99 99
 		Short('r').
100 100
 		Envar("MTG_BUFFER_READ").
101
-		Default("24KB").
101
+		Default("32KB").
102 102
 		Bytes()
103 103
 	runTLSCloakPort = runCommand.Flag("cloak-port",
104 104
 		"Port which should be used for host cloaking.").

Loading…
취소
저장