I modified the connection test, which part of it is to connect, run a single query for one row, disconnect, to iterate only 20,000 times vs. 100,000 times. The reason for this is to allow this test to reasonably test databases that use TCP sockets. When I added Drizzle support to SQL Bench, upon running the connect test it would fail inexplicably. After some serious testing, it was realized that since Drizzle uses TCP sockets, even when connecting to localhost, that the connect test would fail because of the result of sockets being kept around in the kernel in the TIME_WAIT state so any extra TCP packets can be flushed out. The 28000 is the default port range available for socket connections.
Eric Day found this by looking:
# cat /proc/sys/net/ipv4/tcp_fin_timeout
# cat /proc/sys/net/ipv4/ip_local_port_range
So, the test would fail at 28232 connect/query/disconnect-s. This would work find in MySQL using UNIX domain sockets but as soon as I switched to TCP, it would fail. To be certain, I wrote the tests for both RDBMSs in C using the native libraries versus DBD drivers. So, hence this 28k number where it would fail was explained.
Another thing to point out is that the Perl driver for Drizzle, DBD::drizzle has some small bug as well that allows a duplicate key insert to not throw an error, but that is the driver, not sql-bench or the database server itself.
For now, feel free to have fun with SQL Bench!
The Bazaar repo is at: