首页 > 其他分享 >Etcd开启grpc请求耗时监控

Etcd开启grpc请求耗时监控

时间:2024-05-13 22:54:31浏览次数:19  
标签:Txn Etcd grpc 耗时 Range etcd

针对各种类型grpc请求耗时统计场景,etcd提供监控数据。

# etcd容器增加环境变量
env:
- name: ETCD_METRICS
  value: extensive
curl -s http://127.0.0.1:2381/metrics | grep grpc_server_handling_seconds_bucket

grpc_method包含了Alarm/AuthDisable/AuthEnable/Authenticate/Check/Compact/Defragment/DeleteRange/Hash/HashKV/LeaseGrant/LeaseKeepAlive/LeaseLeases/LeaseRevoke/LeaseTimeToLive/MemberAdd/MemberList/MemberPromote/MemberRemove/MemberUpdate/MoveLeader/Put/Range/RoleAdd/RoleDelete/RoleGet/RoleGrantPermission/RoleList/RoleRevokePermission/Snapshot/Status/Txn/UserAdd/UserChangePassword/UserDelete/UserGet/UserGrantRole/UserList/UserRevokeRole/Watch这些类型。

其中,Range是用户读,Txn是用户写。

标签:Txn,Etcd,grpc,耗时,Range,etcd
From: https://www.cnblogs.com/WJQ2017/p/18190228

相关文章

  • Etcd开启trace
    针对处理耗时超过100ms的grpc请求,etcd打印包含耗时长的阶段的trace日志。#etcd容器增加环境变量env:-name:ETCD_LOGGERvalue:zaptrace日志举例{"level":"info","ts":"2024-05-13T14:16:45.478Z","caller":"traceutil/trace.......
  • etcd集群搭建
    主机环境和分配规划:主机ip  主机名  操作系统环境  操作系统版本172.17.0.2etcd01centos7.9172.17.0.3etcd02centos7.9172.17.0.4etcd03centos7.9etcd官网下载,我这边下载的是v3.4.32版本https://objects.githubusercontent.com/github-product......
  • GRPC - Deploying: Envoy proxy
    Installfunc-e: https://func-e.io/func-emakesrunningEnvoy®easyfunc-e(pronouncedfunky)allowsyoutoquicklyseeavailableversionsofEnvoyandtrythemout.Thismakesiteasytovalidateconfigurationyouwoulduseinproduction.Eachtimeyoue......
  • Dockerfile - build zgrpc-go-professionals:client
     FROM--platform=$BUILDPLATFORMalpineasprotocARGBUILDPLATFORM=linux/amd64TARGETOS=linuxTARGETARCH=amd64#downloadtheprotocbinaryfromgithub#Weunzipthefileinto/usr/local.Noticethatweareextractingboththeprotoc#binary(/bin/pr......
  • Dockerfile - build zgrpc-go-professionals:server
     FROM--platform=$BUILDPLATFORMalpineasprotocARGBUILDPLATFORM=linux/amd64TARGETOS=linuxTARGETARCH=amd64#downloadtheprotocbinaryfromgithub#Weunzipthefileinto/usr/local.Noticethatweareextractingboththeprotoc#binary(/bin/pr......
  • GRPC - grpcurl: interact with gRPC servers
    https://github.com/fullstorydev/grpcurl Install:goinstallgithub.com/fullstorydev/grpcurl/cmd/grpcurl@latest Addcodetoenableserverreflection:import"google.golang.org/grpc/reflection"reflection.Register(s)//sisagrpcserver......
  • GRPC - ghz: gRPC benchmarking and load testing tool
     https://ghz.sh/https://github.com/bojand/ghz Installusinggo>=1.16goinstallgithub.com/bojand/ghz/cmd/ghz@latest zzh@ZZHPC:/zdata/Github/zgrpc-go-professionals$ghz--proto./proto/todo/v2/todo.proto\--import-paths=proto\--callto......
  • gRPC入门学习之旅目录
     gRPC入门学习之旅(一)gRPC入门学习之旅(二)gRPC入门学习之旅(三)gRPC入门学习之旅(四)gRPC入门学习之旅(五)gRPC入门学习之旅(六) gRPC入门学习之旅(七)gRPC入门学习之旅(八)......
  • gRPC入门学习之旅(八)
     gRPC入门学习之旅(一)gRPC入门学习之旅(二)gRPC入门学习之旅(三)gRPC入门学习之旅(四)gRPC入门学习之旅(五)gRPC入门学习之旅(六) gRPC入门学习之旅(七) 3.7、添加proto协议文件1.将服务端项目Demo.GrpcService中的Protos目录中的Grpc协议文件复制过来,如下图所示:......
  • ZGRPC - A Unit Test Failure
     functestUpdateTasksUnavailableDb(t*testing.T){//Arrangeconn,c:=newClient(t)deferconn.Close()newDb:=NewFakeDb(IsAvailable(false))*fakeDb=*newDb//ClearallthefieldsinfakeDb.d.tasksexceptId.requests......