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
c90c7698
Commit
c90c7698
authored
May 12, 2019
by
Sergey Vojtovich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplified away CONNECT::host
Part of MDEV-19515 - Improve connect speed
parent
56b1cdde
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
10 deletions
+7
-10
sql/handle_connections_win.cc
sql/handle_connections_win.cc
+0
-1
sql/mysqld.cc
sql/mysqld.cc
+2
-6
sql/sql_connect.cc
sql/sql_connect.cc
+4
-1
sql/sql_connect.h
sql/sql_connect.h
+1
-2
No files found.
sql/handle_connections_win.cc
View file @
c90c7698
...
...
@@ -376,7 +376,6 @@ struct Pipe_Listener : public Listener
statistic_increment
(
connection_errors_internal
,
&
LOCK_status
);
return
;
}
connect
->
host
=
my_localhost
;
create_new_thread
(
connect
);
}
...
...
sql/mysqld.cc
View file @
c90c7698
...
...
@@ -6293,7 +6293,6 @@ void create_new_thread(CONNECT *connect)
void
handle_accepted_socket
(
MYSQL_SOCKET
new_sock
,
MYSQL_SOCKET
sock
)
{
CONNECT
*
connect
;
bool
is_unix_sock
;
#ifdef HAVE_LIBWRAP
{
...
...
@@ -6342,8 +6341,8 @@ void handle_accepted_socket(MYSQL_SOCKET new_sock, MYSQL_SOCKET sock)
if
((
connect
=
new
CONNECT
()))
{
is_unix_sock
=
(
mysql_socket_getfd
(
sock
)
==
mysql_socket_getfd
(
unix_sock
)
);
bool
is_unix_sock
=
mysql_socket_getfd
(
sock
)
==
mysql_socket_getfd
(
unix_sock
);
if
(
!
(
connect
->
vio
=
mysql_socket_vio_new
(
new_sock
,
...
...
@@ -6365,9 +6364,6 @@ void handle_accepted_socket(MYSQL_SOCKET new_sock, MYSQL_SOCKET sock)
return
;
}
if
(
is_unix_sock
)
connect
->
host
=
my_localhost
;
if
(
mysql_socket_getfd
(
sock
)
==
mysql_socket_getfd
(
extra_ip_sock
))
{
connect
->
extra_port
=
1
;
...
...
sql/sql_connect.cc
View file @
c90c7698
...
...
@@ -1517,7 +1517,10 @@ THD *CONNECT::create_thd(THD *thd)
init_net_server_extension
(
thd
);
thd
->
security_ctx
->
host
=
host
;
thd
->
security_ctx
->
host
=
thd
->
net
.
vio
->
type
==
VIO_TYPE_NAMEDPIPE
||
thd
->
net
.
vio
->
type
==
VIO_TYPE_SOCKET
?
my_localhost
:
0
;
thd
->
extra_port
=
extra_port
;
thd
->
scheduler
=
scheduler
;
thd
->
real_id
=
real_id
;
...
...
sql/sql_connect.h
View file @
c90c7698
...
...
@@ -32,7 +32,6 @@ class CONNECT : public ilink {
public:
/* To be copied to THD */
Vio
*
vio
;
/* Copied to THD with my_net_init() */
const
char
*
host
;
scheduler_functions
*
scheduler
;
my_thread_id
thread_id
;
pthread_t
real_id
;
...
...
@@ -43,7 +42,7 @@ class CONNECT : public ilink {
ulonglong
prior_thr_create_utime
;
CONNECT
()
:
vio
(
0
),
host
(
0
),
scheduler
(
thread_scheduler
),
thread_id
(
0
),
real_id
(
0
),
:
vio
(
0
),
scheduler
(
thread_scheduler
),
thread_id
(
0
),
real_id
(
0
),
extra_port
(
0
),
thread_count_incremented
(
0
),
prior_thr_create_utime
(
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