-
Notifications
You must be signed in to change notification settings - Fork 15
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
Some random citus_dev improvements #352
Conversation
JelteF
commented
Feb 23, 2024
•
edited
Loading
edited
- citus_dev: pass arguments directly to createNodeCommands
- Don't fsync by default
- Remove trailing whitespace
- Add editorconfig
- Add some basic gitignore stuff for citus_dev
- Add --no-lib flag to not load citus shared library
- Configure port in the config file instead of pg_ctl
- Configure logging the config file instead of pg_ctl
- remove nightlies for EOL distros
ef6e74d
to
5e01b32
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looking good, lets make sure before merging @gurkanindibay is ok with us removing old distributions. I don't know in what manner the tools repo is used for packaging/building/testing anymore.
- el/7 | ||
- el/8 | ||
- ol/7 | ||
- debian/buster | ||
- debian/bullseye | ||
- debian/bookworm | ||
- ubuntu/bionic | ||
- ubuntu/focal | ||
- ubuntu/jammy | ||
- ubuntu/kinetic |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@gurkanindibay could you double check these changes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can remove ubuntu/kinetic however, we can not remove other ones. We still support el/7 and ol/7
citus_dev/citus_dev
Outdated
if arguments['--no-lib']: | ||
shared_preload_libraries = ['pg_stat_statements'] | ||
else: | ||
shared_preload_libraries = ['citus', 'pg_stat_statements'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This works for now, but it becomes more cumbersome if we need more preload libraries in the future.
if arguments['--no-lib']: | |
shared_preload_libraries = ['pg_stat_statements'] | |
else: | |
shared_preload_libraries = ['citus', 'pg_stat_statements'] | |
shared_preload_libraries = ['pg_stat_statements'] | |
# double negation, what does it mean? | |
# we do add citus if we do _not_ provide the `--no-lib` flag | |
# because citus needs to be at the beginning of the list we perform this check last, and insert `citus` at index 0, which is the beginning of the list | |
if not arguments['--no-lib']: | |
shared_preload_libraries.insert(0, 'citus') |
citus_dev/citus_dev
Outdated
@@ -188,7 +201,7 @@ def main(arguments): | |||
clustername = arguments["<name>"] | |||
port = int(arguments["--port"]) | |||
for role in getRoles(clustername): | |||
run(f'pg_ctl {pgctl_flags} start -D {clustername}/{role} -o "-p {port}" -l {role}_logfile') | |||
run(f'pg_ctl {pgctl_flags} start -D {clustername}/{role} -o "-p {port}"') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can the port be removed if we have it in the config now?
possibly we would also need to remove the flag from start/restart, given it's a property of the cluster now, not a runtime argument.
citus_dev/citus_dev
Outdated
@@ -2,7 +2,7 @@ | |||
"""citus_dev | |||
|
|||
Usage: | |||
citus_dev make <name> [--size=<count>] [--port=<port>] [--use-ssl] [--no-extension] [--destroy] [--init-with=<sql_file>] [--init-worker-with=<sql_file>] [--with-pgbouncer] | |||
citus_dev make <name> [--size=<count>] [--port=<port>] [--use-ssl] [--no-extension] [--no-lib] [--destroy] [--init-with=<sql_file>] [--init-worker-with=<sql_file>] [--with-pgbouncer] [--fsync] | |||
citus_dev restart <name> [--watch] [--port=<port>] | |||
citus_dev (start|stop) <name> [--port=<port>] [--force] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Guess --port
can be removed here
5e01b32
to
55e7f3a
Compare
55e7f3a
to
9e927cf
Compare
9e927cf
to
e91bcb9
Compare
They were failing
e91bcb9
to
6919d3f
Compare