TPC-Council / HammerDB

HammerDB Database Load Testing and Benchmarking Tool
http://www.hammerdb.com
GNU General Public License v3.0
589 stars 119 forks source link

Add CLI & GUI functionality to persist VU settings automatically across restarts #698

Closed v1k1nghawk closed 5 months ago

v1k1nghawk commented 5 months ago

Is your feature request related to a problem? Please describe. The current behavior of CLI & GUI requires updating Virtual Users settings manually before (using giset) or after each restart. It’s better to allow the vuset command (CLI) and Virtual Users Options menu (GUI) to save the setting to storage to improve consistency and speed of continuing benchmarking across restarts.

Describe the solution you'd like Dynamically write the VU settings to generic.db using the vuset command / Virtual Users Options menu confirmation.

Describe alternatives you've considered

  1. Update the VU settings in genericdict during vuset and write everything from genericdict to SQLite on exit, but it’s better to save data to the storage earlier.
  2. Save the VU settings to genericdict and to SQLite (during vuset) to keep them in sync (to avoid side effects such as print generic outputs outdated VU data). In this case, it is logical to modify giset too.

Additional context PR that solves the issue. The behavior and internals are similar to giset but automate frequent VU operations.

sm-shaw commented 5 months ago

Have reviewed and approved PR with additional update https://github.com/TPC-Council/HammerDB/pull/696/commits/5ff2f8aa0c98af733b4281308a4163e6cfee1928

sm-shaw commented 5 months ago

Closing Issue as PR #696 merged