diff options
| author | Florian Fischer <florian.fl.fischer@fau.de> | 2019-10-13 20:29:16 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fl.fischer@fau.de> | 2019-10-13 20:29:16 +0200 |
| commit | af4722c8b69b2ecf1a2085ef1650c61ca57a104a (patch) | |
| tree | a1e4083bfad121bfc06b32cd31df8e10e8a67a06 | |
| parent | 3eab997097f23be22deb99614ee4fbc6e34ff903 (diff) | |
| download | allocbench-af4722c8b69b2ecf1a2085ef1650c61ca57a104a.tar.gz allocbench-af4722c8b69b2ecf1a2085ef1650c61ca57a104a.zip | |
fix redis
don't symlink redis binaries if they already exist.
Make shutdown_cmd work atexit by using its abspath.
| -rw-r--r-- | src/benchmarks/redis.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/benchmarks/redis.py b/src/benchmarks/redis.py index 80bd244..2987d34 100644 --- a/src/benchmarks/redis.py +++ b/src/benchmarks/redis.py @@ -44,7 +44,7 @@ class BenchmarkRedis(Benchmark): self.cmd = "redis-benchmark 1000000 -n 1000000 -P 8 -q lpush a 1 2 3 4 5 6 7 8 9 10 lrange a 1 10" self.servers = [{"name": "redis", "cmd": "redis-server", - "shutdown_cmds": ["redis-cli shutdown"]}] + "shutdown_cmds": ["{build_dir}/redis-cli shutdown"]}] super().__init__(name) @@ -71,7 +71,8 @@ class BenchmarkRedis(Benchmark): for exe in ["redis-cli", "redis-server", "redis-benchmark"]: src = os.path.join(redis_dir, "src", exe) dest = os.path.join(self.build_dir, exe) - os.link(src, dest) + if not os.path.exists(dest): + os.link(src, dest) @staticmethod def process_output(result, stdout, stderr, allocator, perm): |
