Fast and Scalable RPC Framework

Rony (Fast and Scalable RPC Framework)

GitHub release (latest SemVer including pre-releases)

About

Rony lets you create a clustered aware service easily. Checkout Wiki

Performance

Rony is very fast and with very low overhead. In a non-raft environment it adds < 25us latency, and in raft-enabled scenario around 1ms latency.

Rony has negligible memory footprint by reusing buffers and pooling.

BenchmarkEdgeServerMessageSerial
BenchmarkEdgeServerMessageSerial-16                       901370              1195 ns/op              87 B/op          2 allocs/op
BenchmarkEdgeServerMessageParallel
BenchmarkEdgeServerMessageParallel-16                    4521645               272 ns/op              83 B/op          2 allocs/op
BenchmarkEdgeServerWithRaftMessageSerial
BenchmarkEdgeServerWithRaftMessageSerial-16                 9541            132065 ns/op            5034 B/op        116 allocs/op
BenchmarkEdgeServerWithRaftMessageParallel
BenchmarkEdgeServerWithRaftMessageParallel-16             124658              8438 ns/op            4462 B/op         51 allocs/op

BenchmarkServerWithWebsocket-16            46514             25138 ns/op             691 B/op         19 allocs/op

Easy Setup for advanced scenarios

package main

import (
	"github.com/ronaksoft/rony"
	"github.com/ronaksoft/rony/edge"
	"os"
)

func main() {
	serverID := "UniqueServerID"
	edgeServer := edge.NewServer(serverID,
		edge.WithTcpGateway(edge.TcpGatewayConfig{
			Concurrency:   1000,
			MaxIdleTime:   0,
			ListenAddress: "0.0.0.0:80",
			ExternalAddrs: []string{"127.0.0.1:80"}, // ExternalAddr could be used when the server is behind proxy or nats
		}),
		edge.WithUdpTunnel(edge.UdpTunnelConfig{
			ListenAddress: "0.0.0.0:8080",
			MaxBodySize:   0,
			ExternalAddrs: nil,
		}),
		edge.WithGossipCluster(edge.GossipClusterConfig{
			Bootstrap:  true,
			ReplicaSet: 1,
			GossipPort: 7091,
		}),
	)

	service.RegisterSampleService(&service.SampleService{}, edgeServer)
	edgeServer.Start()

	edgeServer.ShutdownWithSignal(os.Kill)
}

This code does not run, please check example directory for working examples


Shoulders

Rony is made of big and popular packages. Without these great libraries building Rony was not possible.

Contribution

We need to make a clear and understandable documentation for Rony, so any help would be appreciated. We also appreciate benchmarking Rony against other platforms for common scenarios and will be cited.

TODOs

  • Auto-generate REST handlers
  • Auto-generate test units
  • Implement scenario tests using edgetest framework
  • Write Examples and Tutorials
  • Helper functions for dependency injection
  • Move store package to internal and provide required interfaces and helper through rony package
  • Update the code generator templates to handle new structure.
Owner
Ronak Software Group
Ronak Software Group
Ronak Software Group
Similar Resources

llb - It's a very simple but quick backend for proxy servers. Can be useful for fast redirection to predefined domain with zero memory allocation and fast response.

llb What the f--k it is? It's a very simple but quick backend for proxy servers. You can setup redirect to your main domain or just show HTTP/1.1 404

Sep 27, 2022

Scalable WebRTC Signaling Server with ayame-like protocol.

ayu ayu is WebRTC Signaling Server with ayame-like protocol. Scalable: ayu uses Redis to store room states, so it can be used on serverless platforms

Nov 11, 2022

Go-Web-Dev - Golang helps the developer to develop highly scalable applications

Go-Web-Dev Golang helps the developer to develop highly scalable applications. T

Feb 5, 2022

A Realtime API Gateway used with NATS to build REST, real time, and RPC APIs, where all your clients are synchronized seamlessly.

A Realtime API Gateway used with NATS to build REST, real time, and RPC APIs, where all your clients are synchronized seamlessly.

Realtime API Gateway Synchronize Your Clients Visit Resgate.io for guides, live demos, and resources. Resgate is a Go project implementing a realtime

Dec 31, 2022

network multiplexing and framing protocol for RPC

TChannel Network multiplexing and framing protocol for RPC Read the Docs Languages: Node.js, Python, Go, Java Questions: Open a Github issue Uber's OS

Nov 26, 2022

Aidos Kuneen (v2 network) daemon program that is controlled through the command line and remotely via RPC calls

adk-daemon: aidosd.v2 aidosd (v2) is a deamon which acts as bitcoind for adk. This version has been built specifically for network mesh version 2+ For

Dec 1, 2021

A protoc-gen-go wrapper including an RPC stub generator

// Copyright 2013 Google. All rights reserved. // // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE fi

Nov 17, 2022

The Go language implementation of gRPC. HTTP/2 based RPC

gRPC-Go The Go implementation of gRPC: A high performance, open source, general RPC framework that puts mobile and HTTP/2 first. For more information

Jan 6, 2023

Go driven rpc code generation tool for right now.

Go driven rpc code generation tool for right now.

Go driven rpc code generation tool for right now. 100% Go Describe services with Go interfaces (with structs, methods, comments, etc.) Generate server

Dec 20, 2022
Comments
  • go 1.6 maybe

    go 1.6 maybe

    not sure if its go 1.6 or just code stability but.

      rony git:(master) ✗ go get -u github.com/ronaksoft/rony/cmd/rony
    ➜  rony git:(master) ✗ go get -u github.com/ronaksoft/rony/cmd/protoc-gen-gorony
    ➜  rony git:(master) ✗ mkdir -p example
    ➜  rony git:(master) ✗ cd ./example && rony project create --project.name github.com/ronaksoft/example --project.name example-project
    panic: runtime error: invalid memory address or nil pointer dereference
    [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x14fb2e1]
    
    goroutine 1 [running]:
    github.com/markbates/pkger/pkging/mem.(*Pkger).Walk(0xc00028eb00, 0x1607135, 0x2d, 0x0, 0x8, 0xc0003954a0)
            /Users/apple/workspace/go/pkg/mod/github.com/markbates/[email protected]/pkging/mem/mem.go:240 +0x361
    github.com/markbates/pkger/pkging.withPkger.Walk(0x16af8b0, 0xc00028eb00, 0x0, 0x0, 0x1607135, 0x2d, 0x0, 0x19b9360, 0x1623ef8)
            /Users/apple/workspace/go/pkg/mod/github.com/markbates/[email protected]/pkging/wrap.go:113 +0x53
    github.com/markbates/pkger.Walk(0x1607135, 0x2d, 0x0, 0x2, 0x15fd44b)
            /Users/apple/workspace/go/pkg/mod/github.com/markbates/[email protected]/pkger.go:79 +0x56
    github.com/ronaksoft/rony/cmd/rony/cmd.init.0()
            /Users/apple/workspace/go/pkg/mod/github.com/ronaksoft/[email protected]/cmd/rony/cmd/cmd.go:43 +0x328
    
  • create project error with windows.

    create project error with windows.

    PS E:\repository\tooyoung\hdcj\go\rony> rony project create --project.name github.com/arden/rony --project.name rony Error: exec: "mkdir": executable file not found in %PATH% Usage: rony project create [flags]

    Flags: -h, --help help for create --package.name string the full path of go package in go.mod file (default "github.com/sample") --project.dir string the root path of the project (default "E:\repository\tooyoung\hdcj\go\rony") --project.name string the name of the project (default "sample-project")

    Global Flags: --dry-run don't actually change anything

  • protoc-gen-rony install fail.

    protoc-gen-rony install fail.

    when use go get -u github.com/ronaksoft/rony/cmd/protoc-gen-rony

    and some error ocurs: go get github.com/ronaksoft/rony/cmd/protoc-gen-rony: module github.com/ronaksoft/rony@upgrade found (v0.1.8), but does not contain package github.com/ronaksoft/rony/cmd/protoc-gen-rony

A modern, fast and scalable websocket framework with elegant API written in Go
A modern, fast and scalable websocket framework with elegant API written in Go

About neffos Neffos is a cross-platform real-time framework with expressive, elegant API written in Go. Neffos takes the pain out of development by ea

Jan 4, 2023
Antenna RPC is an RPC protocol for distributed computing, it's based on QUIC and Colfer. its currently an WIP.

aRPC - Antenna Remote Procedure Call Antenna remote procedure call (aRPC) is an RPC protocol focused on distributed processing and HPC. aRPC is implem

Jun 16, 2021
rpc/v2 support for JSON-RPC 2.0 Specification.

rpc rpc/v2 support for JSON-RPC 2.0 Specification. gorilla/rpc is a foundation for RPC over HTTP services, providing access to the exported methods of

Jul 4, 2021
Go Substrate RPC Client (GSRPC)Go Substrate RPC Client (GSRPC)

Go Substrate RPC Client (GSRPC) Substrate RPC client in Go. It provides APIs and types around Polkadot and any Substrate-based chain RPC calls. This c

Nov 11, 2021
Go-random-chat - Fast and scalable real-time random chat written in go
Go-random-chat - Fast and scalable real-time random chat written in go

Go Random Chat Fast and scalable real-time random chat written in go. Features:

Dec 21, 2022
A simple RPC framework with protobuf service definitions

Twirp is a framework for service-to-service communication emphasizing simplicity and minimalism. It generates routing and serialization from API defin

Jan 7, 2023
A Light Golang RPC Framework

Glory Glory框架为一款Go语言的轻量级RPC框架,您可以使用它快速开发你的服务实例。如果您希望在微服务场景下使用gRPC进行网络通信,那么Glory会使您的开发、运维工作量减轻不少。 欢迎访问Glory主页: glory-go.github.io 示例仓库:github.com/glory

Oct 28, 2022
Netpoll is a high-performance non-blocking I/O networking framework, which focused on RPC scenarios, developed by ByteDance.
Netpoll is a high-performance non-blocking I/O networking framework, which focused on RPC scenarios, developed by ByteDance.

Netpoll is a high-performance non-blocking I/O networking framework, which focused on RPC scenarios, developed by ByteDance. RPC is usually heavy on processing logic and therefore cannot handle I/O serially. But Go's standard library net designed blocking I/O API, so that the RPC framework can only follow the One Conn One Goroutine design.

Jan 2, 2023
A local meetup to show some of the features of the Twirp RPC framework

twirpdemo This repo was created for a local meetup to show some of the features of the Twirp RPC framework. Usage Generate proto code: protoc --twirp

Sep 6, 2022
Gbio - Extremely minimalist RPC framework - Go but interface only

gbio !!! ?? WIP ?? !!! Go but interface only. gbio is a(n): Extremely minimalist

Jan 3, 2022