wklken opened a new issue, #10617:
URL: https://github.com/apache/apisix/issues/10617

   ### Description
   
   the `error.log`
   
   ```
   2023/12/08 04:03:02 [error] 92#92: *31499039 upstream prematurely closed 
connection while reading response header from upstream ...
   ```
   
   the response body
   
   ```
   <html>
   <head><title>502 Bad Gateway</title></head>
   <body>
   <center><h1>502 Bad Gateway</h1></center>
   <hr><center>openresty</center>
   <p><em>Powered by <a 
href="https://apisix.apache.org/";>APISIX</a>.</em></p></body>
   </html>
    while sending to client
   ```
   
   I want to write a plugin to  wrap the 502, and put the error message 
`upstream prematurely closed connection while reading response header from 
upstream` into the response body
   
   is there any way to retrieve the error message of nginx from lua? 
   
   
   ### Environment
   
   - APISIX version (run `apisix version`): 3.2.1
   - Operating system (run `uname -a`):
   - OpenResty / Nginx version (run `openresty -V` or `nginx -V`):
   - etcd version, if relevant (run `curl 
http://127.0.0.1:9090/v1/server_info`):
   - APISIX Dashboard version, if relevant:
   - Plugin runner version, for issues related to plugin runners:
   - LuaRocks version, for installation issues (run `luarocks --version`):
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to