1. <strong id="7actg"></strong>
    2. <table id="7actg"></table>

    3. <address id="7actg"></address>
      <address id="7actg"></address>
      1. <object id="7actg"><tt id="7actg"></tt></object>

        fasterRPCRPC調(diào)用框架

        聯(lián)合創(chuàng)作 · 2023-09-23 12:53

        基于java AIO實現(xiàn)的RPC調(diào)用框架,封裝完全屏蔽IO通信層,使用者就像調(diào)用本地API一樣調(diào)用RPC接口

        服務(wù)端初始化

        public static void main(String[] args) throws Exception {
                new FastRpcServer()
                        .threadSize(20)
                        .register("test", new TestService())
                        .bind(4567)
                        .start();
            }

        客戶端初始化

        public static void main(String[] args) {
                try(IClient client = new FastRpcClient()) {
                    client.connect(new InetSocketAddress("127.0.0.1", 4567));
                    ITestService service = client.getService("test", ITestService.class);
                    String say = service.say("Hello!");
                    System.out.println(say);
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        瀏覽 19
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        評論
        圖片
        表情
        推薦
        點贊
        評論
        收藏
        分享

        手機掃一掃分享

        編輯 分享
        舉報
        1. <strong id="7actg"></strong>
        2. <table id="7actg"></table>

        3. <address id="7actg"></address>
          <address id="7actg"></address>
          1. <object id="7actg"><tt id="7actg"></tt></object>
            久久久久夜 | 放荡艳妇的疯狂呻吟猎艳都市小说 | 楪可怜Av一区二区三区 | 解开英语老师丰满的乳罩视频 | 久草久| 少妇性色婬片AAA直播 | 成人aaa毛片免费视频网站 | 欧美熟妇操逼 | 自拍 第一页 | 草草视频免费观看 |