事件:'wantTrailers'
【Event: 'wantTrailers'】
'wantTrailers' 事件在 Http2Stream 已将最终的 DATA 帧排队准备发送,并且 Http2Stream 已准备好发送尾随头时触发。在发起请求或响应时,必须将 waitForTrailers 选项设置为该事件才能被触发。
【The 'wantTrailers' event is emitted when the Http2Stream has queued the
final DATA frame to be sent on a frame and the Http2Stream is ready to send
trailing headers. When initiating a request or response, the waitForTrailers
option must be set for this event to be emitted.】