Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/beetlex-io/beetlex.light.gprpc
high performance dotnet core google protobuf rpc,supports millions of communication
https://github.com/beetlex-io/beetlex.light.gprpc
protobuf protocol-buffers rpc rpc-client rpc-framework rpc-library rpc-server tls
Last synced: 18 days ago
JSON representation
high performance dotnet core google protobuf rpc,supports millions of communication
- Host: GitHub
- URL: https://github.com/beetlex-io/beetlex.light.gprpc
- Owner: beetlex-io
- License: apache-2.0
- Created: 2024-06-11T01:08:03.000Z (5 months ago)
- Default Branch: main
- Last Pushed: 2024-08-22T08:01:23.000Z (3 months ago)
- Last Synced: 2024-10-11T14:09:28.000Z (about 1 month ago)
- Topics: protobuf, protocol-buffers, rpc, rpc-client, rpc-framework, rpc-library, rpc-server, tls
- Language: C#
- Homepage:
- Size: 120 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BeetleX.Light.gpRPC
high performance dotnet core google protobuf rpc,supports millions of rps communication
## server
``` csharp
RpcServer server = new RpcServer();
server.Options.SetDefaultListen(o =>
{
o.Port = 8080;
});
server.RegisterMessages();
server.Options.AddLogOutputHandler();
server.Options.LogLevel = LogLevel.Trace;
server.Start();
await Task.Delay(3000);
```## client
``` csharp
RpcClient client = "tcp://localhost:8080";
client.AddLogOutputHandler();
client.RegisterMessages();
client.LogLevel = LogLevel.Trace;
IUserHandler handler = client.Create();
RegisterReq req = new RegisterReq();
req.Address = $"guangzhouLongdong";
req.City = $"guzngzhou";
req.Email = "[email protected]";
req.FirstName = $"fan";
req.LastName = $"henry";
req.Password = "122";
var resp = await handler.Register(req);
```
## performance
Test hardware: 32-core cloud server, 100Gb network
### 1 connection 100 concurrency
![image](https://github.com/beetlex-io/BeetleX.Light.gpRPC/assets/2564178/4fd533f0-4e1d-47cf-a2d9-48a51fe5085c)### 20 connections 2000 concurrency
![image](https://github.com/beetlex-io/BeetleX.Light.gpRPC/assets/2564178/082828f1-e461-4672-85ab-fc93ec38fa2e)