Rpcx-framework - An RPC microservices framework based on rpcx, simple and easy to use, ultra fast and efficient, powerful, service discovery, service governance, service layering, version control, routing label registration.

RPCX Framework

Go Report Card MIT license Build Status Foundation GoDoc Sourcegraph Release TODOs goproxy.cn

An RPC microservices framework based on rpcx.

Features: simple and easy to use, ultra fast and efficient, powerful, service discovery, service governance, service layering, version control, routing label registration.

Best microservices framework in Go, like alibaba Dubbo, but with more features, Scale easily. Try it. Test it. If you feel it's better, use it!

Java有Dubbo, Golang有RPCX!

Installation

To install rpcx-framework package, you need to install Go and set your Go workspace first.

  1. The first need Go installed (version 1.11+ is required), then you can use the below Go command to install rpcx-framework.
$ go get -u github.com/ZYallers/rpcx-framework
  1. Import it in your code:
import "github.com/ZYallers/rpcx-framework" 

Examples

The below is a simple example.

%+v; Etcd-> %+v", *s, *(s.Etcd)) s.Serve() } ">
package main

import (
	"github.com/smallnest/rpcx/log"
	framework "gitlab.sys.hxsapp.net/hxs/rpcx-framework"
)

func init() {
	framework.LoadConfig()
}

func main() {
	//share.Trace = true
	s := framework.NewService()
	log.Infof("Service-> %+v; Etcd-> %+v", *s, *(s.Etcd))
	s.Serve()
}

How to deploy and run?

Copy the boot script "script / bootstrap. Sh" to the root directory of your project, and then execute it; If successful, you will see the following information:

 current path: /Users/cloud/gopath_hxsapp/rpcx-demo 
 download produce.sh 
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  7791  100  7791    0     0    221      0  0:00:35  0:00:35 --:--:--  1904
 download produce.sh(/Users/cloud/gopath_hxsapp/rpcx-demo/./bin/produce.sh) finished 
 service config: 
 ServiceName: rpcx-demo 
 ServiceAddr: 172.18.28.123:8978 
 LogDir: /apps/logs/go/rpcx-demo 
 Operation: 
     status                                  View service status
     sync                                    Synchronization service vendor resources
     build                                   Compile and generate service program
     reload                                  Smooth restart service
     quit                                    Stop service
     help                                    View help information for the help command
 For more information about an action, use the help command to view it

At the same time, after successful execution, it will create a new bin directory in your current directory, and generate a service compilation and deployment script produce sh

Execute the deployment script ./bin/produce.sh help, it will tell you what to do next.

 service config: 
 ServiceName: rpcx-demo 
 ServiceAddr: 172.18.28.123:8978 
 LogDir: /apps/logs/go/rpcx-demo 
 Operation: 
     status                                  View service status
     sync                                    Synchronization service vendor resources
     build                                   Compile and generate service program
     reload                                  Smooth restart service
     quit                                    Stop service
     help                                    View help information for the help command
 For more information about an action, use the help command to view it

Feature

An RPC service framework based on rpcx (fast, easy-to-use but powerful RPC service governance framework of go language).

  • easy to use
  • super fast and efficient
  • powerful
  • service discovery
  • service governance
  • service layering
  • version control
  • routing label registration.

RPCX

rpcx is a RPC framework like Alibaba Dubbo and Weibo Motan.

rpcx is created for targets:

  1. Simple: easy to learn, easy to develop, easy to intergate and easy to deploy
  2. Performance: high perforamnce (>= grpc-go)
  3. Cross-platform: support raw slice of bytes, JSON, Protobuf and MessagePack. Theoretically it can be used with java, php, python, c/c++, node.js, c# and other platforms
  4. Service discovery and service governance: support zookeeper, etcd and consul.

It contains below features

  • Support raw Go functions. There's no need to define proto files.
  • Pluggable. Features can be extended such as service discovery, tracing.
  • Support TCP, HTTP, QUIC and KCP
  • Support multiple codecs such as JSON, Protobuf, MessagePack and raw bytes.
  • Service discovery. Support peer2peer, configured peers, zookeeper, etcd, consul and mDNS.
  • Fault tolerance:Failover, Failfast, Failtry.
  • Load banlancing:support Random, RoundRobin, Consistent hashing, Weighted, network quality and Geography.
  • Support Compression.
  • Support passing metadata.
  • Support Authorization.
  • Support heartbeat and one-way request.
  • Other features: metrics, log, timeout, alias, circuit breaker.
  • Support bidirectional communication.
  • Support access via HTTP so you can write clients in any programming languages.
  • Support API gateway.
  • Support backup request, forking and broadcast.

Reference

License

Released under the MIT License

Owner
ZYallers
You will be grateful to yourself in the future
ZYallers
Similar Resources

Access to b2c microservices through this service

Access to b2c microservices through this service

API service Access to b2c microservices through this service Config file Create config file with services addresses. Services: vdc - get camera inform

Nov 8, 2021

A microservices-demo service that provides catalogue/product information.

A microservices-demo service that provides catalogue/product information. This service is built, tested and released by travis.

Nov 22, 2021

A microservices-demo service that provides catalogue/product information.

A microservices-demo service that provides catalogue/product information. This service is built, tested and released by travis.

Nov 28, 2021

Kitex byte-dance internal Golang microservice RPC framework with high performance and strong scalability, customized extensions for byte internal.

Kitex byte-dance internal Golang microservice RPC framework with high performance and strong scalability, customized extensions for byte internal.

Kitex 字节跳动内部的 Golang 微服务 RPC 框架,具有高性能、强可扩展的特点,针对字节内部做了定制扩展。

Jan 9, 2023

Solution & Framework for JSON-RPC over HTTP

JROH Solution & Framework for JSON-RPC over HTTP Why not OpenAPI? OpenAPI addresses the definition of RESTful APIs, when it comes to JSON-RPCs, some i

Mar 13, 2022

Automatic Service Mesh and RPC generation for Go micro services, it's a humble alternative to gRPC with Istio.

Automatic Service Mesh and RPC generation for Go micro services, it's a humble alternative to gRPC with Istio.

Mesh RPC MeshRPC provides automatic Service Mesh and RPC generation for Go micro services, it's a humble alternative to gRPC with Istio. In a nutshell

Aug 22, 2022

Cloud-native and easy-to-use application management platform | 云原生且易用的应用管理平台

Cloud-native and easy-to-use application management platform | 云原生且易用的应用管理平台

Website • Documentation What is NEW! August 24, 2020 ,Rainbond 5.2 Stable version is officially released View Release Rainbond Introduction Cloud nati

Dec 29, 2022

Sample cloud-native application with 10 microservices showcasing Kubernetes, Istio, gRPC and OpenCensus.

Sample cloud-native application with 10 microservices showcasing Kubernetes, Istio, gRPC and OpenCensus.

Online Boutique is a cloud-native microservices demo application. Online Boutique consists of a 10-tier microservices application. The application is

Dec 31, 2022

Go microservices with REST, and gRPC using BFF pattern.

Go microservices with REST, and gRPC using BFF pattern.

Go microservices with REST, and gRPC using BFF pattern. This repository contains backend services. Everything is dockerized and ready to

Jan 4, 2023
Kratos is a microservice-oriented governance framework implements by golang,
Kratos is a microservice-oriented governance framework implements by golang,

Kratos is a microservice-oriented governance framework implements by golang, which offers convenient capabilities to help you quickly build a bulletproof application from scratch.

Dec 31, 2022
RPC explained by writing simple RPC framework in 300 lines of pure Golang.

Simple GoRPC Learning RPC basic building blocks by building a simple RPC framework in Golang from scratch. RPC In Simple Term Service A wants to call

Dec 17, 2022
Create production ready microservices mono repo pattern wired with Neo4j. Microservices for other languages and front end repos to be added as well in future.
Create production ready microservices mono repo pattern wired with Neo4j. Microservices for other languages and front end repos to be added as well in future.

Create Microservices MonoRepo in GO/Python Create a new production-ready project with backend (Golang), (Python) by running one CLI command. Focus on

Oct 26, 2022
Go-kit-microservices - Example microservices implemented with Go Kit

Go Kit Microservices Example microservices implemented with go kit, a programmin

Jan 18, 2022
The Consul API Gateway is a dedicated ingress solution for intelligently routing traffic to applications running on a Consul Service Mesh.

The Consul API Gateway is a dedicated ingress solution for intelligently routing traffic to applications running on a Consul Service Mesh.

Dec 14, 2022
Blue is a lightweight cloud-native gateway solution to handle millions of routing endpoints with a large number of connections.
Blue is a lightweight cloud-native gateway solution to handle millions of routing endpoints with a large number of connections.

Blue is a lightweight cloud-native gateway solution to handle millions of routing endpoints with a large number of connections.

Jan 19, 2022
🦄🌈 YoyoGo is a simple, light and fast , dependency injection based micro-service framework written in Go.
🦄🌈 YoyoGo is a simple, light and fast , dependency injection based micro-service framework written in Go.

???? YoyoGo is a simple, light and fast , dependency injection based micro-service framework written in Go. Support Nacos ,Consoul ,Etcd ,Eureka ,kubernetes.

Jan 4, 2023
Fast, intuitive, and powerful configuration-driven engine for faster and easier REST development
Fast, intuitive, and powerful configuration-driven engine for faster and easier REST development

aicra is a lightweight and idiomatic configuration-driven engine for building REST services. It's especially good at helping you write large APIs that remain maintainable as your project grows.

Oct 19, 2022
Design-based APIs and microservices in Go
Design-based APIs and microservices in Go

Goa is a framework for building micro-services and APIs in Go using a unique design-first approach. Overview Goa takes a different approach to buildin

Jan 5, 2023
Best microservices framework in Go, like alibaba Dubbo, but with more features, Scale easily.
Best microservices framework in Go, like alibaba Dubbo, but with more features, Scale easily.

Best microservices framework in Go, like alibaba Dubbo, but with more features, Scale easily.

Dec 30, 2022