Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
262f6b4f
Commit
262f6b4f
authored
Mar 17, 2005
by
serg@serg.mylan
Browse files
Options
Browse Files
Download
Plain Diff
Automerge
parents
aab19698
1400af88
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
1 deletion
+26
-1
mysql-test/r/rpl_drop_temp.result
mysql-test/r/rpl_drop_temp.result
+1
-0
mysql-test/t/rpl_drop_temp.test
mysql-test/t/rpl_drop_temp.test
+3
-0
sql/ha_innodb.cc
sql/ha_innodb.cc
+20
-1
sql/log_event.cc
sql/log_event.cc
+2
-0
No files found.
mysql-test/r/rpl_drop_temp.result
View file @
262f6b4f
...
@@ -10,3 +10,4 @@ create temporary table mysqltest.t2 (n int);
...
@@ -10,3 +10,4 @@ create temporary table mysqltest.t2 (n int);
show status like 'Slave_open_temp_tables';
show status like 'Slave_open_temp_tables';
Variable_name Value
Variable_name Value
Slave_open_temp_tables 0
Slave_open_temp_tables 0
drop database mysqltest;
mysql-test/t/rpl_drop_temp.test
View file @
262f6b4f
...
@@ -11,3 +11,6 @@ disconnect master;
...
@@ -11,3 +11,6 @@ disconnect master;
connection
slave
;
connection
slave
;
--
real_sleep
3
;
# time for DROP to be written
--
real_sleep
3
;
# time for DROP to be written
show
status
like
'Slave_open_temp_tables'
;
show
status
like
'Slave_open_temp_tables'
;
connection
default
;
drop
database
mysqltest
;
sql/ha_innodb.cc
View file @
262f6b4f
...
@@ -1483,7 +1483,7 @@ innobase_commit(
...
@@ -1483,7 +1483,7 @@ innobase_commit(
/* We were instructed to commit the whole transaction, or
/* We were instructed to commit the whole transaction, or
this is an SQL statement end and autocommit is on */
this is an SQL statement end and autocommit is on */
/* We need current binlog position for
HotB
ackup to work.
/* We need current binlog position for
ibb
ackup to work.
Note, the position is current because of prepare_commit_mutex */
Note, the position is current because of prepare_commit_mutex */
trx
->
mysql_log_file_name
=
mysql_bin_log
.
get_log_fname
();
trx
->
mysql_log_file_name
=
mysql_bin_log
.
get_log_fname
();
trx
->
mysql_log_offset
=
trx
->
mysql_log_offset
=
...
@@ -6472,6 +6472,25 @@ innobase_xa_prepare(
...
@@ -6472,6 +6472,25 @@ innobase_xa_prepare(
if
(
thd
->
lex
->
sql_command
!=
SQLCOM_XA_PREPARE
)
{
if
(
thd
->
lex
->
sql_command
!=
SQLCOM_XA_PREPARE
)
{
/* For ibbackup to work the order of transactions in binlog
and InnoDB must be the same. Consider the situation
thread1> prepare; write to binlog; ...
<context switch>
thread2> prepare; write to binlog; commit
thread1> ... commit
To ensure this will not happen we're taking the mutex on
prepare, and releasing it on commit.
Note: only do it for normal commits, done via ha_commit_trans.
If 2pc protocol is executed by external transaction
coordinator, it will be just a regular MySQL client
executing XA PREPARE and XA COMMIT commands.
In this case we cannot know how many minutes or hours
will be between XA PREPARE and XA COMMIT, and we don't want
to block for undefined period of time.
*/
pthread_mutex_lock
(
&
prepare_commit_mutex
);
pthread_mutex_lock
(
&
prepare_commit_mutex
);
trx
->
active_trans
=
2
;
trx
->
active_trans
=
2
;
}
}
...
...
sql/log_event.cc
View file @
262f6b4f
...
@@ -2012,6 +2012,7 @@ int Format_description_log_event::exec_event(struct st_relay_log_info* rli)
...
@@ -2012,6 +2012,7 @@ int Format_description_log_event::exec_event(struct st_relay_log_info* rli)
delete
rli
->
relay_log
.
description_event_for_exec
;
delete
rli
->
relay_log
.
description_event_for_exec
;
rli
->
relay_log
.
description_event_for_exec
=
this
;
rli
->
relay_log
.
description_event_for_exec
=
this
;
#ifdef USING_TRANSACTIONS
/*
/*
As a transaction NEVER spans on 2 or more binlogs:
As a transaction NEVER spans on 2 or more binlogs:
if we have an active transaction at this point, the master died
if we have an active transaction at this point, the master died
...
@@ -2033,6 +2034,7 @@ int Format_description_log_event::exec_event(struct st_relay_log_info* rli)
...
@@ -2033,6 +2034,7 @@ int Format_description_log_event::exec_event(struct st_relay_log_info* rli)
"to its binary log."
);
"to its binary log."
);
end_trans
(
thd
,
ROLLBACK
);
end_trans
(
thd
,
ROLLBACK
);
}
}
#endif
/*
/*
If this event comes from ourselves, there is no cleaning task to perform,
If this event comes from ourselves, there is no cleaning task to perform,
we don't call Start_log_event_v3::exec_event() (this was just to update the
we don't call Start_log_event_v3::exec_event() (this was just to update the
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment