8000 Implement support for running benchmarks with perf by alexanderlaw · Pull Request #5 · postgrespro/pg-mark · GitHub
[go: up one dir, main page]

Skip to content

Implement support for running benchmarks with perf #5 8000

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 7, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Use f-strings consistently in prepare-instances.py
  • Loading branch information
alexanderlaw committed Jul 6, 2023
commit e2f474f598fd0440c4547f6df636042f494e35b5
18 changes: 9 additions & 9 deletions prepare-instances.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,11 +143,11 @@ def get_repo_url(instance):
dockerfile.write(df_contents)

if instance.get('pg_version') is not None:
build_args += ['--build-arg', ('PG_VERSION=' +
instance.get('pg_version'))]
build_args += ['--build-arg',
(f'PG_VERSION={instance.get("pg_version")}')]
if instance.get('pgpro_edition') is not None:
build_args += ['--build-arg', ('PGPRO_EDN=' +
instance.get('pgpro_edition'))]
build_args += ['--build-arg',
(f'PGPRO_EDN={instance.get("pgpro_edition")}')]
pg_params = ''
for param in instance.findall('config/pg_param'):
pg_params += f"{param.get('name')} = '{param.get('value')}'\\n"
Expand All @@ -157,15 +157,15 @@ def get_repo_url(instance):

repo_url = get_repo_url(instance)
if repo_url is not None:
build_args += ['--build-arg', ('REPOSITORY=' + repo_url)]
build_args += ['--build-arg', (f'REPOSITORY={repo_url}')]

extra = instance.find('extra')
if extra is not None:
if extra.find('source') is not None and \
extra.find('source').get('type') == 'git':
extra_git_url = extra.find('source').get('url')
build_args += ['--build-arg', ('EXTRA_SRC_GIT=' +
extra_git_url)]
build_args += ['--build-arg',
(f'EXTRA_SRC_GIT={extra_git_url}')]
pg_modules = ''
for pgm in extra.findall('pg_module'):
pg_modules += (',' if pg_modules else '') + pgm.get('name')
Expand All @@ -182,8 +182,8 @@ def get_repo_url(instance):
phase2_action = instance.find('os').get('phase2_action')
if instance.find('os').get('extra_packages') is not None:
extra_os_packages = instance.find('os').get('extra_packages')
build_args += ['--build-arg', ('PHASE1_ACTION=' + phase1_action)]
build_args += ['--build-arg', ('PHASE2_ACTION=' + phase2_action)]
build_args += ['--build-arg', (f'PHASE1_ACTION={phase1_action}')]
build_args += ['--build-arg', (f'PHASE2_ACTION={phase2_action}')]
build_args += ['--build-arg',
(f'EXTRA_OS_PACKAGES="{extra_os_packages}"')]

Expand Down
0