Our project implements a distributed profiler that can be used to trace critical path in distributed applications using the Dagger Producers framework. The project consists of the following major components -
Top lever server consists of two subcomponents - put and get. Put and get subcomponents conditionally call other service subcomponents.
Server B and Server C both have two subcomponents - b1, b2 and c1, c2 respectively. Different latency for each subcomponent is simulated by sleeping the corresponding thread. Further, each subcomponent may conditionally call other subcomponents depending on the call type.
This module implements RPC interceptor to collect latency information and also computes critical path.
The client or the load generator is used to make calls to the top level service. Further, it also collects the RPC data corresponding to different subcomponent which consists of the call graph and the latencies corresponding to each subcomponent call.
Frontend uses D3 data visualization library to display CPT information of each request.
You must already have the JDK installed to run. To install all other dependencies, including gRPC:
$ ./gradlew installDist -PskipAndroid=true
Run the server:
$ ./build/install/mygrpc/bin/top-level-server
Then run the client:
$ ./build/install/mygrpc/bin/client
To run all tests:
$ ./gradlew test
Various command line flags change the behavior of server and client. Pass
-h to the above Run commands to see the available options.
To run the UI requires grpc-web, so there are significantly more dependencies:
- protoc
- protoc-gen-grpc-web
- NodeJS
- docker
- python3
- On Mac: Command Line Tools package
- Optional: gRPC-Web Dev Tools
- Optional: Scabbard has a dependency on graphviz
if you want to generate
png's of the component graphs.
Once all dependencies are installed, use the following script:
$ ./run