Giter VIP home page Giter VIP logo

netty-rpc-demo's Introduction

基于netty的RPC框架demo
1、使用Protostuff作为序列化和反序列化工具 --->>> com.sjz.rpc.serialize.SerializationUtil
2、LengthFieldBasedFrameDecoder解决TCP粘包/拆包问题
3、客户端基于jdk动态代理生成代理类 --->>> com.sjz.rpc.client.RpcInvoker
4、服务端基于反射执行方法调用 --->>> com.sjz.rpc.server.RpcServerHandler.doHandler()
5、通过实现Future类,实现调用结果的异步获取 --->>> com.sjz.rpc.client.RpcFuture


代码结构:
    rpc-core(工程名)
        com.sjz.rpc
               client >>> 客户端相应类
               model  >>> 自定义的实体类,用于数据传输
               registry >>> 注册中心实体类
               serialize >>> 序列化/发序列化相应类
               server >>> 服务端相应类

    rpc-api(api接口)

    rpc-provider(api接口实现类)
        test(测试)
            client ---> 客户端测试类
            server ---> 服务端测试类
    





netty-rpc-demo's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.