| 1 |
## I. Validate that X Plugin sends kill notice on IDLE connections |
| 2 |
# |
| 3 |
# Connect multiple clients, make the IDLE, and trigger kill, validate the notice |
| 4 |
# |
| 5 |
## II. Validate that X Plugin sends kill notice on connections that process a query |
| 6 |
# |
| 7 |
# 1. A connection is waiting for lock |
| 8 |
# 2. A connection is sleeping "SELECT SLEEP(A);" |
| 9 |
# |
| 10 |
## III. Validate that X Plugin not sends kill notice on not authorized connections |
| 11 |
# |
| 12 |
|
| 13 |
|
| 14 |
# |
| 15 |
# I |
| 16 |
|
| 17 |
# |
| 18 |
# Creating sessions |
| 19 |
connecting... |
| 20 |
active session is now 'session_0' |
| 21 |
connecting... |
| 22 |
active session is now 'session_1' |
| 23 |
connecting... |
| 24 |
active session is now 'session_2' |
| 25 |
connecting... |
| 26 |
active session is now 'session_3' |
| 27 |
connecting... |
| 28 |
active session is now 'session_4' |
| 29 |
connecting... |
| 30 |
active session is now 'session_5' |
| 31 |
connecting... |
| 32 |
active session is now 'session_6' |
| 33 |
connecting... |
| 34 |
active session is now 'session_7' |
| 35 |
connecting... |
| 36 |
active session is now 'session_8' |
| 37 |
connecting... |
| 38 |
active session is now 'session_9' |
| 39 |
|
| 40 |
# |
| 41 |
# Killing sessions |
| 42 |
switched to session default |
| 43 |
kill session_0 |
| 44 |
|
| 45 |
0 rows affected |
| 46 |
kill session_1 |
| 47 |
|
| 48 |
0 rows affected |
| 49 |
kill session_2 |
| 50 |
|
| 51 |
0 rows affected |
| 52 |
kill session_3 |
| 53 |
|
| 54 |
0 rows affected |
| 55 |
kill session_4 |
| 56 |
|
| 57 |
0 rows affected |
| 58 |
kill session_5 |
| 59 |
|
| 60 |
0 rows affected |
| 61 |
kill session_6 |
| 62 |
|
| 63 |
0 rows affected |
| 64 |
kill session_7 |
| 65 |
|
| 66 |
0 rows affected |
| 67 |
kill session_8 |
| 68 |
|
| 69 |
0 rows affected |
| 70 |
kill session_9 |
| 71 |
|
| 72 |
0 rows affected |
| 73 |
|
| 74 |
# |
| 75 |
# Reciving close notices |
| 76 |
switched to session session_0 |
| 77 |
[ASSERT notice warning - ERROR, 3169] |
| 78 |
Server disconnected |
| 79 |
closing session session_0 |
| 80 |
switched to session default |
| 81 |
switched to session session_1 |
| 82 |
[ASSERT notice warning - ERROR, 3169] |
| 83 |
Server disconnected |
| 84 |
closing session session_1 |
| 85 |
switched to session default |
| 86 |
switched to session session_2 |
| 87 |
[ASSERT notice warning - ERROR, 3169] |
| 88 |
Server disconnected |
| 89 |
closing session session_2 |
| 90 |
switched to session default |
| 91 |
switched to session session_3 |
| 92 |
[ASSERT notice warning - ERROR, 3169] |
| 93 |
Server disconnected |
| 94 |
closing session session_3 |
| 95 |
switched to session default |
| 96 |
switched to session session_4 |
| 97 |
[ASSERT notice warning - ERROR, 3169] |
| 98 |
Server disconnected |
| 99 |
closing session session_4 |
| 100 |
switched to session default |
| 101 |
switched to session session_5 |
| 102 |
[ASSERT notice warning - ERROR, 3169] |
| 103 |
Server disconnected |
| 104 |
closing session session_5 |
| 105 |
switched to session default |
| 106 |
switched to session session_6 |
| 107 |
[ASSERT notice warning - ERROR, 3169] |
| 108 |
Server disconnected |
| 109 |
closing session session_6 |
| 110 |
switched to session default |
| 111 |
switched to session session_7 |
| 112 |
[ASSERT notice warning - ERROR, 3169] |
| 113 |
Server disconnected |
| 114 |
closing session session_7 |
| 115 |
switched to session default |
| 116 |
switched to session session_8 |
| 117 |
[ASSERT notice warning - ERROR, 3169] |
| 118 |
Server disconnected |
| 119 |
closing session session_8 |
| 120 |
switched to session default |
| 121 |
switched to session session_9 |
| 122 |
[ASSERT notice warning - ERROR, 3169] |
| 123 |
Server disconnected |
| 124 |
closing session session_9 |
| 125 |
switched to session default |
| 126 |
Mysqlx.Ok { |
| 127 |
msg: "bye!" |
| 128 |
} |
| 129 |
ok |
| 130 |
|
| 131 |
# |
| 132 |
# II |
| 133 |
RUN CREATE TABLE test.some_table(some_column INT) |
| 134 |
|
| 135 |
0 rows affected |
| 136 |
RUN CREATE PROCEDURE test.loop_in_sp() |
| 137 |
BEGIN |
| 138 |
REPEAT |
| 139 |
SET @A=1; |
| 140 |
UNTIL FALSE END REPEAT; |
| 141 |
END |
| 142 |
|
| 143 |
|
| 144 |
0 rows affected |
| 145 |
|
| 146 |
# |
| 147 |
# Creating sessions |
| 148 |
connecting... |
| 149 |
active session is now 'session_WRITE_LOCK' |
| 150 |
RUN LOCK TABLE test.some_table WRITE |
| 151 |
|
| 152 |
0 rows affected |
| 153 |
connecting... |
| 154 |
active session is now 'session_READ_LOCK' |
| 155 |
RUN SELECT * FROM test.some_table |
| 156 |
connecting... |
| 157 |
active session is now 'session_SLEEP' |
| 158 |
RUN SELECT SLEEP(10000) |
| 159 |
connecting... |
| 160 |
active session is now 'session_SP' |
| 161 |
RUN CALL test.loop_in_sp() |
| 162 |
switched to session default |
| 163 |
|
| 164 |
# |
| 165 |
# Killing sessions |
| 166 |
switched to session default |
| 167 |
|
| 168 |
0 rows affected |
| 169 |
|
| 170 |
0 rows affected |
| 171 |
|
| 172 |
0 rows affected |
| 173 |
|
| 174 |
0 rows affected |
| 175 |
|
| 176 |
# |
| 177 |
# Reciving close notices |
| 178 |
switched to session session_WRITE_LOCK |
| 179 |
[ASSERT notice warning - ERROR, 3169] |
| 180 |
Server disconnected |
| 181 |
closing session session_WRITE_LOCK |
| 182 |
switched to session default |
| 183 |
switched to session session_READ_LOCK |
| 184 |
Mysqlx.Error(code) = 1317 |
| 185 |
Server disconnected |
| 186 |
closing session session_READ_LOCK |
| 187 |
switched to session default |
| 188 |
switched to session session_SLEEP |
| 189 |
SLEEP(10000) |
| 190 |
1 |
| 191 |
0 rows affected |
| 192 |
[ASSERT notice warning - ERROR, 3169] |
| 193 |
Server disconnected |
| 194 |
closing session session_SLEEP |
| 195 |
switched to session default |
| 196 |
switched to session session_SP |
| 197 |
Mysqlx.Error(code) = 1317 |
| 198 |
Server disconnected |
| 199 |
closing session session_SP |
| 200 |
switched to session default |
| 201 |
Mysqlx.Ok { |
| 202 |
msg: "bye!" |
| 203 |
} |
| 204 |
ok |
| 205 |
|
| 206 |
# |
| 207 |
# III |
| 208 |
|
| 209 |
# |
| 210 |
# Creating sessions |
| 211 |
connecting... |
| 212 |
active session is now 'session_noauth_0' |
| 213 |
Mysqlx.Notice.Frame(type) = 5 |
| 214 |
connecting... |
| 215 |
active session is now 'session_noauth_1' |
| 216 |
Mysqlx.Notice.Frame(type) = 5 |
| 217 |
connecting... |
| 218 |
active session is now 'session_noauth_2' |
| 219 |
Mysqlx.Notice.Frame(type) = 5 |
| 220 |
connecting... |
| 221 |
active session is now 'session_noauth_3' |
| 222 |
Mysqlx.Notice.Frame(type) = 5 |
| 223 |
connecting... |
| 224 |
active session is now 'session_noauth_4' |
| 225 |
Mysqlx.Notice.Frame(type) = 5 |
| 226 |
connecting... |
| 227 |
active session is now 'session_noauth_5' |
| 228 |
Mysqlx.Notice.Frame(type) = 5 |
| 229 |
connecting... |
| 230 |
active session is now 'session_noauth_6' |
| 231 |
Mysqlx.Notice.Frame(type) = 5 |
| 232 |
connecting... |
| 233 |
active session is now 'session_noauth_7' |
| 234 |
Mysqlx.Notice.Frame(type) = 5 |
| 235 |
connecting... |
| 236 |
active session is now 'session_noauth_8' |
| 237 |
Mysqlx.Notice.Frame(type) = 5 |
| 238 |
connecting... |
| 239 |
active session is now 'session_noauth_9' |
| 240 |
Mysqlx.Notice.Frame(type) = 5 |
| 241 |
|
| 242 |
# |
| 243 |
# Killing sessions |
| 244 |
switched to session default |
| 245 |
kill session_noauth_0 |
| 246 |
|
| 247 |
0 rows affected |
| 248 |
kill session_noauth_1 |
| 249 |
|
| 250 |
0 rows affected |
| 251 |
kill session_noauth_2 |
| 252 |
|
| 253 |
0 rows affected |
| 254 |
kill session_noauth_3 |
| 255 |
|
| 256 |
0 rows affected |
| 257 |
kill session_noauth_4 |
| 258 |
|
| 259 |
0 rows affected |
| 260 |
kill session_noauth_5 |
| 261 |
|
| 262 |
0 rows affected |
| 263 |
kill session_noauth_6 |
| 264 |
|
| 265 |
0 rows affected |
| 266 |
kill session_noauth_7 |
| 267 |
|
| 268 |
0 rows affected |
| 269 |
kill session_noauth_8 |
| 270 |
|
| 271 |
0 rows affected |
| 272 |
kill session_noauth_9 |
| 273 |
|
| 274 |
0 rows affected |
| 275 |
|
| 276 |
# |
| 277 |
# Closing connection |
| 278 |
switched to session session_noauth_0 |
| 279 |
# `recvunitldisc` command must report disconnection without any other messages |
| 280 |
Server disconnected |
| 281 |
closing session session_noauth_0 |
| 282 |
switched to session default |
| 283 |
switched to session session_noauth_1 |
| 284 |
# `recvunitldisc` command must report disconnection without any other messages |
| 285 |
Server disconnected |
| 286 |
closing session session_noauth_1 |
| 287 |
switched to session default |
| 288 |
switched to session session_noauth_2 |
| 289 |
# `recvunitldisc` command must report disconnection without any other messages |
| 290 |
Server disconnected |
| 291 |
closing session session_noauth_2 |
| 292 |
switched to session default |
| 293 |
switched to session session_noauth_3 |
| 294 |
# `recvunitldisc` command must report disconnection without any other messages |
| 295 |
Server disconnected |
| 296 |
closing session session_noauth_3 |
| 297 |
switched to session default |
| 298 |
switched to session session_noauth_4 |
| 299 |
# `recvunitldisc` command must report disconnection without any other messages |
| 300 |
Server disconnected |
| 301 |
closing session session_noauth_4 |
| 302 |
switched to session default |
| 303 |
switched to session session_noauth_5 |
| 304 |
# `recvunitldisc` command must report disconnection without any other messages |
| 305 |
Server disconnected |
| 306 |
closing session session_noauth_5 |
| 307 |
switched to session default |
| 308 |
switched to session session_noauth_6 |
| 309 |
# `recvunitldisc` command must report disconnection without any other messages |
| 310 |
Server disconnected |
| 311 |
closing session session_noauth_6 |
| 312 |
switched to session default |
| 313 |
switched to session session_noauth_7 |
| 314 |
# `recvunitldisc` command must report disconnection without any other messages |
| 315 |
Server disconnected |
| 316 |
closing session session_noauth_7 |
| 317 |
switched to session default |
| 318 |
switched to session session_noauth_8 |
| 319 |
# `recvunitldisc` command must report disconnection without any other messages |
| 320 |
Server disconnected |
| 321 |
closing session session_noauth_8 |
| 322 |
switched to session default |
| 323 |
switched to session session_noauth_9 |
| 324 |
# `recvunitldisc` command must report disconnection without any other messages |
| 325 |
Server disconnected |
| 326 |
closing session session_noauth_9 |
| 327 |
switched to session default |
| 328 |
Mysqlx.Ok { |
| 329 |
msg: "bye!" |
| 330 |
} |
| 331 |
ok |
| 332 |
DROP TABLE test.some_table; |
| 333 |
DROP PROCEDURE test.loop_in_sp; |