File: galera_ssl_compression.test

package info (click to toggle)
mariadb-10.3 1%3A10.3.34-0%2Bdeb10u1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 531,600 kB
  • sloc: cpp: 1,415,326; ansic: 917,243; perl: 58,570; sh: 43,538; pascal: 39,206; java: 33,919; yacc: 32,096; javascript: 15,655; python: 10,576; ruby: 8,684; xml: 5,957; makefile: 4,893; sql: 3,750; asm: 841; lex: 670; php: 22; awk: 20; sed: 16
file content (35 lines) | stat: -rw-r--r-- 1,504 bytes parent folder | download | duplicates (3)
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
#
# Test SSL compression. The accompanying galera_ssl_compression.cnf has a customized wsrep_provider_options setting that enables SSL and compression.
#
# Unfortunately there is no wire-level traffic bytes counter that would allow us to determine that compression kicked in, so we can only 
# perform a most basic replication check.
#

--source include/galera_cluster.inc
--source include/have_innodb.inc
--source include/big_test.inc

SELECT VARIABLE_VALUE = 'Synced' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_state_comment';
SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';

--connection node_2
SELECT VARIABLE_VALUE = 'Synced' FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_local_state_comment';
SELECT VARIABLE_VALUE = 2 FROM INFORMATION_SCHEMA.GLOBAL_STATUS WHERE VARIABLE_NAME = 'wsrep_cluster_size';

--connection node_1

# Check that the socket.ssl_compression provider option is not dynamic
--error ER_WRONG_ARGUMENTS
SET GLOBAL wsrep_provider_options = "socket.ssl_compression=No";

CREATE TABLE t1 (f1 VARCHAR(333) PRIMARY KEY, f2 BLOB) Engine=InnoDB;
INSERT INTO t1 VALUES (REPEAT('a', 333), REPEAT('b', 65535));

--connection node_2
SELECT COUNT(*) = 1 FROM t1 WHERE f1 = REPEAT('a', 333) AND f2 = REPEAT('b', 65535);

--connection node_1
DROP TABLE t1;

CALL mtr.add_suppression("Unknown parameter 'socket\.ssl_compression'");
CALL mtr.add_suppression("Set options returned 7");