Bug #46360 Mysql proxy with rw-splitting.lua can't work in debug mode
Description:
When I start mysql proxy with rw-splitting.lua in debug mode, mysql proxy can't work.
The error log is
2009-07-24 15:08:45: (critical) proxy-plugin.c:1389: (connect_server) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:69: .address is deprecated. Use .src.name or .dst.name instead
2009-07-24 15:08:45: (critical) (read_query) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:179: .address is deprecated. Use .src.name or .dst.name instead
2009-07-24 15:08:45: (critical) proxy-plugin.c.1129: I have no server backend, closing connection
2009-07-24 15:08:45: (critical) network-mysqld.c.1188: plugin_call(CON_STATE_READ_QUERY) failed
2009-07-24 15:08:45: (critical) proxy-plugin.c.1684: (disconnect_client) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:356: .address is deprecated. Use .src.name or .dst.name instead
How to repeat:
Set is_debug = true in rw-splitting.lua.
Start mysql proxy with rw-splitting.lua.
Suggested fix:
Modify the rw-splitting.lua like this.
diff rw-splitting.lua.orig rw-splitting.lua
68c68
< print("[connect_server] " .. proxy.connection.client.address)
---
> print("[connect_server] " .. proxy.connection.client.src.name)
146c146
< print("[read_auth_result] " .. proxy.connection.client.address)
---
> print("[read_auth_result] " .. proxy.connection.client.src.name)
178c178
< print("[read_query] " .. proxy.connection.client.address)
---
> print("[read_query] " .. proxy.connection.client.src.name)
288c288
< print(" sending to backend : " .. b.address);
---
> print(" sending to backend : " .. b.dst.name);
322c322
< " to on slave " .. proxy.global.backends[proxy.connection.backend_ndx].address
---
> " to on slave " .. proxy.global.backends[proxy.connection.backend_ndx].dst.name
355c355
< print("[disconnect_client] " .. proxy.connection.client.address)
---
> print("[disconnect_client] " .. proxy.connection.client.src.name)
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.058 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders. It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.
Description: When I start mysql proxy with rw-splitting.lua in debug mode, mysql proxy can't work. The error log is 2009-07-24 15:08:45: (critical) proxy-plugin.c:1389: (connect_server) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:69: .address is deprecated. Use .src.name or .dst.name instead 2009-07-24 15:08:45: (critical) (read_query) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:179: .address is deprecated. Use .src.name or .dst.name instead 2009-07-24 15:08:45: (critical) proxy-plugin.c.1129: I have no server backend, closing connection 2009-07-24 15:08:45: (critical) network-mysqld.c.1188: plugin_call(CON_STATE_READ_QUERY) failed 2009-07-24 15:08:45: (critical) proxy-plugin.c.1684: (disconnect_client) [string "/home/yanbing/local/mysql-proxy/share/doc/m..."]:356: .address is deprecated. Use .src.name or .dst.name instead How to repeat: Set is_debug = true in rw-splitting.lua. Start mysql proxy with rw-splitting.lua. Suggested fix: Modify the rw-splitting.lua like this. diff rw-splitting.lua.orig rw-splitting.lua 68c68 < print("[connect_server] " .. proxy.connection.client.address) --- > print("[connect_server] " .. proxy.connection.client.src.name) 146c146 < print("[read_auth_result] " .. proxy.connection.client.address) --- > print("[read_auth_result] " .. proxy.connection.client.src.name) 178c178 < print("[read_query] " .. proxy.connection.client.address) --- > print("[read_query] " .. proxy.connection.client.src.name) 288c288 < print(" sending to backend : " .. b.address); --- > print(" sending to backend : " .. b.dst.name); 322c322 < " to on slave " .. proxy.global.backends[proxy.connection.backend_ndx].address --- > " to on slave " .. proxy.global.backends[proxy.connection.backend_ndx].dst.name 355c355 < print("[disconnect_client] " .. proxy.connection.client.address) --- > print("[disconnect_client] " .. proxy.connection.client.src.name)