cd scripts && bash recompile_thrift.sh
mvn spotless:apply
mvn clean package -DskipTests
To run test, you should prepare the test environment:
net-tools
mvn clean package
Or specify one test:
mvn clean package -Dtest=TestPing
cd scripts && bash recompile_thrift.sh && cd - mvn clean install -DskipTests
Configure client by pegasus.properties
file, for example:
meta_servers = 127.0.0.1:34601,127.0.0.1:34602,127.0.0.1:34603 operation_timeout = 1000 async_workers = 4 enable_perf_counter = true perf_counter_tags = k1=v1,k2=v2,k3=v3 push_counter_interval_secs = 10
You can provide a parameter of configPath
when creating a client instance.
The format of configPath
should be one of these:
Pegasus Java Client supports QPS and latency statistics of requests.
The related configurations are:
enable_perf_counter = true perf_counter_tags = k1=v1,k2=v2,k3=v3 push_counter_interval_secs = 10
For each type of request(get, set, multiset, etc.), we collect 8 metrics:
We use io.dropwizard.metrics library to calculate the request count.
Currently, metrics are integrated with open-falcon(https://github.com/open-falcon),
which push counters to local http agent http://127.0.0.1:1988/push/v1.
If you'd like to integrate pegasus client with other monitor system, please let us know ASAP.