1
# Copyright (C) 2008-2009 Sun Microsystems, Inc. All rights reserved.
2
# Use is subject to license terms.
4
# This program is free software; you can redistribute it and/or modify
5
# it under the terms of the GNU General Public License as published by
6
# the Free Software Foundation; version 2 of the License.
8
# This program is distributed in the hope that it will be useful, but
9
# WITHOUT ANY WARRANTY; without even the implied warranty of
10
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11
# General Public License for more details.
13
# You should have received a copy of the GNU General Public License
14
# along with this program; if not, write to the Free Software
15
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
19
stall_serial_log_rotation |
20
serial_log_event | serial_log_event | serial_log_event | serial_log_event | serial_log_event |
21
serial_log_event | serial_log_event | serial_log_event | serial_log_event | serial_log_event |
22
serial_log_event | serial_log_event | serial_log_event | serial_log_event | serial_log_event |
23
serial_log_event | serial_log_event | serial_log_event | serial_log_event | serial_log_event ;
26
# This creates a transaction in connection_id = 10 that performs an update and then lives for 1800 seconds.
27
# This makes serial log rotation impossible, resulting in larger serial log files and longer recovery times.
30
stall_serial_log_rotation:
31
START TRANSACTION ; CREATE TEMPORARY TABLE IF NOT EXISTS stall ( `f1` INTEGER , `connection_id` INTEGER ) ENGINE = Falcon ; INSERT INTO stall VALUES (_digit, CONNECTION_ID()) ; UPDATE stall SET f1 = f1 + 1 WHERE connection_id = CONNECTION_ID() ; SELECT IF( CONNECTION_ID() = 10 , SLEEP(1800) , 1 ) ;
74
DELETE FROM _table WHERE `col_int` = CONNECTION_ID() LIMIT 1 ;
77
INSERT INTO _table ( `col_int` , `blob` ) VALUES ( CONNECTION_ID() , _data ) |
78
UPDATE _table SET `blob` = _data WHERE `col_int` = CONNECTION_ID() LIMIT _digit ;
83
START TRANSACTION | COMMIT | COMMIT | COMMIT | COMMIT ;
86
ALTER TABLE _table ADD key_type _letter ( `col_int` ) |
87
ALTER TABLE _table ADD key_type _letter ( `col_int` ) |
88
ALTER TABLE _table ADD key_type _letter ( `col_char_255` ) |
89
ALTER TABLE _table ADD key_type _letter ( `col_char_255` ) ;
92
INDEX | UNIQUE | PRIMARY KEY ;
95
CREATE TABLE IF NOT EXISTS _letter (`f1` VARCHAR(255) ) ENGINE = FALCON TABLESPACE _letter ; INSERT INTO _letter SELECT _field FROM _table ;
98
CREATE TABLESPACE _letter ADD DATAFILE file_name ENGINE = FALCON ;
105
DELETE FROM _table LIMIT 1;
108
ALTER TABLE _table DROP INDEX _letter ;
111
DROP TABLE IF EXISTS _letter ;
114
# This is disabled because of bug 39138
117
# DROP TABLESPACE _letter ENGINE = FALCON
121
TRUNCATE TABLE _letter ;
124
INSERT INTO _table ( `col_int` ) VALUES ( _digit ) |
125
INSERT INTO _table ( `col_char_255` ) VALUES ( _english ) ;
128
DELETE FROM _table LIMIT 1;
131
INSERT INTO _table ( `col_int` ) SELECT `col_int` FROM _table LIMIT _tinyint_unsigned ;
138
insert_big_record ; insert_big_record ; insert_big_record ; insert_big_record ; insert_big_record ; insert_big_record ; insert_big_record ;
150
SAVEPOINT A | SAVEPOINT A | SAVEPOINT A | SAVEPOINT A |
151
ROLLBACK TO SAVEPOINT A ;
160
INSERT INTO _table (`pk`) VALUE ( NULL ) ;
169
UPDATE _table SET `blob` = _data WHERE `col_int` = CONNECTION_ID() LIMIT _digit |
170
INSERT INTO _table (`col_int`, `blob`) VALUES ( CONNECTION_ID(), _data ) ;
173
INSERT INTO _table (`col_int`) VALUES ( _digit ) ;
176
UPDATE _table SET `col_int` = `col_int` + 1 LIMIT 1 ;
183
INSERT INTO _table ( `col_char_255` ) VALUES ( REPEAT('x', 255) ) ;
186
''f1'' | ''f2'' | ''f3'' | ''f4'' | ''f5'' | ''f6'' | ''f7'' | ''f8'' | ''f9'' | ''f10'' |
187
''f11'' | ''f12'' | ''f13'' | ''f14'' | ''f15'' | ''f16'' | ''f17'' | ''f18'' | ''f19'' | ''f20'' ;