Skip to content

Align Resource Group Tables with Trino v476 #713

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

yardenc2003
Copy link

@yardenc2003 yardenc2003 commented Jun 26, 2025

Description

This PR updates the resource groups–related tables to match the schemas used by Trino (v476).

Additional context and related issues

Since version 14, automatic database migrations have been enabled in the gateway (I believe in this PR).
This causes conflicts (different Flyway migration checksums) with the automatic migrations triggered during Trino’s startup. As a result, when sharing the database between the gateway and one or more Trino instances, migration immediately fails.

If we decide to enable only the gateway migrations, we must ensure the schemas match Trino’s. Otherwise, it fails due to missing columns. This PR addresses that schema alignment.

Refers this issue.

a Few Disclaimers

  • I believe we need to disable one of the migrations (either Trino's or the gateway's) or at least document this. Currently, it does not work with the default configuration if resource groups are enabled and Trino shares the database with the gateway.
  • I have not verified compatibility with older Trino versions that haven’t updated their schemas while the gateway has, only with v476 for the different db implementations.
  • I had to reduce the maximum length of the environment column in exact_match_source_selectors in Oracle to match Trino’s schema. This change might be unsafe and prone to failures.
  • I have not updated either the UI forms for resource groups/selectors creation or the underlying SQL statements (DAO classes). I wasn’t sure if this effort was worthwhile, given that this feature is about to be removed from the gateway and the existing implementation has issues updating via the UI.

Release notes

( ) This is not user-visible or is docs only, and no release notes are required.
(X) Release notes are required. Please propose a release note for me.
( ) Release notes are required, with the following suggested text.

@cla-bot cla-bot bot added the cla-signed label Jun 26, 2025
@RoeyoOgen RoeyoOgen requested review from posulliv and mosabua June 27, 2025 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

1 participant