Have you tried profiling your code yet? There is a blog post explaining
how to do it for Go: https://blog.golang.org/profiling-go-programs
On Sunday, July 2, 2017 at 8:16:58 AM UTC-7, Lei YiXing(北京研发中心) wrote:
>
> Hello,dear,
>
> Recently I used grpc-go in my project. But in stress testing, I
> found the throughput was very low and the response time was very long.
>
> Could you help me analyse the reason of this ? I am very confuseing
> and don’t know what I should do.
>
> I’m truly grateful for your help.
>
> Look forward to your soonest reply.
>
> Best Regards,
>
>
> Ethan Lei
>
>
>
>
>
> My grpc-server init like this:
>
>
> *// Register Services to RPC *server :=
> grpc.NewServer(grpc.MaxMsgSize(1024*1024*500),
> grpc.MaxSendMsgSize(1024*1024*500))
> grpcProto.RegisterVideoServiceServer(server, &VideoServiceImpl{})
>
> *// Register reflection service on gRPC server. *
> reflection.Register(server)
>
>
>
> My grpc-client caller like this:
>
> ctx := context.TODO()
> conn2videoInfoService, err = grpc.DialContext(ctx, videoInfoServerAddress,
> grpc.WithInsecure(), grpc.WithMaxMsgSize(1024*1024*500))
>
> videoServiceClient = grpcProto.NewVideoServiceClient(conn2videoInfoService)
>
>
>
> And when testing ,my server cpu and memory status like this:
>
>
>
>
>
> And Test Data like this:
>
>
>
> e.g. : 269.4 / s means throughput per second
>
> Avg means the average value of response time
> (millsecond)
>
> Min means the min value of response time (millsecond)
>
> Max means the max value of response time (millsecond)
>
> Active and Started means the num of thread
>
>
>
>
>
>
>
--
You received this message because you are subscribed to the Google Groups
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/grpc-io.
To view this discussion on the web visit
https://groups.google.com/d/msgid/grpc-io/a6844b83-03a5-4a9c-98e6-cb2bad7af225%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.