OnDownStreamData is called for whatever tcp data is available rather than the entire body. Please check the API doc beforehand and you might want to see https://github.com/tetratelabs/proxy-wasm-go-sdk/tree/main/examples/http_body for how to get the entire body.
Peihu2020 opened this issue · 2 comments
Peihu2020 commented
OnDownStreamData is called for whatever tcp data is available rather than the entire body. Please check the API doc beforehand and you might want to see https://github.com/tetratelabs/proxy-wasm-go-sdk/tree/main/examples/http_body for how to get the entire body.
Originally posted by @mathetake in #379 (comment)
Peihu2020 commented
Hi Takeshi,
I haven't answered your feedback in time because I am on vacation in the past few days. Sorry, for late answer.
My question is I can't decode my request is because I am doing tcp proxy(postgresql database proxy) rather than http request. So, I believe I can't get http request body or header and I shouldn't follow up the http_body examples as well. Please correct me if my understanding is wrong.
Peihu
mathetake commented
Hey please do not spam us creating the issue title like this from next time, and your understanding is correct.