| 1 |
Preamble |
| 2 |
SET GLOBAL mysqlx_wait_timeout = 5; |
| 3 |
SET GLOBAL mysqlx_interactive_timeout = 10; |
| 4 |
CREATE USER temp_user@localhost |
| 5 |
IDENTIFIED WITH 'mysql_native_password' BY 'auth_string'; |
| 6 |
GRANT ALL ON *.* TO temp_user@localhost; |
| 7 |
# |
| 8 |
# Run the test without SSL |
| 9 |
# |
| 10 |
Verify [Session variable "mysqlx_wait_timeout" needs to have a value of 5] |
| 11 |
Verify [Global variable "mysqlx_wait_timeout" needs to have a value of 5] |
| 12 |
RUN SHOW SESSION VARIABLES LIKE 'mysqlx_wait_timeout' |
| 13 |
Variable_name Value |
| 14 |
mysqlx_wait_timeout 5 |
| 15 |
0 rows affected |
| 16 |
RUN SELECT CONNECTION_TYPE from performance_schema.threads where processlist_command='Query' |
| 17 |
CONNECTION_TYPE |
| 18 |
TCP/IP |
| 19 |
0 rows affected |
| 20 |
RUN SELECT USER() |
| 21 |
USER() |
| 22 |
temp_user@localhost |
| 23 |
0 rows affected |
| 24 |
RUN SHOW STATUS LIKE 'Mysqlx_ssl_active' |
| 25 |
Variable_name Value |
| 26 |
Mysqlx_ssl_active OFF |
| 27 |
0 rows affected |
| 28 |
# Hanging 'receive' command will cause wait_timeout |
| 29 |
Mysqlx.Notice.Frame { |
| 30 |
type: 1 |
| 31 |
payload: "Mysqlx.Notice.Warning { level: ERROR\ncode: 1810\nmsg: \"IO Read error: read_timeout exceeded\"\n }" |
| 32 |
} |
| 33 |
|
| 34 |
# We do no expect any message to be received here, |
| 35 |
# verification is done by comparing with 'result' file. |
| 36 |
Server disconnected |
| 37 |
ok |
| 38 |
# |
| 39 |
# Run the test with SSL |
| 40 |
# |
| 41 |
Verify [Session variable "mysqlx_wait_timeout" needs to have a value of 5] |
| 42 |
Verify [Global variable "mysqlx_wait_timeout" needs to have a value of 5] |
| 43 |
RUN SHOW SESSION VARIABLES LIKE 'mysqlx_wait_timeout' |
| 44 |
Variable_name Value |
| 45 |
mysqlx_wait_timeout 5 |
| 46 |
0 rows affected |
| 47 |
RUN SELECT CONNECTION_TYPE from performance_schema.threads where processlist_command='Query' |
| 48 |
CONNECTION_TYPE |
| 49 |
SSL/TLS |
| 50 |
0 rows affected |
| 51 |
RUN SELECT USER() |
| 52 |
USER() |
| 53 |
temp_user@localhost |
| 54 |
0 rows affected |
| 55 |
RUN SHOW STATUS LIKE 'Mysqlx_ssl_active' |
| 56 |
Variable_name Value |
| 57 |
Mysqlx_ssl_active ON |
| 58 |
0 rows affected |
| 59 |
# Hanging 'receive' command will cause wait_timeout |
| 60 |
Mysqlx.Notice.Frame { |
| 61 |
type: 1 |
| 62 |
payload: "Mysqlx.Notice.Warning { level: ERROR\ncode: 1810\nmsg: \"IO Read error: read_timeout exceeded\"\n }" |
| 63 |
} |
| 64 |
|
| 65 |
# We do no expect any message to be received here, |
| 66 |
# verification is done by comparing with 'result' file. |
| 67 |
Server disconnected |
| 68 |
ok |
| 69 |
SET GLOBAL mysqlx_wait_timeout = DEFAULT; |
| 70 |
SET GLOBAL mysqlx_interactive_timeout = DEFAULT; |
| 71 |
DROP USER temp_user@localhost; |