Hello Robert,

Pgbench *currently* already accept multiple "-f ..." options, and this is a
good thing to test realistic loads which may intermix several kind of
transactions, say a lot of readonly and some update or insert, and very rare
deletes...

Hmm, I didn't realize that.  The code looks a bit inconsistent right
now - e.g. we do support multiple files, but pgbench's options-parsing
loop sets ttype to a value that depends only on the last of -f, -N,
and -S encountered.

Indeed. However as with current pgbench <nothing>/-N/-S and -f are mutually exclusive it is ok to have ttype set as it is.

With the patch pgbench just executes scripts and the options are not mutually exclusive: some scripts are internal and others are not, but they are treated the same beyond initialization, which helps removing some code including the "ttype" variable you mention. The name of the script is kept in an SQLScript struct along with its commands, weight and stats.

--
Fabien.


--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to