libhv icon indicating copy to clipboard operation
libhv copied to clipboard

🔥 比libevent/libuv/asio更易用的网络库。A c/c++ network library for developing TCP/UDP/SSL/HTTP/WebSocket/MQTT client/server.

Results 126 libhv issues
Sort by recently updated
recently updated
newest added

accept连接频繁的时候这个惊群现象性能影响挺明显的,有什么好的改善方案吗?

满足一些需要对HttpServer通讯层socket套接字hio做一些业务处理操作或计数器类需求。

windows: ``` PS E:\Codes\cpp\libhvN\build\bin\Debug> ./ping 2400:3200::1 64 bytes from 2400:3200::1: icmp_seq=1 time=43.1 ms 64 bytes from 2400:3200::1: icmp_seq=2 time=43.1 ms 64 bytes from 2400:3200::1: icmp_seq=3 time=43.0 ms 64 bytes from...

![Image](https://github.com/user-attachments/assets/bfa3f2ee-a38a-4a63-91f7-f2dc82e2ea4a) ![Image](https://github.com/user-attachments/assets/8c7fe28d-da4c-4bb1-bca3-f7510939ce8d)

mqtt和tcp网络重连时都会调用hio_create_socket创建Io,但是当网络异常或者网卡还未准备好时又或是网络本来是正常的突然没网情况时,hio_create_socket函数由于无法进行域名解析导致hio_create_socket直接返回为NULL,而重连定时器运行的前提是socket要正常创建,进而导致重连无法实现。现在要解决问题就很麻烦,希望libhv能解决这个问题就好了,这样就无脑使用就行。 ![2ed7bd19051ea39b37fd4d2a539a71a4](https://github.com/user-attachments/assets/ae34f3c1-41ed-41f9-b0f5-3b198600a29d) ![image](https://github.com/user-attachments/assets/1e1d7dfe-58c2-49ce-83d1-80565acf5e2f) ![2f8d46573d8b591ec4c9588012d4ae11](https://github.com/user-attachments/assets/b092d942-9e86-43c4-9ea9-1077d9d32792) ![image](https://github.com/user-attachments/assets/102f0a97-a6d4-4ab7-a16a-dfc9257c57d8)

`hconfig.h`是自动生成的文件,并且已配置为忽略,应当删除原始文件,使配置生效。 https://github.com/ithewei/libhv/blob/fded2ba287199d3c20c619e06ddc571e2972ed92/.gitignore#L65 因为这个文件构建时会自动生成,让 git submodule 产生意外变更,造成一些不便。

add homebrew formula now ``` brew install cxwx/cxbrew/libhv ``` but it need the `test` part for merge to homebrew-core like ``` test do (testpath/"test.c").write

``` http_client_send_async(req, [=](const HttpResponsePtr &resp) { if (resp != nullptr) { resp->body; //body="" resp->status_code; // status_code=200 } else { } } ``` 有没有人遇到这种情况,发生这种情况时服务端并未收到这条请求,但是libhv确实返回了200以及空body

Please provide a link to a websocket client example that includes server authentication, and if there's another example that show how to do client authentication too. Thanks

复现方法: 运行hv样例中的httpd, 然后使用Chrome浏览器访问https://127.0.0.1:8443/downloads/libhv-vs-nginx.png, f12调试工具报错"net::ERR_HTTP2_FRAME_SIZE_ERROR". hv版本: v1.3.3 CMake参数: -DWITH_OPENSSL=ON -DWITH_NGHTTP2=ON 系统: Ubuntu 24.04