Re: Mysql-Proxy Return prior to Execution

2015-08-29 Thread Stefan Certic
Managed to solve, just in case anyone else needs the same: function read_query( packet ) if string.byte(packet) == proxy.COM_QUERY then condition. if (condition) then print("replaced with " .. query ) proxy.queries:append(1, string.char(proxy.COM_QUERY)

Re: Mysql-Proxy Return prior to Execution

2015-08-29 Thread Stefan Certic
Hi Martin, Application benchmarking purposes - i don't want any latency for updates to complete. Still, data is needed. But i don't want application nor server to handle the logic wether sql went fine or not. The idea is: Fire an update / insert, return ok to application, execute query - while ap

Mysql-Proxy Return prior to Execution

2015-08-29 Thread Stefan Certic
Hi Everyone, Does anyone by chance have a working example of mysql-proxy lua script that can: - First return OK to a client - Then actually execute the query on server, ignoring the results. Thanks in advance! -- Stefan Certic *Chief Technology Officer* ste...@cs-networks.net --