1 Star 0 Fork 0

LYSMAYUN / rest_rpc

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README

english wiki

在此特别感谢社区的朋友刘丹将rest_rpc的中文说明翻译为英文。

#chinese wiki

##Contributer

江南(qicosmos)IndignantAngel

##Contact us qicosmos@163.com


rest_rpc v0.91 release note

新增特性

1.业务函数的参数可以有connection_ptr,也可以没有,取决于你的需要,使用更灵活。

server.register_handler("add_with_conn", []
    (timax::rpc::connection_ptr conn, int a, int b)
{
    auto result = a + b;
    if (result < 1)
        conn->close();
    return result;
});

2.客户端添加private接口,拥有更高的权限和更多的流程控制

3.server端的pub提供了一个纯转发的重载实现

4.提供管理多个endpoint的工具

auto endpoints = timax::rpc::get_tcp_endpoints("127.0.0.1:5001|127.0.0.1:5002");
for(auto const& endpoint : endpoints)
{
    std::cout << endpoint << std::endl;
}

5.客户端pub接口的,将会把转发协议的name当做topic,广播给所有监听这个topic的客户端,而不需要再服务器上注册handler;

6.服务器注册handler,将使用hash值代替字符串

Bug修复

  1. rpc超时后异步调用链断开
  2. 客户端和服务器read大块消息时,因使用boost::bind,而发生了意外地拷贝,招致读取到不正确的地址
  3. 支持更低版本的编译器

空文件

简介

rest_rpc官网的源码 展开 收起
C++ 等 2 种语言
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
C++
1
https://gitee.com/lysmayun1600/rest_rpc.git
git@gitee.com:lysmayun1600/rest_rpc.git
lysmayun1600
rest_rpc
rest_rpc
master

搜索帮助