Skip to content

Commit

Permalink
Update ab command
Browse files Browse the repository at this point in the history
  • Loading branch information
Kunihiko Kido committed Apr 23, 2015
1 parent c919694 commit 7da3099
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion elasticsearch_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,13 @@ def run_apache_bench(self, path,
requests='100', concurrency='10', postfile=''):
url = self.get_request_url(path)
command = [self.ab_command, '-n', requests, '-c', concurrency,
'-p', postfile, '-T', 'application/json', url]
'-p', postfile, '-T', 'application/json']

for k, v in self.http_headers.items():
command += ['-H', "{0}: {1}".format(k, v)]

command += [url]

self.run_command(command)

def make_path(self):
Expand Down

0 comments on commit 7da3099

Please sign in to comment.