- 
                Notifications
    You must be signed in to change notification settings 
- Fork 2
pipe一些修改 #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: siyuan.make_ngx_resp
Are you sure you want to change the base?
pipe一些修改 #4
Conversation
6fe6055    to
    ad90694      
    Compare
  
    There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
|  | ||
| if opts.signature_cb ~= nil then | ||
| req = opts.signature_cb(req) | ||
| end | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
上面这些初始化和赋值是不是可以从for循环中拿出去
| end | ||
| end | ||
|  | ||
| if err_code ~= nil then | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里可以直接返回错误
        
          
                lib/pipe/reader.lua
              
                Outdated
          
        
      | break | ||
| end | ||
| end | ||
| function _M.loop_http_read(pobj, ident, http) | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
上面那几个函数还需要在这里保留吗?
| end | ||
| function _M.connect_http(ips, port, verb, uri, opts) | ||
| return httplib.connect_http(ips, port, verb, uri, opts) | ||
| end | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
感觉直接用httplib的更直接,reader里面也封装了一下
84058b2    to
    10966ae      
    Compare
  
    10966ae    to
    62d8779      
    Compare
  
    
1.将一些writer、reader公用的http函数移动到httplib中
2.添加make_aws_put_s3_writer
3.添加make_quorum_http_writers