-
Hi all. I have a custom plugin to store the response body on Redis and in some use cases I get an error decoding the information stored on Redis with this error: bad argument #1 to '?' (string expected, got nil) So when I get the response body with PDK I encode that on redis
but when I fetch the data from redis with
after further validation and test I can reproduce when the data as invalid json, but my point is why using kong.response.get_raw_body() I get invalid json. thanks |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hi @flowdopip, seems |
Beta Was this translation helpful? Give feedback.
I guess we should know what the raw body is when the problem occurs. Or adding some debug log or using some package capture tools to log the network flow. From current info, we could not detect whether the problem occurs inside Kong or Kong receives the invalid data.