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

[stable29] Migration Attributes #46889

Merged
merged 2 commits into from
Aug 8, 2024
Merged

Conversation

backportbot[bot]
Copy link

@backportbot backportbot bot commented Jul 30, 2024

Backport of #46476+#47069

This is a light backport of the Migration Attributes + Metadata Manager adding the features to:

  • download metadata from download server,
  • convert them to Attributes and uses the description() method to obtain human readable content,
  • add the migrations:preview occ command to display future migrations

The backport removes the part of creating metadata based on local content, as it is useless for NC29, and not compat for php 8.0

@backportbot backportbot bot added enhancement 3. to review Waiting for reviews feature: occ pending documentation This pull request needs an associated documentation update 🍂 2024-Autumn labels Jul 30, 2024
@backportbot backportbot bot added this to the Nextcloud 29.0.5 milestone Jul 30, 2024
@ChristophWurst
Copy link
Member

This PR adds a new API. Are you sure this will be backported?

@AndyScherzinger
Copy link
Member

Discussion/Decision has been to have it backported to v29, so people can "experience" the new feature when updating to v30 - given that we judge this change to be low/no risk. Thus adding @sorbaugh to clarify/ensure this.

@skjnldsv
Copy link
Member

skjnldsv commented Aug 1, 2024

Discussion/Decision has been to have it backported to v29, so people can "experience" the new feature when updating to v30 - given that we judge this change to be low/no risk

As always, features = minor.
Backporting features is an antipattern, which would be safe to avoid.

@nickvergessen
Copy link
Member

Maybe we can wait until it was tested a couple of times during the 30 beta/rc updates?

@AndyScherzinger
Copy link
Member

Maybe we can wait until it was tested a couple of times during the 30 beta/rc updates?

During the betas sure, maybe RC1 / RC2 max, else there isn't enough time to actually get feedback for it.

@nickvergessen
Copy link
Member

well the updates within the 30 beta X to beta X+1 also use this right? not only the updates from 29 to 30

@AndyScherzinger
Copy link
Member

well the updates within the 30 beta X to beta X+1 also use this right? not only the updates from 29 to 30

Yes. My point is rather when we consider it "the last point in time we are (relatively) fine with merging it", hence I do not want to wait until the very last minute before that v29 package is build and released but also respect v29 release timelines.

@ArtificialOwl ArtificialOwl force-pushed the backport/46476/stable29 branch from 20cd7aa to e027825 Compare August 2, 2024 01:35
Copy link

@github-advanced-security github-advanced-security bot left a comment

Choose a reason for hiding this comment

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

Psalm found more than 20 potential problems in the proposed changes. Check the Files changed tab for more details.

@ArtificialOwl ArtificialOwl force-pushed the backport/46476/stable29 branch from e027825 to 7b67067 Compare August 2, 2024 01:47
@ArtificialOwl ArtificialOwl force-pushed the backport/46476/stable29 branch from a329ce1 to f3ac8ad Compare August 2, 2024 02:49
@ArtificialOwl
Copy link
Member

  • only the part to parse metadata files is kept available from the API and occ command
  • to stay compatible with php 8.0, enums IndexType and ColumnType are removed, and will just be ignored when deserializing Migrations Attributes from metadata files

@ArtificialOwl ArtificialOwl marked this pull request as ready for review August 6, 2024 12:02
@ArtificialOwl
Copy link
Member

result when used with current nc30beta3 metadata
image

@AndyScherzinger
Copy link
Member

@ArtificialOwl beyond testing if the occ command works, did (and if not can) you test that the 29+PR upgraded to 30-master (with above annotated migrations) still runs through smoothly? That would be a pre-requisite in terms of test-set that should be checked before merging this PR.

Copy link
Member

@juliusknorr juliusknorr left a comment

Choose a reason for hiding this comment

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

Looks good with one question.

Also please update the issue description to reflect the current state of the partial backport. Currently it looks like there is still work to do but the diff seems fine

lib/private/Migration/MetadataManager.php Show resolved Hide resolved
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
@ArtificialOwl ArtificialOwl force-pushed the backport/46476/stable29 branch from f3ac8ad to 825be0a Compare August 6, 2024 23:57
@ArtificialOwl
Copy link
Member

I have updated the description of the PR

@ArtificialOwl
Copy link
Member

@ArtificialOwl beyond testing if the occ command works, did (and if not can) you test that the 29+PR upgraded to 30-master (with above annotated migrations) still runs through smoothly? That would be a pre-requisite in terms of test-set that should be checked before merging this PR.

i will test 29.0.4+PR with an upgrade to 30.0.0beta5 after its release at the end of this week. (But I see no reason for a fail)

@AndyScherzinger
Copy link
Member

Thanks a lot @ArtificialOwl 👍👍👍

@Altahrim Altahrim mentioned this pull request Aug 8, 2024
9 tasks
@AndyScherzinger
Copy link
Member

Testing has been reported as being successful upgrading 29+this-pr to v30-pre-releases

@AndyScherzinger AndyScherzinger merged commit 598d501 into stable29 Aug 8, 2024
173 of 177 checks passed
@AndyScherzinger AndyScherzinger deleted the backport/46476/stable29 branch August 8, 2024 11:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews enhancement feature: install and update feature: occ pending documentation This pull request needs an associated documentation update 🍂 2024-Autumn
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants