grpc support in fortio (grpc load testing)#519
Conversation
Gazelle doesn’t seem to generate build rule for proto
So #517 can be better/easier
…or programatic calls Also auto set the testing function for http by default
* make http runner available as library Moved a lot of the code from fortio main to the library so #517 can be better/easier (This is same as #519 with attempt at preserving history and without the grpc wip) * Added test, moved echosrv code to lib, ... Added test, moved echosrv code to lib, created DynamicHTTP for test, renames per @douglas-reid code review comments * Better initialization syntax * Add a negative testing
Used master for conflicts
prow/istio-presubmit.sh
Outdated
| bazel test //... | ||
|
|
||
| echo 'Pushing Images' | ||
| (cd devel/fortio make TAG="${GIT_SHA}") |
There was a problem hiding this comment.
don't you need a ; ?
(cd devel/fortio; make TAG="${GIT_SHA}")
|
prow/istio-presubmit.sh and makefile look legit beside the typo |
|
the presubmit part needs istio/test-infra#366 |
+ reduce the verbosity of http
douglas-reid
left a comment
There was a problem hiding this comment.
Only small nits. I don't need to review again (unless there are major changes).
devel/fortio/cmd/grpcping/pingsrv.go
Outdated
| // GODEBUG="http2debug=2" GRPC_GO_LOG_VERBOSITY_LEVEL=99 GRPC_GO_LOG_SEVERITY_LEVEL=info grpcping -loglevel debug | ||
|
|
||
| var ( | ||
| countFlag = flag.Int("n", 1, "how many ping the client will send") |
There was a problem hiding this comment.
super nit: "how many ping (s) the client will send"
|
|
||
| func main() { | ||
| flag.Parse() | ||
| if *hostFlag != "" { |
There was a problem hiding this comment.
in the future, you may want to consider https://github.com/spf13/cobra to allow subcommands that may be better suited for this purpose (instead of grpcping -host ..., you would have something like grpcping server ... which might be easier to grok (and allow file separation of client/server code)).
devel/fortio/cmd/grpcping/pingsrv.go
Outdated
| "istio.io/istio/devel/fortio" | ||
|
|
||
| context "golang.org/x/net/context" | ||
|
|
There was a problem hiding this comment.
nit: unnecessary separation of import blocks.
other nit: here and elsewhere, you are using import blocks of the order: stdlib, istio, external. elsewhere in istio, it is typically: stdlib, external, istio.
There was a problem hiding this comment.
my IDE or gofmt seems to do the ordering but I'll see if a change sticks
|
|
||
| // TestGrpc exercises Grpc health check at the target QPS. | ||
| // To be set as the Function in RunnerOptions. | ||
| func TestGrpc(t int) { |
There was a problem hiding this comment.
food for thought: i know this matches other bits, but this always makes me do a double-take to ensure that I'm not in a *_test.go file.
There was a problem hiding this comment.
yeah, on the other hand fortio is all about testing but I'll see if I can come up with something
|
|
||
| // DynamicGrpcHealthServer starts and returns the port where a Grpc Health | ||
| // server is running. It runs until error or program exit (separate go routine) | ||
| func DynamicGrpcHealthServer() int { |
There was a problem hiding this comment.
small nit: initialisms, like GRPC, are supposed to be non-mixed-case (https://github.com/golang/go/wiki/CodeReviewComments#initialisms).
There was a problem hiding this comment.
I was happy the linter didn't know about GRPC but you do :-)
There was a problem hiding this comment.
changing it but for the record I think it's less readable... but conventions are conventions so ok
Thx doug!
|
Thanks a lot @douglas-reid for all the reviews! |
* make http runner available as library Moved a lot of the code from fortio main to the library so #517 can be better/easier (This is same as #519 with attempt at preserving history and without the grpc wip) * Added test, moved echosrv code to lib, ... Added test, moved echosrv code to lib, created DynamicHTTP for test, renames per @douglas-reid code review comments * Better initialization syntax * Add a negative testing Former-commit-id: 7b83910
fortio now supports grpc testing as well fixes #451 docker images are created for fortio, grpcping, echosrv * Simple grpc cli/server Gazelle doesn’t seem to generate build rule for proto * Added payload flag * User fortio logger, temp check in of .pb. file * Renamed to grpcping * Allow grpc_cli ls to work * ping and clock skew calculations * Add histograms to grpcping * Make http runner accessible/reusable as library So #517 can be better/easier * Return actual QPS and indicate default runner options aren't needed for programatic calls Also auto set the testing function for http by default * Comment on the provenance of the code * Adding gprc std health svc check (through -health) * Grpc runner as library * Fortio now has a -grpc flag to exercise grpc servers (that have health services) For #451 * Minor fixes/updates * Added comment per code review * Opsa spell check * Fix Dockerfile Builds 3 binaries which is kind of big Todo: consider 1 binary * Move grpc in separate package to keep echosrv binary small Move grpc in separate package to keep echosrv binary small and dependencies smaller when not using grpc (so echosrv which doesn’t use grpc stays 4mb instead of becoming 6mb) (Seemingly a side effect of go’s init() that not using still pulls it in) Individual images fortio.fortio fortio.echosrv fortio.grpcping as well as a combo images having all 3 * Adding images push * Adding missing GIT_SHA * Typo galore * Debug docker version * Got push failure, trying authorize + reduce the verbosity of http * Code review comments Thx doug! Former-commit-id: 13ced35
* make http runner available as library Moved a lot of the code from fortio main to the library so istio#517 can be better/easier (This is same as istio#519 with attempt at preserving history and without the grpc wip) * Added test, moved echosrv code to lib, ... Added test, moved echosrv code to lib, created DynamicHTTP for test, renames per @douglas-reid code review comments * Better initialization syntax * Add a negative testing Former-commit-id: 7b83910
fortio now supports grpc testing as well fixes istio#451 docker images are created for fortio, grpcping, echosrv * Simple grpc cli/server Gazelle doesn’t seem to generate build rule for proto * Added payload flag * User fortio logger, temp check in of .pb. file * Renamed to grpcping * Allow grpc_cli ls to work * ping and clock skew calculations * Add histograms to grpcping * Make http runner accessible/reusable as library So istio#517 can be better/easier * Return actual QPS and indicate default runner options aren't needed for programatic calls Also auto set the testing function for http by default * Comment on the provenance of the code * Adding gprc std health svc check (through -health) * Grpc runner as library * Fortio now has a -grpc flag to exercise grpc servers (that have health services) For istio#451 * Minor fixes/updates * Added comment per code review * Opsa spell check * Fix Dockerfile Builds 3 binaries which is kind of big Todo: consider 1 binary * Move grpc in separate package to keep echosrv binary small Move grpc in separate package to keep echosrv binary small and dependencies smaller when not using grpc (so echosrv which doesn’t use grpc stays 4mb instead of becoming 6mb) (Seemingly a side effect of go’s init() that not using still pulls it in) Individual images fortio.fortio fortio.echosrv fortio.grpcping as well as a combo images having all 3 * Adding images push * Adding missing GIT_SHA * Typo galore * Debug docker version * Got push failure, trying authorize + reduce the verbosity of http * Code review comments Thx doug! Former-commit-id: 13ced35
* make http runner available as library Moved a lot of the code from fortio main to the library so #517 can be better/easier (This is same as #519 with attempt at preserving history and without the grpc wip) * Added test, moved echosrv code to lib, ... Added test, moved echosrv code to lib, created DynamicHTTP for test, renames per @douglas-reid code review comments * Better initialization syntax * Add a negative testing Former-commit-id: 7b83910
fortio now supports grpc testing as well fixes #451 docker images are created for fortio, grpcping, echosrv * Simple grpc cli/server Gazelle doesn’t seem to generate build rule for proto * Added payload flag * User fortio logger, temp check in of .pb. file * Renamed to grpcping * Allow grpc_cli ls to work * ping and clock skew calculations * Add histograms to grpcping * Make http runner accessible/reusable as library So #517 can be better/easier * Return actual QPS and indicate default runner options aren't needed for programatic calls Also auto set the testing function for http by default * Comment on the provenance of the code * Adding gprc std health svc check (through -health) * Grpc runner as library * Fortio now has a -grpc flag to exercise grpc servers (that have health services) For #451 * Minor fixes/updates * Added comment per code review * Opsa spell check * Fix Dockerfile Builds 3 binaries which is kind of big Todo: consider 1 binary * Move grpc in separate package to keep echosrv binary small Move grpc in separate package to keep echosrv binary small and dependencies smaller when not using grpc (so echosrv which doesn’t use grpc stays 4mb instead of becoming 6mb) (Seemingly a side effect of go’s init() that not using still pulls it in) Individual images fortio.fortio fortio.echosrv fortio.grpcping as well as a combo images having all 3 * Adding images push * Adding missing GIT_SHA * Typo galore * Debug docker version * Got push failure, trying authorize + reduce the verbosity of http * Code review comments Thx doug! Former-commit-id: 13ced35
Signed-off-by: Kuat Yessenov <kuat@google.com>
* [kiali] issue-18798 fix some wrong yaml. Another (trivial) change is that this alphabetizes a couple settings to make comparison with the old helm charts easier. * gen check results
…cified (istio#519) Annotations for ServiceAccounts can now be specified with helm values Signed-off-by: Nabeel Sadiq <nabeel.sadiq@paytrix.io> Signed-off-by: Pavel Nikolov <pavelnikolov@users.noreply.github.com> Co-authored-by: Pavel Nikolov <pavelnikolov@users.noreply.github.com>
fortio support for grpc
fixes #451