Skip to content

Commit d81b77b

Browse files
author
Pavel_Shilin
committed
Fixed outputs in the replication-test.rec test
1 parent 8ab3578 commit d81b77b

File tree

1 file changed

+128
-7
lines changed

1 file changed

+128
-7
lines changed

test/clt-tests/replication/replication-test.rec

Lines changed: 128 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,137 @@
11
––– input –––
22
export INSTANCE=1
33
––– output –––
4-
––– block: ../base/replication/start-searchd-precach –––
4+
––– input –––
5+
mkdir -p /var/{run,lib,log}/manticore-${INSTANCE}/{a,b,c,d,e,f,g,h,i,j}
6+
––– output –––
7+
––– input –––
8+
stdbuf -oL searchd -c test/clt-tests/base/searchd-with-flexible-ports.conf | grep -v precach
9+
––– output –––
10+
Manticore %{SEMVER} %{COMMITDATE}#!/(\sdev)?\s/!#(columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})
11+
Copyright (c) 2001-2016, Andrew Aksyonoff
12+
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)
13+
Copyright (c) 2017-%{YEAR}, Manticore Software LTD (https://manticoresearch.com)
14+
[#!/[a-zA-Z]{3}\s[a-zA-Z]{3}\s+[0-9]{1,2}\s[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}\s[0-9]{4}/!#] [%{NUMBER}] using config file '/.clt/test/clt-tests/base/searchd-with-flexible-ports.conf' (%{NUMBER} chars)...
15+
starting daemon version '%{SEMVER} %{COMMITDATE} dev (columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})' ...
16+
listening on all interfaces for mysql, port=%{NUMBER}
17+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
18+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
19+
––– input –––
20+
if timeout 10 grep -qm1 'accepting connections' <(tail -n 1000 -f /var/log/manticore-${INSTANCE}/searchd.log); then echo 'Accepting connections!'; else echo 'Timeout or failed!'; fi
21+
––– output –––
22+
Accepting connections!
523
––– input –––
624
export INSTANCE=2
725
––– output –––
8-
––– block: ../base/replication/start-searchd-precach –––
26+
––– input –––
27+
mkdir -p /var/{run,lib,log}/manticore-${INSTANCE}/{a,b,c,d,e,f,g,h,i,j}
28+
––– output –––
29+
––– input –––
30+
stdbuf -oL searchd -c test/clt-tests/base/searchd-with-flexible-ports.conf | grep -v precach
31+
––– output –––
32+
Manticore %{SEMVER} %{COMMITDATE}#!/(\sdev)?\s/!#(columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})
33+
Copyright (c) 2001-2016, Andrew Aksyonoff
34+
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)
35+
Copyright (c) 2017-%{YEAR}, Manticore Software LTD (https://manticoresearch.com)
36+
[#!/[a-zA-Z]{3}\s[a-zA-Z]{3}\s+[0-9]{1,2}\s[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}\s[0-9]{4}/!#] [%{NUMBER}] using config file '/.clt/test/clt-tests/base/searchd-with-flexible-ports.conf' (%{NUMBER} chars)...
37+
starting daemon version '%{SEMVER} %{COMMITDATE} dev (columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})' ...
38+
listening on all interfaces for mysql, port=%{NUMBER}
39+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
40+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
41+
––– input –––
42+
if timeout 10 grep -qm1 'accepting connections' <(tail -n 1000 -f /var/log/manticore-${INSTANCE}/searchd.log); then echo 'Accepting connections!'; else echo 'Timeout or failed!'; fi
43+
––– output –––
44+
Accepting connections!
945
––– input –––
1046
export INSTANCE=3
1147
––– output –––
12-
––– block: ../base/replication/start-searchd-precach –––
48+
––– input –––
49+
mkdir -p /var/{run,lib,log}/manticore-${INSTANCE}/{a,b,c,d,e,f,g,h,i,j}
50+
––– output –––
51+
––– input –––
52+
stdbuf -oL searchd -c test/clt-tests/base/searchd-with-flexible-ports.conf | grep -v precach
53+
––– output –––
54+
Manticore %{SEMVER} %{COMMITDATE}#!/(\sdev)?\s/!#(columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})
55+
Copyright (c) 2001-2016, Andrew Aksyonoff
56+
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)
57+
Copyright (c) 2017-%{YEAR}, Manticore Software LTD (https://manticoresearch.com)
58+
[#!/[a-zA-Z]{3}\s[a-zA-Z]{3}\s+[0-9]{1,2}\s[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}\s[0-9]{4}/!#] [%{NUMBER}] using config file '/.clt/test/clt-tests/base/searchd-with-flexible-ports.conf' (%{NUMBER} chars)...
59+
starting daemon version '%{SEMVER} %{COMMITDATE} dev (columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})' ...
60+
listening on all interfaces for mysql, port=%{NUMBER}
61+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
62+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
63+
––– input –––
64+
if timeout 10 grep -qm1 'accepting connections' <(tail -n 1000 -f /var/log/manticore-${INSTANCE}/searchd.log); then echo 'Accepting connections!'; else echo 'Timeout or failed!'; fi
65+
––– output –––
66+
Accepting connections!
1367
––– input –––
1468
export INSTANCE=4
1569
––– output –––
16-
––– block: ../base/replication/start-searchd-precach –––
70+
––– input –––
71+
mkdir -p /var/{run,lib,log}/manticore-${INSTANCE}/{a,b,c,d,e,f,g,h,i,j}
72+
––– output –––
73+
––– input –––
74+
stdbuf -oL searchd -c test/clt-tests/base/searchd-with-flexible-ports.conf | grep -v precach
75+
––– output –––
76+
Manticore %{SEMVER} %{COMMITDATE}#!/(\sdev)?\s/!#(columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})
77+
Copyright (c) 2001-2016, Andrew Aksyonoff
78+
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)
79+
Copyright (c) 2017-%{YEAR}, Manticore Software LTD (https://manticoresearch.com)
80+
[#!/[a-zA-Z]{3}\s[a-zA-Z]{3}\s+[0-9]{1,2}\s[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}\s[0-9]{4}/!#] [%{NUMBER}] using config file '/.clt/test/clt-tests/base/searchd-with-flexible-ports.conf' (%{NUMBER} chars)...
81+
starting daemon version '%{SEMVER} %{COMMITDATE} dev (columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})' ...
82+
listening on all interfaces for mysql, port=%{NUMBER}
83+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
84+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
85+
––– input –––
86+
if timeout 10 grep -qm1 'accepting connections' <(tail -n 1000 -f /var/log/manticore-${INSTANCE}/searchd.log); then echo 'Accepting connections!'; else echo 'Timeout or failed!'; fi
87+
––– output –––
88+
Accepting connections!
1789
––– input –––
1890
export INSTANCE=5
1991
––– output –––
20-
––– block: ../base/replication/start-searchd-precach –––
92+
––– input –––
93+
mkdir -p /var/{run,lib,log}/manticore-${INSTANCE}/{a,b,c,d,e,f,g,h,i,j}
94+
––– output –––
95+
––– input –––
96+
stdbuf -oL searchd -c test/clt-tests/base/searchd-with-flexible-ports.conf | grep -v precach
97+
––– output –––
98+
Manticore %{SEMVER} %{COMMITDATE}#!/(\sdev)?\s/!#(columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})
99+
Copyright (c) 2001-2016, Andrew Aksyonoff
100+
Copyright (c) 2008-2016, Sphinx Technologies Inc (http://sphinxsearch.com)
101+
Copyright (c) 2017-%{YEAR}, Manticore Software LTD (https://manticoresearch.com)
102+
[#!/[a-zA-Z]{3}\s[a-zA-Z]{3}\s+[0-9]{1,2}\s[0-9]{2}:[0-9]{2}:[0-9]{2}.[0-9]{3}\s[0-9]{4}/!#] [%{NUMBER}] using config file '/.clt/test/clt-tests/base/searchd-with-flexible-ports.conf' (%{NUMBER} chars)...
103+
starting daemon version '%{SEMVER} %{COMMITDATE} dev (columnar %{SEMVER} %{COMMITDATE}) (secondary %{SEMVER} %{COMMITDATE}) (knn %{SEMVER} %{COMMITDATE})' ...
104+
listening on all interfaces for mysql, port=%{NUMBER}
105+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
106+
listening on all interfaces for sphinx and http(s), port=%{NUMBER}
107+
––– input –––
108+
if timeout 10 grep -qm1 'accepting connections' <(tail -n 1000 -f /var/log/manticore-${INSTANCE}/searchd.log); then echo 'Accepting connections!'; else echo 'Timeout or failed!'; fi
109+
––– output –––
110+
Accepting connections!
21111
––– input –––
22112
export CLUSTER_NAME=replication
23113
––– output –––
24-
––– block: ../base/replication/create-cluster –––
114+
––– input –––
115+
mysql -h0 -P1306 -e "create cluster ${CLUSTER_NAME}"
116+
––– output –––
117+
––– input –––
118+
mysql -h0 -P1306 -e "show status like 'cluster_${CLUSTER_NAME}_status'\G"
119+
––– output –––
120+
*************************** 1. row ***************************
121+
Counter: cluster_#!/[a-z]+/!#_status
122+
Value: primary
25123
––– input –––
26124
export CLUSTER_NAME=replication
27125
––– output –––
28-
––– block: ../base/replication/join-cluster-on-all-nodes –––
126+
––– input –––
127+
for n in `seq 2 $INSTANCE`; do mysql -h0 -P${n}306 -e "join cluster ${CLUSTER_NAME} at '127.0.0.1:1312'"; done;
128+
––– output –––
129+
––– input –––
130+
mysql -h0 -P${INSTANCE}306 -e "show status like 'cluster_${CLUSTER_NAME}_status'\G"
131+
––– output –––
132+
*************************** 1. row ***************************
133+
Counter: cluster_#!/[a-z]+/!#_status
134+
Value: primary
29135
––– input –––
30136
mysql -h0 -P1306 -e "CREATE TABLE testrt (title text, content text, gid uint);"
31137
––– output –––
@@ -35,6 +141,11 @@ mysql -h0 -P1306 -e "ALTER CLUSTER replication ADD testrt;"
35141
––– input –––
36142
mysql -h0 -P1306 -e "SHOW STATUS LIKE 'cluster_replication_indexes';"
37143
––– output –––
144+
+-----------------------------+--------+
145+
| Counter | Value |
146+
+-----------------------------+--------+
147+
| cluster_replication_indexes | testrt |
148+
+-----------------------------+--------+
38149
––– input –––
39150
mysql -h0 -P1306 -e "INSERT INTO replication:testrt VALUES(6775836565403860993,'List of HP business laptops','Elitebook Probook',1);"
40151
––– output –––
@@ -44,6 +155,16 @@ mysql -h0 -P1306 -e "INSERT INTO replication:testrt VALUES(6775836565403860994,'
44155
––– input –––
45156
mysql -h0 -P1306 -e "SHOW CREATE TABLE testrt;"
46157
––– output –––
158+
+--------+--------------------------------------------------------------------------+
159+
| Table | Create Table |
160+
+--------+--------------------------------------------------------------------------+
161+
| testrt | CREATE TABLE testrt (
162+
id bigint,
163+
title text,
164+
content text,
165+
gid integer
166+
) |
167+
+--------+--------------------------------------------------------------------------+
47168
––– input –––
48169
export INSTANCE=5
49170
––– output –––

0 commit comments

Comments
 (0)