摘要: nginx中对POST数据的读取是异步进行的,也就是说你不必在content handler中等待数据读完然后返回。对客户端的响应是通过:ngx_http_send_header(r); ngx_http_output_filter(r,&out);两个调用完成,content handler的return并不意味着请求处理的完成。既然是异步调用,而且caller可以立即返回,那就意味着需要定义一个回调函数:typedef void (*ngx_http_client_body_handler_pt)(ngx_http_request_t *r)真正进行数据读取的是这个函数ngx_ht 阅读全文
posted @ 2012-09-07 17:21 donj 阅读(6681) 评论(1) 推荐(0) 编辑