Skip to content

Commit

Permalink
fixup! Add session setting support for specs
Browse files Browse the repository at this point in the history
  • Loading branch information
mkleen committed Aug 27, 2024
1 parent d54e59d commit fb33c98
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cr8/clients.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ def __exit__(self, exc_type, exc_val, exc_tb):
self.close()


def client(hosts, session_settings=None, concurrency=25):
def client(hosts, concurrency=25, session_settings=None):
hosts = hosts or 'localhost:4200'
if hosts.startswith('asyncpg://'):
if not asyncpg:
Expand Down
2 changes: 1 addition & 1 deletion cr8/engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def _generate_statements(stmt, args, iterations, duration):
class Runner:
def __init__(self, hosts, concurrency, sample_mode, session_settings=None):
self.concurrency = concurrency
self.client = client(hosts, session_settings=session_settings, concurrency=concurrency)
self.client = client(hosts, concurrency=concurrency, session_settings=session_settings)
self.sampler = get_sampler(sample_mode)

def warmup(self, stmt, num_warmup, concurrency=0, args=None):
Expand Down
2 changes: 1 addition & 1 deletion cr8/run_spec.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ def __init__(self,
self.session_settings = session_settings
self.spec_dir = spec_dir
self.client = clients.client(benchmark_hosts, session_settings)
self.result_client = clients.client(result_hosts, session_settings)
self.result_client = clients.client(result_hosts)
self.server_version_info = aio.run(self.client.get_server_version)
self.server_version = parse_version(self.server_version_info['number'])
self.log = log
Expand Down

0 comments on commit fb33c98

Please sign in to comment.