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
65989dac
Commit
65989dac
authored
Jan 31, 2002
by
sasha@mysql.sashanet.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge work:/home/bk/mysql-4.0
into mysql.sashanet.com:/reiser-data/mysql-4.0
parents
2c9f1cc4
cef13d5b
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
43 additions
and
6 deletions
+43
-6
include/my_global.h
include/my_global.h
+10
-0
mysql-test/t/rpl000001.test
mysql-test/t/rpl000001.test
+20
-3
mysys/mf_iocache.c
mysys/mf_iocache.c
+1
-0
mysys/mf_iocache2.c
mysys/mf_iocache2.c
+8
-2
sql/item_func.cc
sql/item_func.cc
+3
-0
sql/slave.cc
sql/slave.cc
+1
-1
No files found.
include/my_global.h
View file @
65989dac
...
...
@@ -51,6 +51,16 @@
#endif
#endif
/* _WIN32... */
/* sometimes we want to make sure that the variable is not put into
a register in debugging mode so we can see its value in the core
*/
#ifndef DBUG_OFF
#define dbug_volatile volatile
#else
#define dbug_volatile
#endif
/*
The macros below are borrowed from include/linux/compiler.h in the
Linux kernel. Use them to indicate the likelyhood of the truthfulness
...
...
mysql-test/t/rpl000001.test
View file @
65989dac
...
...
@@ -27,21 +27,38 @@ sync_with_master;
connection
master
;
reset
master
;
connection
slave
;
slave
stop
;
reset
slave
;
connection
master
;
drop
table
if
exists
t1
,
t2
;
create
table
t1
(
n
int
);
let
$
1
=
10
;
#we want the log to exceed 16K to test deal with the log that is bigger than
#IO_SIZE
let
$
1
=
5000
;
disable_query_log
;
while
(
$
1
)
{
eval
insert
into
t1
values
(
$
1
);
eval
insert
into
t1
values
(
$
1
+
get_lock
(
"hold_slave"
,
10
)
*
0
);
dec
$
1
;
}
enable_query_log
;
#try to cause a large relay log lag on the slave
connection
slave
;
select
get_lock
(
"hold_slave"
,
10
);
slave
start
;
#hope this is long enough for I/O thread to fetch over 16K relay log data
sleep
1
;
select
release_lock
(
"hold_slave"
);
unlock
tables
;
connection
master
;
create
table
t2
(
id
int
);
insert
into
t2
values
(
connection_id
());
save_master_pos
;
connection
master1
;
#avoid generating result
create
temporary
table
t1_temp
(
n
int
);
...
...
@@ -60,7 +77,7 @@ reap;
connection
slave
;
sync_with_master
;
#give the slave a chance to exit
sleep
0.5
;
wait_for_slave_to_stop
;
# The following test can't be done because the result of Pos will differ
# on different computers
...
...
mysys/mf_iocache.c
View file @
65989dac
...
...
@@ -823,6 +823,7 @@ int my_b_append(register IO_CACHE *info, const byte *Buffer, uint Count)
}
Count
-=
length
;
Buffer
+=
length
;
info
->
end_of_file
+=
length
;
}
end:
...
...
mysys/mf_iocache2.c
View file @
65989dac
...
...
@@ -27,7 +27,10 @@
my_off_t
my_b_append_tell
(
IO_CACHE
*
info
)
{
my_off_t
res
;
/* prevent optimizer from putting res in a register when debugging
we need this to be able to see the value of res when the assert fails
*/
dbug_volatile
my_off_t
res
;
/* we need to lock the append buffer mutex to keep flush_io_cache()
from messing with the variables that we need in order to provide the
answer to the question.
...
...
@@ -35,8 +38,11 @@ my_off_t my_b_append_tell(IO_CACHE* info)
#ifdef THREAD
pthread_mutex_lock
(
&
info
->
append_buffer_lock
);
#endif
/* save the value of my_tell in res so we can see it when studying
coredump
*/
DBUG_ASSERT
(
info
->
end_of_file
-
(
info
->
append_read_pos
-
info
->
write_buffer
)
==
my_tell
(
info
->
file
,
MYF
(
0
)));
==
(
res
=
my_tell
(
info
->
file
,
MYF
(
0
)
)));
res
=
info
->
end_of_file
+
(
info
->
write_pos
-
info
->
append_read_pos
);
#ifdef THREAD
pthread_mutex_unlock
(
&
info
->
append_buffer_lock
);
...
...
sql/item_func.cc
View file @
65989dac
...
...
@@ -1433,16 +1433,19 @@ void item_user_lock_release(ULL *ull)
if
(
mysql_bin_log
.
is_open
())
{
THD
*
thd
=
current_thd
;
uint
save_query_length
;
char
buf
[
256
];
String
tmp
(
buf
,
sizeof
(
buf
));
tmp
.
length
(
0
);
tmp
.
append
(
"DO RELEASE_LOCK(
\"
"
);
tmp
.
append
(
ull
->
key
,
ull
->
key_length
);
tmp
.
append
(
"
\"
)"
);
save_query_length
=
thd
->
query_length
;
thd
->
query_length
=
tmp
.
length
();
Query_log_event
qev
(
thd
,
tmp
.
ptr
());
qev
.
error_code
=
0
;
// this query is always safe to run on slave
mysql_bin_log
.
write
(
&
qev
);
thd
->
query_length
=
save_query_length
;
}
if
(
--
ull
->
count
)
pthread_cond_signal
(
&
ull
->
cond
);
...
...
sql/slave.cc
View file @
65989dac
...
...
@@ -2010,7 +2010,7 @@ static int queue_old_event(MASTER_INFO *mi, const char *buf,
mi
->
master_log_pos
+=
event_len
;
if
(
unlikely
(
processed_stop_event
))
mi
->
ignore_stop_event
=
1
;
pthread_mutex_lock
(
&
mi
->
data_lock
);
pthread_mutex_
un
lock
(
&
mi
->
data_lock
);
return
0
;
}
...
...
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