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

RFC: app/compose: Add --legacy to start deprecation process #1739

Closed
wants to merge 1 commit into from

Conversation

jlebon
Copy link
Member

@jlebon jlebon commented Jan 23, 2019

First, start printing the current mode we're operating in. This will
make it clear from the output if the default changes. Second, add a new
--legacy switch that users can use today to explicit opt into the
current default. And third, start emitting a warning if neither
--legacy nor --unified-core is given.

The way I'm thinking we can do this is (timespans flexible of course):

  • next 6 months: print warning unless mode is explicitly chosen
  • following 6 months: change default, print deprecation warning if
    --legacy is given
  • afterwards: remove --legacy, gradually clean up code, and profit

First, start printing the current mode we're operating in. This will
make it clear from the output if the default changes. Second, add a new
`--legacy` switch that users can use today to explicit opt into the
current default. And third, start emitting a warning if neither
`--legacy` nor `--unified-core` is given.

The way I'm thinking we can do this is (timespans flexible of course):
- next 6 months: print warning unless mode is explicitly chosen
- following 6 months: change default, print deprecation warning if
  `--legacy` is given
- afterwards: remove `--legacy`, gradually clean up code, and profit
opt_unified_core ? "unified core" : "legacy");

if (!opt_print_only && !opt_unified_core && !opt_legacy)
g_printerr ("%swarning: In the future, the default compose mode will be --unified-mode. The legacy mode will be deprecated but available behind --legacy for some time. Use one of the two switches above to squash this warning.%s\n", get_bold_start (), get_bold_end ());
Copy link
Member Author

Choose a reason for hiding this comment

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

We should probably throw a link in there with more details about the difference between the two.

@cgwalters
Copy link
Member

We talked about this in person, just want to record things here. One thing I want to avoid is breaking the community of people using rpm-ostree with CentOS 7. We have landed various fixes in Fedora for unified core that aren't necessarily in C7 yet.

We can probably get away with the fact that the rpm-ostree builds for CentOS7 aren't being updated, and tell anyone who wants to target C7 to use a C7 container on the source side too.

Let's file an issue about this (copy the PR text mostly) and link to it like we do the /opt one.

I'd also say we add a sleep(10) or something to increase the chance the warning is seen (and be annoying).

Also before we do this we should submit a patch to https://pagure.io/pungi/

Big picture though I think you're right that we need to start this process, and deleting the old code is going to be great!

@cgwalters
Copy link
Member

Also I think a blocker here is verifying Silverblue builds in unified-core mode reliably. Last time I tried it I had to make a few fixes.

@jlebon
Copy link
Member Author

jlebon commented Mar 13, 2019

Also I think a blocker here is verifying Silverblue builds in unified-core mode reliably. Last time I tried it I had to make a few fixes.

OK, I split that into https://pagure.io/workstation-ostree-config/issue/137. Can you add some details there if you have them handy on some of the issues you hit?

cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Mar 21, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Mar 22, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Mar 26, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Mar 26, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Mar 26, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Apr 15, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Apr 28, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request May 9, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
cgwalters added a commit to cgwalters/rpm-ostree that referenced this pull request Jun 7, 2019
We still accept the `--unified-core` option, it just does
nothing.

We're talking about making 2019.2 the last release to support
RHEL7.  That makes it also a good cutover point to just drop
the non-unified-core codepath.

Since coreos-assembler defaults to it, we know it works.
I also tested Silverblue with it.

Alternative to coreos#1739
@cgwalters
Copy link
Member

I think we should do #1793 instead - we already have the deprecation warning if they aren't specifying --unified-core. And IMO rpm-ostree compose tree is something you end up wrapping in higher level build logic - so carrying forward --unified-core there is a very small price to pay.

@cgwalters cgwalters closed this Sep 24, 2020
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.

2 participants