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

dist: support smooth upgrade from enterprise to source availalbe #121

Merged
merged 1 commit into from
Jan 29, 2025

Conversation

syuu1228
Copy link
Contributor

When upgrading for example from 2024.1 to 2025.1 the package name is not identical casuing the upgrade command to fail.

This makes packages upgradable from enterprise.

Related scylladb/scylladb#22420

When upgrading for example from `2024.1` to `2025.1` the package name is
not identical casuing the upgrade command to fail.

This makes packages upgradable from enterprise.

Related scylladb/scylladb#22420

Signed-off-by: Takuya ASADA <syuu@scylladb.com>
Copy link
Collaborator

@fruch fruch left a comment

Choose a reason for hiding this comment

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

LGTM

@fruch
Copy link
Collaborator

fruch commented Jan 26, 2025

@syuu1228 @yaronkaikov

did we had this one tested anywhere ?

@yaronkaikov
Copy link
Contributor

@syuu1228 @yaronkaikov

did we had this one tested anywhere ?

I assume we will test it as part of scylladb/scylladb#22420

@@ -11,5 +11,14 @@ Architecture: any
Depends: %{product}-python3 (= ${binary:Version})
Conflicts: cassandra
Description: cqlsh is a Python-based command-line client for running CQL commands on a cassandra cluster.
Replaces: scylla-tools (<< 5.2~rc0)
Breaks: scylla-tools (<< 5.2~rc0)
Replaces: scylla-tools (<< 5.2~rc0), scylla-enterprise-cqlsh (<< 2025.1.0~)
Copy link
Collaborator

Choose a reason for hiding this comment

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

are we sure the ~ is enough to over all dev / rc versions ?

Copy link
Contributor

Choose a reason for hiding this comment

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

Nope, but since @syuu1228 did it, let's wait for him to confirm

Copy link
Contributor Author

Choose a reason for hiding this comment

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

(<< X.Y.Z~) is used on Debian wiki for example code,
https://wiki.debian.org/RenamingPackages
And the document says
https://www.debian.org/doc/debian-policy/ch-controlfields.html#special-version-conventions
debian_revision
This part of the version number specifies the version of the Debian package based on the upstream version. It must contain only alphanumerics and the characters + . ~ (plus, full stop, tilde) and is compared in the same way as the upstream_version is.

Also we can compare version number by dpkg --compare-versions:

$ dpkg --compare-versions 2025.1.0~dev-0.20250126.48349d4d7c67-1 gt 2025.1.0~; echo $?
0
~$ dpkg --compare-versions 2025.1.0~rc0-0.20250126.48349d4d7c67-1 gt 2025.1.0~; echo $?
0
$ dpkg --compare-versions 2025.1.0~rc1-0.20250126.48349d4d7c67-1 gt 2025.1.0~; echo $?
0
$ dpkg --compare-versions 2025.1.0~rc2-0.20250126.48349d4d7c67-1 gt 2025.1.0~; echo $?
0

So I guess it is fine.

@syuu1228
Copy link
Contributor Author

@syuu1228 @yaronkaikov

did we had this one tested anywhere ?

It only tested by manually for now.

@yaronkaikov
Copy link
Contributor

@fruch this part is working, i confirmed when testing it locally please merge this, i will update the submodule as part of my PR

@fruch
Copy link
Collaborator

fruch commented Jan 28, 2025

@fruch this part is working, i confirmed when testing it locally please merge this, i will update the submodule as part of my PR

did we tried the RPM based ?

@yaronkaikov
Copy link
Contributor

@fruch this part is working, i confirmed when testing it locally please merge this, i will update the submodule as part of my PR

did we tried the RPM based ?

no i will check it as well

@fruch fruch merged commit 5f0b0ca into scylladb:master Jan 29, 2025
8 checks passed
@yaronkaikov
Copy link
Contributor

@fruch we need to backport this to 2025.1 to support the upgrades. Can you please create branch-2025.1 and backport this?

@fruch
Copy link
Collaborator

fruch commented Feb 9, 2025

@fruch we need to backport this to 2025.1 to support the upgrades. Can you please create branch-2025.1 and backport this?

Isn't enough to backport the change to submodule ?

@yaronkaikov
Copy link
Contributor

@fruch yes, this is what we need to do, but the way to do it (or at least how things done in Scylla) is to create a branch and backport,

@fruch
Copy link
Collaborator

fruch commented Feb 9, 2025

@fruch yes, this is what we need to do, but the way to do it (or at least how things done in Scylla) is to create a branch and backport,

it's a bit silly

but there's now a new branch branch-2025.1 and you can take it from there

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 this pull request may close these issues.

3 participants