TsgcHTTP2Client › Olaylar › OnHTTP2RSTStream
Sunucu belirli bir HTTP/2 stream'ini sıfırladığında tetiklenir.
property OnHTTP2RSTStream: TsgcHTTP2ClientRSTStreamEvent;
// TsgcHTTP2ClientRSTStreamEvent = procedure(Sender: TObject; const Connection: TsgcHTTP2ConnectionClient; const RSTStream: TsgcHTTP2RSTStreamProperty) of object
—
OnHTTP2RSTStream, sunucu altta yatan bağlantıyı açık tutarken tek bir stream'i iptal etmek için bir RST_STREAM çerçevesi gönderdiğinde tetiklenir; örneğin bir istek reddedildiğinde, gönderilen bir kaynağa artık ihtiyaç duyulmadığında veya sunucu tarafı zaman aşımı dolduğunda. RSTStream parametresi, uygulamanın nedeni günlüğe kaydedebilmesi ve gerekirse isteği yeni bir stream'de yeniden deneyebilmesi için HTTP/2 ErrorCode'unu ve ErrorDescription'ını sunar. Aynı Connection'daki devam eden diğer stream'ler etkilenmez ve veri almaya devam eder.
procedure OnHTTP2RSTStreamEvent(Sender: TObject; const Connection: TsgcHTTP2ConnectionClient;
const RSTStream: TsgcHTTP2RSTStreamProperty);
begin
Log(Format('Stream reset: %d - %s',
[RSTStream.ErrorCode, RSTStream.ErrorDescription]));
end;