Skip to content
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

Enabled overrides for worker and coordinator configmap resources #163

Closed
wants to merge 6 commits into from

Conversation

silent-lad
Copy link

This is to install multiple helm releases of trino cluster in the same namespace.
Closes #159 .

Copy link

cla-bot bot commented May 14, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

@nineinchnick
Copy link
Member

Would be nice to have a test for this, maybe a second call to ct install in https://github.com/trinodb/charts/blob/main/.github/workflows/ci-cd.yaml#L44

@@ -132,7 +132,7 @@ data:
apiVersion: v1
kind: ConfigMap
metadata:
name: trino-access-control-volume-coordinator
name: {{ template "trino.coordinator" . }}-access-control-volume-coordinator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could we eliminate suffix -coordinator?
since in the template already has it, similar to other confimap objects

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since in the template already has it, similar to other confimap objects

I thought of it. The problem with it would be that in case someone doesn't overrides the name the default name only say "trino" which will cause duplicate configmap issues.

@nineinchnick
Copy link
Member

@silent-lad I recently added a test.sh script that runs multiple tests. Can you update it to add a new test for deploying multiple releases into a single namespace? If you'd use ct install, you'd have to disable cleanup when calling it. test.sh already creates and cleans up a custom namespace.

@silent-lad
Copy link
Author

Hey @nineinchnick , will do the same. Thanks for the heads up

Copy link

cla-bot bot commented May 23, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

Copy link

cla-bot bot commented May 23, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

@silent-lad
Copy link
Author

@silent-lad I recently added a test.sh script that runs multiple tests. Can you update it to add a new test for deploying multiple releases into a single namespace? If you'd use ct install, you'd have to disable cleanup when calling it. test.sh already creates and cleans up a custom namespace.

This is done now.

Copy link
Member

@nineinchnick nineinchnick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great! My only ask is if you could add coordinatorNameOverride and workerNameOverride to values.yaml with empty defaults, but with a comment describing when to use them.

test.sh Outdated
time ct install "${CT_ARGS[@]}" --helm-extra-set-args "$HELM_EXTRA_SET_ARGS ${testCases[$test_name]}"
echo "${testCases[$test_name]}"
if [ "$test_name" == "multiple_clusters" ]; then
time ct install "${CT_ARGS[@]}" --helm-extra-set-args "$HELM_EXTRA_SET_ARGS ${testCases[default]}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we also need --skip-clean-up added for ct install.

test.sh Outdated Show resolved Hide resolved
Co-authored-by: Jan Waś <jan@was.net.pl>
Copy link

cla-bot bot commented May 23, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

Copy link

cla-bot bot commented May 23, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

Copy link

cla-bot bot commented May 24, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

@silent-lad
Copy link
Author

Have pushed the required changes @nineinchnick

Comment on lines +5 to +10
# If you want to have multiple Trino Clusters in same namespace
# override the following values to avoid naming conflicts
# Example:
# coordinatorNameOverride: trino-adhoc
# workerNameOverride: trino-adhoc
# nameOverride: trino-adhoc
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# If you want to have multiple Trino Clusters in same namespace
# override the following values to avoid naming conflicts
# Example:
# coordinatorNameOverride: trino-adhoc
# workerNameOverride: trino-adhoc
# nameOverride: trino-adhoc
# -- Override resource names to avoid name conflicts when deploying multiple
# releases in the same namespace.
# @raw
# Example:
# ```yaml
# coordinatorNameOverride: trino-adhoc
# workerNameOverride: trino-adhoc
# nameOverride: trino-adhoc
# ```
nameOverride:
coordinatorNameOverride:
workerNameOverride:

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will also require update to README.md, but it should be automatically generated by the pre-commit hook, if you've installed it locally.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also fix trailing spaces, see the CI errors for details.

@@ -133,7 +133,7 @@ data:
apiVersion: v1
kind: ConfigMap
metadata:
name: trino-access-control-volume-coordinator
name: {{ template "trino.coordinator" . }}-access-control-volume-coordinator
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about using trino.fullname instead of trino.coordinator?

@nineinchnick
Copy link
Member

@cla-bot check

Copy link

cla-bot bot commented May 30, 2024

Thank you for your pull request and welcome to the Trino community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. Continue to work with us on the review and improvements in this PR, and submit the signed CLA to cla@trino.io. Photos, scans, or digitally-signed PDF files are all suitable. Processing may take a few days. The CLA needs to be on file before we merge your changes. For more information, see https://github.com/trinodb/cla

Copy link

cla-bot bot commented May 30, 2024

The cla-bot has been summoned, and re-checked this pull request!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Cannot deploy multiple trino clusters in the same k8s namespace
3 participants