Giter Club home page Giter Club logo

grpc_sample's Introduction

GRPC sample project

  • protocol buffers 사용
  • 단순 string api를 rest api vs protobuf api 비교

위 프로젝트에서는 https://github.com/LogNet/grpc-spring-boot-starter 를 활용하게 되었습니다. 하지만, armeria를 도입하는 것이 유지보수 측면에서 좀 더 좋은 방법이라고 생각 합니다.

grpc support framework

https://www.reddit.com/r/SpringBoot/comments/1255u5x/spring_boot_and_grpc/

  • 특별히 spring boot3를 쓰지 않는 한, 둘 중에 뭘 쓰거나 상관 없어 보인다.
  • lognet 구현체가 좀 더 구성이 잘 되어 있다.
    • spring boot 지원 버전이 더 최신성을 잘 반영 함.
    • native spring은 지원이 잘 안되는 것 같다. (issue의 버그 제기 있는 상태)
  • 다른 모듈 support 은 yidongnan 모듈이 좀 더 잘 지원한다.
    • https://yidongnan.github.io/grpc-spring-boot-starter/en/versions.html
      • 2.15.0 버전은 spring boot 2.7.5 버전/spring cloud 2021.0.5버전을 지원 예정
      • 2.14.0 버전은 spring boot 2.6.13/spring cloud 2021.0.5버전 지원
    • 문제점은 spring boot 기반 start의 모듈은 official 모듈이 없고, 3th-party 모듈이 유지보수한다.
      • 과연 써도 될까?
    • armeria를 도입 하는 것이 좋은 장점이 될 수 있음.
      • HTTP/GRPC 둘다 서비스 가능
      • RPC docs 지원
      • Spring과 integration support 가능
        • armeria + spring 두개를 띄워서 서비스 가능하여, 별도 migration의 노고가 줄어든다.

구조

  • server api <---- api call ----- client api <----- http client / grpc client (ex. postman)
  • local https 활성화 필요

사용 버전

  • buildSrc/src/main/kotlin/Versions.kt 참조

https tool

protobuf docs

protobuf docs

grpc docs

sample api test 구조도

sample

grpc_sample's People

Contributors

seungdols avatar

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.