proxy-wasm-cpp-sdk icon indicating copy to clipboard operation
proxy-wasm-cpp-sdk copied to clipboard

Can Call onRequestTrailers() and onResponseTrailers unconditionally???

Open coolg92003 opened this issue 2 years ago • 1 comments

Hi Expert, If there is no Trailer in Request/Response, then I have no chance to add Trailer when after processing Request/Response. Is it possible call those two API onRequestTrailers() and onResponseTrailers unconditionally? if there is Not anything to do, then it can return Continue directly.

thanks Cliff

coolg92003 avatar Dec 05 '22 05:12 coolg92003

You can add trailers from the request/response body callbacks (e.g. upon receiving end_of_stream=True, which implies that there are no trailers).

PiotrSikora avatar Dec 05 '22 16:12 PiotrSikora