TsgcHTTP2Client › 方法 › TraceAsync
发送非阻塞 HTTP/2 TRACE 请求;回显的载荷将通过 OnHTTP2Response 到达。
procedure TraceAsync(const aURL: string);
| 名称 | 类型 | 描述 |
|---|---|---|
aURL | const string | 目标的绝对 URL。到达源服务器(经过任何代理后)的请求头将被回显。 |
Trace 的非阻塞变体。适用于向不同端点同时触发多个 TRACE 探测而不阻塞调用方;每个回复通过 OnHTTP2Response 呈现。请注意,出于安全原因,许多服务器会拒绝 TRACE。
oClient.OnHTTP2Response := OnHTTP2ResponseEvent;
oClient.TraceAsync('https://api.example.com/diag');