TsgcWebSocketServer_HTTPAPIEigenschappen › MaxBandwidth

MaxBandwidth Eigenschap

Maximale toegestane bandbreedte in bytes per seconde over alle verbindingen heen (nul betekent onbeperkt).

Syntaxis

property MaxBandwidth: Integer read FMaxBandwidth write FMaxBandwidth;

Standaardwaarde

0 (onbeperkt)

Opmerkingen

Caps the aggregate send rate in bytes per second; de waarde is applied at the URL-group level through the http.sys HttpServerBindingProperty / HttpServerQosProperty settings and enforced by the kernel driver. A value of 0 (de standaardwaarde) disables the limit. Useful to beperken a server that shares bandbreedte with andere services or to cap egress costs on cloud deployments. Note: the cap applies to uitgaand traffic only — ingress is not limited by deze eigenschap. Combine with RateLimiter for finer per-peer control.

Voorbeeld


oServer := TsgcWebSocketServer_HTTPAPI.Create(nil);
oServer.Host := '127.0.0.1';
oServer.Port := 80;
// cap total egress at 1 MB/sec
oServer.MaxBandwidth := 1048576;
oServer.Active := true;

Terug naar eigenschappen