tulir / tgfilestream

A Telegram bot that can stream Telegram files to users over HTTP.
GNU Affero General Public License v3.0
200 stars 726 forks source link

How to add connection limit per link #4

Open FelinaHD opened 4 years ago

FelinaHD commented 4 years ago

Hi, i need to add connection limit per each link, can i do this with TGFileStream? (also connection limit per IP doesn't work for me btw, I can download with 32 connections even if I set limitations)

pseudokawaii commented 4 years ago

@FelinaHD The 32 connections you're using are the connections between your device and your hosting server, not the connection between your hosting server and Telegram.

What i mean is, The CONNECTION_LIMIT env variable is for limiting the number of connections your hosting server will use to connect to Telegram servers. If you are talking about the REQUEST_LIMIT var, it simply means the maximum amount of files the host server can download at the same time.