Merge with 3.23:
Set innobase_flush_log_at_trx_commit to 1 by default Fix problem with timestamp on 64 bit systems Reserve alarms for up to 10 slave threads
This commit is contained in:
commit
8b20a878cc
@ -273,6 +273,9 @@ cust 20
|
|||||||
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE lr.siteid = 'rivercats' AND emp.emp_id = 'psmith';
|
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE lr.siteid = 'rivercats' AND emp.emp_id = 'psmith';
|
||||||
rate_code base_rate
|
rate_code base_rate
|
||||||
cust 20
|
cust 20
|
||||||
|
ID Value1 ID Value2
|
||||||
|
ID Value1 ID Value2
|
||||||
|
ID Value1 ID Value2
|
||||||
drop table t1,t2;
|
drop table t1,t2;
|
||||||
create table t1 (i int);
|
create table t1 (i int);
|
||||||
create table t2 (i int);
|
create table t2 (i int);
|
||||||
|
@ -272,6 +272,20 @@ SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (site
|
|||||||
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE lr.siteid = 'rivercats' AND emp.emp_id = 'psmith';
|
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE lr.siteid = 'rivercats' AND emp.emp_id = 'psmith';
|
||||||
drop table t1,t2;
|
drop table t1,t2;
|
||||||
|
|
||||||
|
#
|
||||||
|
# Problem with internal list handling when reducing WHERE
|
||||||
|
#
|
||||||
|
|
||||||
|
CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, Value1 VARCHAR(255));
|
||||||
|
CREATE TABLE t2 (ID INTEGER NOT NULL PRIMARY KEY, Value2 VARCHAR(255));
|
||||||
|
INSERT INTO t1 VALUES (1, 'A');
|
||||||
|
INSERT INTO t2 VALUES (1, 'B');
|
||||||
|
|
||||||
|
SELECT * FROM t1 NATURAL JOIN t2 WHERE 1 AND (Value1 = 'A' AND Value2 <> 'B');
|
||||||
|
SELECT * FROM t1 NATURAL JOIN t2 WHERE 1 AND Value1 = 'A' AND Value2 <> 'B';
|
||||||
|
SELECT * FROM t1 NATURAL JOIN t2 WHERE (Value1 = 'A' AND Value2 <> 'B') AND 1;
|
||||||
|
drop table t1,t2;
|
||||||
|
|
||||||
#
|
#
|
||||||
# Test combination of join methods
|
# Test combination of join methods
|
||||||
#
|
#
|
||||||
|
@ -1,19 +1,19 @@
|
|||||||
source include/master-slave.inc;
|
source include/master-slave.inc;
|
||||||
drop database if exists d1;
|
drop database if exists test_$1;
|
||||||
create database d1;
|
create database test_$1;
|
||||||
create table d1.t1 ( n int);
|
create table test_$1.t1 ( n int);
|
||||||
alter table d1.t1 add m int;
|
alter table test_$1.t1 add m int;
|
||||||
insert into d1.t1 values (1,2);
|
insert into test_$1.t1 values (1,2);
|
||||||
create table d1.t2 (n int);
|
create table test_$1.t2 (n int);
|
||||||
insert into d1.t2 values (45);
|
insert into test_$1.t2 values (45);
|
||||||
rename table d1.t2 to d1.t3, d1.t1 to d1.t2;
|
rename table test_$1.t2 to test_$1.t3, test_$1.t1 to test_$1.t2;
|
||||||
save_master_pos;
|
save_master_pos;
|
||||||
connection slave;
|
connection slave;
|
||||||
sync_with_master;
|
sync_with_master;
|
||||||
select * from d1.t2;
|
select * from test_$1.t2;
|
||||||
select * from d1.t3;
|
select * from test_$1.t3;
|
||||||
connection master;
|
connection master;
|
||||||
drop database d1;
|
drop database test_$1;
|
||||||
save_master_pos;
|
save_master_pos;
|
||||||
connection slave;
|
connection slave;
|
||||||
sync_with_master;
|
sync_with_master;
|
||||||
|
@ -77,7 +77,7 @@ static my_bool get_word(struct simpleconfig_buf_st *fb, char *buf)
|
|||||||
endptr = fb->buf;
|
endptr = fb->buf;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (!isspace(*endptr))
|
while (*endptr && !isspace(*endptr))
|
||||||
*buf++= *endptr++;
|
*buf++= *endptr++;
|
||||||
*buf=0;
|
*buf=0;
|
||||||
fb->p = endptr;
|
fb->p = endptr;
|
||||||
|
@ -100,7 +100,7 @@ char* innobase_unix_file_flush_method = NULL;
|
|||||||
/* Below we have boolean-valued start-up parameters, and their default
|
/* Below we have boolean-valued start-up parameters, and their default
|
||||||
values */
|
values */
|
||||||
|
|
||||||
uint innobase_flush_log_at_trx_commit = 0;
|
uint innobase_flush_log_at_trx_commit = 1;
|
||||||
my_bool innobase_log_archive = FALSE;
|
my_bool innobase_log_archive = FALSE;
|
||||||
my_bool innobase_use_native_aio = FALSE;
|
my_bool innobase_use_native_aio = FALSE;
|
||||||
my_bool innobase_fast_shutdown = TRUE;
|
my_bool innobase_fast_shutdown = TRUE;
|
||||||
|
@ -717,7 +717,7 @@ void Start_log_event::print(FILE* file, bool short_form, char* last_db)
|
|||||||
print_header(file);
|
print_header(file);
|
||||||
fprintf(file, "\tStart: binlog v %d, server v %s created ", binlog_version,
|
fprintf(file, "\tStart: binlog v %d, server v %s created ", binlog_version,
|
||||||
server_version);
|
server_version);
|
||||||
print_timestamp(file, (time_t*)&created);
|
print_timestamp(file, &created);
|
||||||
fputc('\n', file);
|
fputc('\n', file);
|
||||||
fflush(file);
|
fflush(file);
|
||||||
}
|
}
|
||||||
|
@ -452,14 +452,14 @@ extern char server_version[SERVER_VERSION_LENGTH];
|
|||||||
class Start_log_event: public Log_event
|
class Start_log_event: public Log_event
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
uint32 created;
|
time_t created;
|
||||||
uint16 binlog_version;
|
uint16 binlog_version;
|
||||||
char server_version[ST_SERVER_VER_LEN];
|
char server_version[ST_SERVER_VER_LEN];
|
||||||
|
|
||||||
#ifndef MYSQL_CLIENT
|
#ifndef MYSQL_CLIENT
|
||||||
Start_log_event() :Log_event(), binlog_version(BINLOG_VERSION)
|
Start_log_event() :Log_event(), binlog_version(BINLOG_VERSION)
|
||||||
{
|
{
|
||||||
created = (uint32) when;
|
created = (time_t) when;
|
||||||
memcpy(server_version, ::server_version, ST_SERVER_VER_LEN);
|
memcpy(server_version, ::server_version, ST_SERVER_VER_LEN);
|
||||||
}
|
}
|
||||||
void pack_info(String* packet);
|
void pack_info(String* packet);
|
||||||
|
@ -1694,9 +1694,10 @@ extern "C" void *signal_hand(void *arg __attribute__((unused)))
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
Setup alarm handler
|
Setup alarm handler
|
||||||
The two extra handlers are for slave threads
|
This should actually be '+ max_number_of_slaves' instead of +10,
|
||||||
|
but the +10 should be quite safe.
|
||||||
*/
|
*/
|
||||||
init_thr_alarm(max_connections+max_insert_delayed_threads+2);
|
init_thr_alarm(max_connections+max_insert_delayed_threads+10);
|
||||||
#if SIGINT != THR_KILL_SIGNAL
|
#if SIGINT != THR_KILL_SIGNAL
|
||||||
(void) sigemptyset(&set); // Setup up SIGINT for debug
|
(void) sigemptyset(&set); // Setup up SIGINT for debug
|
||||||
(void) sigaddset(&set,SIGINT); // For debugging
|
(void) sigaddset(&set,SIGINT); // For debugging
|
||||||
|
Loading…
x
Reference in New Issue
Block a user