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

Remove Mysql5.7 support / remove Mysql5.7 from PR validation #3949

Open
kathap opened this issue Sep 3, 2024 · 1 comment · May be fixed by #4018
Open

Remove Mysql5.7 support / remove Mysql5.7 from PR validation #3949

kathap opened this issue Sep 3, 2024 · 1 comment · May be fixed by #4018

Comments

@kathap
Copy link
Contributor

kathap commented Sep 3, 2024

Mysql5.7 is not supported any more, remove support for Mysql5.7

[email protected] is not supported any more upstream and also not in cf-deployment. PR validation could be sped up by removing the checks for MySQL5.7. Extra lines in migrations, that are needed to be compliant with Mysql5.7, would not be necessary (e.g. removing unique constraint in MySQL 5.7 does not include removing the corresponding index, in higher versions it does).

Steps to Reproduce

Write a migration to drop a unique constraint, like

Sequel.migration do
  up do
    if self.class.name.match?(/mysql/i)
      alter_table :quota_definitions do
        drop_constraint :name, if_exists: true
      end
    elsif self.class.name.match?(/postgres/i)
      alter_table :quota_definitions do
        drop_constraint :quota_definitions_name_key, if_exists: true
      end
    end
  end

  down do
    if self.class.name.match?(/mysql/i)
      alter_table :quota_definitions do
        add_unique_constraint :name, name: :name, if_not_exists: true
      end
    elsif self.class.name.match?(/postgres/i)
      alter_table :quota_definitions do
        add_unique_constraint :name, name: :quota_definitions_name_key, if_not_exists: true
      end
    end
  end
end

and open a PR. It will fail with Mysql2::Error: Duplicate key name 'name' for MySQL5.7.

Expected result

PR validation runs without check for MySQL5.7, same for Backwards Compatibility Unit Tests.

Current result

Migrations and migration specs need to be compliant for MySQL5.7

Possible Fix

Remove support for MySQL5.7 and the MySQL5.7 PR validation checks.

@Gerg
Copy link
Member

Gerg commented Sep 3, 2024

It's worth noting that some MySQL vendors still offer extended support for 5.7, notably Amazon RDS (until at least 2025).

I'm not saying we couldn't drop testing for it, but EoL for upstream MySQL doesn't necessarily mean that people can't get an in-support version of it.

stephanme added a commit that referenced this issue Oct 11, 2024
@stephanme stephanme linked a pull request Oct 11, 2024 that will close this issue
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants