Skip to content

Commit

Permalink
add socket
Browse files Browse the repository at this point in the history
  • Loading branch information
zizdlp committed Oct 8, 2023
1 parent 5cc8b64 commit 3229ef4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 3 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
LOOP ?= 10
LENGTH ?= 25000

RANDOM_PORT := $(shell shuf -i 50001-50099 -n 1)
PORT ?= $(RANDOM_PORT)
build:
bazel build //profile/workflow:sync_server
bazel build //profile/workflow:sync_client
Expand All @@ -9,5 +10,5 @@ build:
bazel build //profile/socket:server
bazel build //profile/socket:client
benchmark:
python benchmark.py --loop=$(LOOP) --length=$(LENGTH)
python benchmark.py --loop=$(LOOP) --length=$(LENGTH) --port=$(PORT)
.PHONY: workflow_sync_server workflow_sync_client benchmark
1 change: 0 additions & 1 deletion benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import argparse

def benchmark(server, client, length=None, loop=None,port=None):
time.sleep(3)
# 启动 sync_server 进程
server_args = [server]
if port is not None:
Expand Down

0 comments on commit 3229ef4

Please sign in to comment.