rest_rpc icon indicating copy to clipboard operation
rest_rpc copied to clipboard

modern C++(C++11), simple, easy to use rpc framework

Results 79 rest_rpc issues
Sort by recently updated
recently updated
newest added

祁工: 嵌入式设备内存不大,所以特别关注内存消耗,还是以自带person为例,如果name的大小是10M,那么在服务端调用处理函数的时候,会瞬时消耗40M内存,原因是unpack调用msgpack::unpack时使用的默认参数,object_handle对str类型数据是复制不是引用,我看现在的流程,buffer的生命周期是大于object_handle的,能不能使用下边的接口,让unpack_reference_func固定返回true,强制使用引用模式,这样消耗的内存就是20M了。我测试了下,没有发现问题。 void unpack( object_handle& result, const char* data, std::size_t len, unpack_reference_func f = nullptr, void* user_data = nullptr, unpack_limit const& limit = unpack_limit());

祁工: 我看下了订阅发布模式的实现方式,如果发布者发布速度远大于消费者,数据会缓存在链接里的数据队列write_queue_,时间久了会把内存耗光的吧,能增加每个链接发送缓存队列的最大值限制么?

在通信过程中,想要使用一个自定义类型的数组,请问如何支持。除了vector也可以使用指针类型。

terminate called after throwing an instance of 'std::future_error' what(): std::future_error: Broken promise 求大佬指点下。

你好!现有java似乎只支持异步调用,可否增加同步调用功能?还有请问java只支持jdk8以上,请问1.6可否有办法使用? 谢谢!

- add a function to get the size of the send queue. - add the maximum size parameter of the send queue, limit the length of the send queue, and...

void test_sub1() { rpc_client client; client.enable_auto_reconnect(); client.enable_auto_heartbeat(); bool r = client.connect("127.0.0.1", 9000); if (!r) { return; } client.subscribe( "key", "048a796c8a3c6a6b7bd1223bf2c8cee05232e927b521984ba417cb2fca6df9d1", [](string_view data) { msgpack_codec codec; person p = codec.unpack(data.data(), data.size());...

开发环境. centos 7 && gcc 8.3 操作步骤 1. 启动basic_server 2. 启动basic_client 等待3-5秒 ctrl+c关闭client. 重复这个操作 正常是2次 出现. ![rest_rpc](https://user-images.githubusercontent.com/10229072/149745187-2c2443ed-f6bc-496e-bb00-0c1dd3ef4bfb.png)

在ubuntu16.04的环境中使用cmake编译example的程序,在编译之前安装了boost。想请教一下,是不是只需要安装boost就可以了。但是在example 下执行cmake 出现了如下的错误: -- The C compiler identification is GNU 5.4.0 -- The CXX compiler identification is GNU 5.4.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI...