-
Notifications
You must be signed in to change notification settings - Fork 23
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: lrq619 <[email protected]>
- Loading branch information
Showing
19 changed files
with
203 additions
and
516 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
|
||
# Spright Benchmark | ||
|
||
The spright benchmark is a set of parking slot functions(object detetction, searching, etc) adapted from: [spright](https://github.com/ucr-serverless/spright) | ||
We implement a grpc-proxy so it can be invoked by vSwarm. | ||
|
||
|
||
## Running this benchmark locally (using docker) | ||
|
||
The detailed and general description how to run benchmarks local you can find [here](../../docs/running_locally.md). The following steps show it on the spright-python function. | ||
1. Build or pull the function images using `make all-images` or `make pull`. | ||
### Invoke once | ||
2. Start the function with docker-compose | ||
```bash | ||
docker-compose -f ./yamls/docker-compose/dc-parking.yaml up | ||
``` | ||
3. In a new terminal, invoke the interface function with grpcurl. | ||
```bash | ||
./tools/bin/grpcurl -plaintext localhost:50000 helloworld.Greeter.SayHello | ||
``` | ||
### Invoke multiple times | ||
2. Run the invoker | ||
```bash | ||
# build the invoker binary | ||
cd ../../tools/invoker | ||
make invoker | ||
# Specify the hostname through "endpoints.json" | ||
echo '[ { "hostname": "localhost" } ]' > endpoints.json | ||
# Start the invoker with a chosen RPS rate and time | ||
./invoker -port 50000 -dbg -time 10 -rps 1 | ||
``` | ||
|
||
|
||
## Running this benchmark (using knative) | ||
### TODO: Need to test it on knative | ||
Below contents haven't been tested on knative | ||
The detailed and general description on how to run benchmarks on knative clusters you can find [here](../../docs/running_benchmarks.md). The following steps show it on the spright-python function. | ||
1. Build or pull the function images using `make all-images` or `make pull`. | ||
2. Start the function with knative | ||
```bash | ||
kn service apply -f ./yamls/knative/kn-parking-function-cahin-python.yaml | ||
``` | ||
3. **Note the URL provided in the output. The part without the `http://` we'll call `$URL`. Replace any instance of `$URL` in the code below with it.** | ||
### Invoke once | ||
4. In a new terminal, invoke the interface function with test-client. | ||
```bash | ||
./test-client --addr $URL:80 --name "Example invocation of spright" | ||
``` | ||
### Invoke multiple times | ||
4. Run the invoker | ||
```bash | ||
# build the invoker binary | ||
cd ../../tools/invoker | ||
make invoker | ||
# Specify the hostname through "endpoints.json" | ||
echo '[ { "hostname": "$URL" } ]' > endpoints.json | ||
# Start the invoker with a chosen RPS rate and time | ||
./invoker -port 80 -dbg -time 10 -rps 1 | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.