Add support for setting the query timeout via query string or API. Note that
the timeout is still a rough timing based on how long it takes to communicate
with the backend and does not account for the aggregation/TSD side time.
Also add a max_rows flag to the queries that can be used as a means of limiting
a query when too many rows of data have been scanned.