nim-chronos
nim-chronos copied to clipboard
proxy implementation in httpclient
First of all, thank you guys so much for putting effort this amazing project. I really enjoy using it and learning how to make the NIM project clean and organized. I was wondering, does the httpclient support regular http/https proxy, just like NIM std httpclient library? I went through the code and I didn't find code can realize this functionality but just want to make sure.
If not I think it should be easy to implement and I can try to do that then make PR. The only thing worries me that is you have very well defined test cases and I don't have anything on top of my head how to make a robust test case for the http proxy (mainly to find a long lifetime public proxy server).
Indeed. The way to write a test case would be to implement a small proxy server in the test case and validate through there that the client is sending the proper content (and consequently getting the right responses) - one way to get examples is to record a proxy session with wireshark for example.
That's a great idea! Thank you for the suggestion! Apparently cheatfate is the main contributor of the httpclient code. Not sure if he is already implementing this part but will start to work on this on my side anyway. : )