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

Package manager should have an upgrade framework #550

Open
isc-kiyer opened this issue Aug 22, 2024 · 4 comments
Open

Package manager should have an upgrade framework #550

isc-kiyer opened this issue Aug 22, 2024 · 4 comments
Labels
enhancement New feature or request
Milestone

Comments

@isc-kiyer
Copy link
Collaborator

If a package is already installed and needs to be upgraded, the package should be able to indicate upgrade steps to be run between any source and target versions.
The package manager should have separate commands for upgrading a package vs fresh install with the ability to intentionally override and do a fresh install (bypassing upgrade steps) if they want (for example in a dev environment).

@isc-kiyer isc-kiyer added the enhancement New feature or request label Aug 22, 2024
@isc-shuliu
Copy link
Collaborator

@isc-kiyer What are some of the differences to consider between upgrades and fresh new installs?

I can think of only 1 case where the package developer renames some classes and we need to migrate the associated data (like with %ZPM -> %IPM).

Are there any more things to look out for?

@isc-tleavitt
Copy link
Contributor

@isc-shuliu the primary motivation is data migration/schema change steps, which don't necessarily correspond to a class rename. New indices would be another use case. Really, it's all around data.

HealthShare has some more specific use cases / constraints (along with plenty of examples) and I'd recommend that you and @isc-kiyer or @isc-eneil meet to discuss them.

@isc-shuliu
Copy link
Collaborator

@isc-tleavitt
After discussion with the HSOPS team, IPM will provide an abstract class for upgrades. Package developers are responsible for subclassing it to implement their own upgrade logic for every earlier version.

Each upgrade could contain many methods (tasks), even if just bumping up one version number, so that users can see which tasks are successful.

IPM will figure out the correct order to run the methods as part of the installation process. We still need to figure out which conventions to use. This GitHub issue page can be used for discussion.

@isc-shuliu
Copy link
Collaborator

Internal reference: HS.Util.Installer.Upgrade.Loader & HS.Util.Installer.Upgrade.ModuleAbstract

@isc-tleavitt isc-tleavitt added this to the Backlog milestone Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: To do
Development

No branches or pull requests

3 participants