-
Notifications
You must be signed in to change notification settings - Fork 8
/
test.sh
executable file
·51 lines (47 loc) · 965 Bytes
/
test.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/bash
clear
HOST=127.0.0.1
PORT=6379
echo ""
echo "Input to ECache"
echo "------------------------"
echo ""
echo "Details"
echo "-------"
echo "Host : $HOST"
echo "Port : $PORT"
echo ""
echo "Counting nb of increments:"
echo "--------------------------"
for (( c=1; c<=1000000; c++ ))
do
cat << EOF | redis-cli -h $HOST -p $PORT > /dev/null
SETBIT bit$c $c 1
GETBIT bit$c $c
EVAL "return ARGV[1]" 0 $c
GEOADD Sicily 13.361389 38.115556 Palermo 15.087269 37.502669 Catania
GEORADIUS Sicily 15 37 100 km
HSET hash$c number $c
HGET hash$c number
PFADD hyperloglog$c a b c d e f g
PFCOUNT hyperloglog$c
EXISTS string$c
EXISTS nostring$c
lpush list$c $c
rpop list$c
PUBLISH channel message$c
SADD set$c item$c
SMEMBERS set$c
ZADD zset$c $c item
ZRANGE zset$c 0 -1 WITHSCORES
SET string$c $c
GET string$c
XLEN mystream$c
UNWATCH
EOF
echo -ne "Iteration: $c"\\r
sleep 0.0001
done
echo ""
echo "--------------------------"
echo "Done!"