memsql / dbbench

Database Benchmark Tool
Apache License 2.0
154 stars 30 forks source link

Non-sql support #1

Open tj opened 8 years ago

tj commented 8 years ago

I 100% understand if it's out of scope but it would be cool to have telnet-style protocols so this could be used for redis/influx and friends. I've written a few similar tools to stress test or create a baseline and it's definitely something that could live in a package like this!

Maybe just an interface that implements each step that can be easily wrapped up in a cli for custom cases.

awreece commented 8 years ago

So, dbbench is pretty strongly wed to the golang database/sql standard package right now. While this makes it easy to support anything that implements that package, I don't oppose moving away from this direction for a number of reasons:

If you wanted to contribute to dbbench to get this support in, I'd suggest making/finding a primitive golang sql.Driver that covers subset of functionality you care about. If that doesn't work there are other options, although for now I'll be a bit hesitant to commit to anything that substantially increases the complexity of dbbench or its reliance on non-standard packages.

If you wanted something immediately, tsung is a similar (but substantially more complex) tool that might cover the functionality you need.

awreece commented 8 years ago

I just pushed a diff that abstracted the database specific logic into a DatabaseFlavor and an abstract Database interface. This was intended to make it easier for me to write some more tests, but it might also make it possible to extend dbbench to support redis, etc w/o having to extend the sql.Driver interface.