High-performance, low-cost microservice governance platform. Service Discovery and Configuration Service | 高性能、低成本微服务治理平台
APACHE-2.0 License
Bot releases are visible (Hide)
Published by Ahoo-Wang over 3 years ago
Published by Ahoo-Wang over 3 years ago
fix typo
Published by Ahoo-Wang over 3 years ago
Published by Ahoo-Wang over 3 years ago
Govern Service is a lightweight, low-cost service registration, service discovery, and configuration service SDK. By
using Redis in the existing infrastructure (I believe you have already deployed Redis), it doesn’t need to bring extra
to the operation and maintenance deployment. Cost and burden. With the high performance of Redis, Govern Service
provides ultra-high TPS&QPS. Govern Service combines the process cache strategy + Redis PubSub to achieve real-time
process cache refresh, with unparalleled QPS performance and real-time consistency between process cache and Redis.
notify-keyspace-events "Kg$shx"
You can use the following command line (redis-cli or any other redis-client) to set
notify-keyspace-events
config set notify-keyspace-events "Kg$shx"
or
config set notify-keyspace-events "KA"
val governVersion = "0.7.1";
implementation("me.ahoo.govern:spring-cloud-starter-config:${governVersion}")
implementation("me.ahoo.govern:spring-cloud-starter-discovery:${governVersion}")
<properties>
<govern.version>0.7.1</govern.version>
</properties>
<dependencies>
<dependency>
<groupId>me.ahoo.govern</groupId>
<artifactId>spring-cloud-starter-config</artifactId>
<version>${govern.version}</version>
</dependency>
<dependency>
<groupId>me.ahoo.govern</groupId>
<artifactId>spring-cloud-starter-discovery</artifactId>
<version>${govern.version}</version>
</dependency>
</dependencies>
spring:
application:
name: govern-rest-api
cloud:
govern:
namespace: dev
config:
config-id: ${spring.application.name}.yml
redis:
mode: standalone
url: redis://localhost:6379
Optional
)bin/rest-api
gradle jmh
# JMH version: 1.28
# VM version: JDK 11.0.11, OpenJDK 64-Bit Server VM, 11.0.11+9-LTS
# VM invoker: /Library/Java/JavaVirtualMachines/zulu-11.jdk/Contents/Home/bin/java
# VM options: -Dfile.encoding=UTF-8 -Djava.io.tmpdir=/Users/ahoo/govern-service/config/build/tmp/jmh -Duser.country=CN -Duser.language=zh -Duser.variant
# Blackhole mode: full + dont-inline hint
# Warmup: 1 iterations, 10 s each
# Measurement: 1 iterations, 10 s each
# Timeout: 10 min per iteration
# Threads: 50 threads, will synchronize iterations
# Benchmark mode: Throughput, ops/time
Benchmark Mode Cnt Score Error Units
ConsistencyRedisConfigServiceBenchmark.getConfig thrpt 555275866.836 ops/s
RedisConfigServiceBenchmark.getConfig thrpt 57397.188 ops/s
RedisConfigServiceBenchmark.setConfig thrpt 56882.673 ops/s
# JMH version: 1.29
# VM version: JDK 11.0.11, OpenJDK 64-Bit Server VM, 11.0.11+9-LTS
# VM invoker: /Library/Java/JavaVirtualMachines/zulu-11.jdk/Contents/Home/bin/java
# VM options: -Dfile.encoding=UTF-8 -Djava.io.tmpdir=/Users/ahoo/work/ahoo-git/govern-service/discovery/build/tmp/jmh -Duser.country=CN -Duser.language=zh -Duser.variant
# Blackhole mode: full + dont-inline hint
# Warmup: 1 iterations, 10 s each
# Measurement: 1 iterations, 10 s each
# Timeout: 10 min per iteration
# Threads: 50 threads, will synchronize iterations
# Benchmark mode: Throughput, ops/time
Benchmark Mode Cnt Score Error Units
ConsistencyRedisServiceDiscoveryBenchmark.getInstances thrpt 567329996.255 ops/s
ConsistencyRedisServiceDiscoveryBenchmark.getServices thrpt 1929377291.635 ops/s
RedisServiceDiscoveryBenchmark.getInstances thrpt 43760.035 ops/s
RedisServiceDiscoveryBenchmark.getServices thrpt 60953.971 ops/s
RedisServiceRegistryBenchmark.deregister thrpt 63133.011 ops/s
RedisServiceRegistryBenchmark.register thrpt 53957.797 ops/s
RedisServiceRegistryBenchmark.renew thrpt 67116.116 ops/s