apache / apache/servicecomb-java-chassis

[FEATURE] - 一个性能优化思路,扩展服务监听/注册/发现和流量调度机制,实现本地地址监听&本地实例优先调度,提高微服务框架通信性能

Open
#5,124 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Java
Stars
1.9k
Forks
814
Avg merge
8d 23h
Merged PRs (30d)
1

Description

### Problem this feature would solve

微服务架构的特点是服务粒度比较小,实例数量多,实例之间存在大量通信,通信时涉及大量网络IO、加密传输、接口鉴权等性能损耗。

### Describe the solution

由于微服务实例粒度比较小,实际部署时往往多个实例会部署在一个主机上,假如同一个主机上的实例之间使用127.0.0.1地址来通信,那么受攻击面会大大减少,业务就可以考虑去掉加密传输、接口鉴权这些安全性的开销,同时在主机内通信只需要在内核协议转中转发,不需要经过网卡驱动和IO。

进一步来说,假如每个consumer都优先路由到本地的provider、同时兼顾全局的流量均衡,那么整个系统的性能都会有较大提升。

我们在业务产品上做了实验,原来一个主机上最多部署5个实例,优化后可以部署10个实例,CPU占用率与5个实例时基本持平,主机资源总体可以节省20%左右。

请社区看下这个特性,如果有价值的话我可以把代码提交进来。

### Alternatives considered

_No response_

### Additional Context

_No response_

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading the service registration, discovery, and traffic-routing entry points in ServiceComb Java Chassis; the issue does not name specific files or tests. Assess how local-address listening and prioritizing local provider instances would fit the existing mechanisms, while preserving global traffic balancing. Done would require an agreed design and implementation demonstrating the proposed communication and resource-use improvements; the issue itself provides no acceptance tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, distributed-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.