Skip to content

[Discuss] Support providing hints for breaking changes #817

Open

Description

@jsoriano

There are situations where breaking changes may be unavoidable. Currently packages can indicate this in changelogs and/or bumping their major versions, but from a user perspective upgrading to versions with breaking changes looks the same as any other upgrade. After the upgrade they may be missing fields or having other kinds of issues.

It should be possible to include hints in packages to handle breaking changes. There can be two kinds of hints:

  • Hints for Fleet, in case it can do anything during the upgrade.
  • Hints for users, in case they need to be aware of some change or perform some manual action.

These hints should help with the migration path to versions with breaking changes.

There are some places where the hints could appear:

  • In breaking change notes in the changelog, a new field could be added with additional information. We should ensure that breaking changes are displayed to users in the UI when upgrading ([Fleet] Detect breaking changes in integration change logs and flag them to users during integration upgrades kibana#187481), and if possible also in API responses.
  • In field definitions, we could keep definitions of removed fields, along with additional information to indicate if it was completely removed, moved or whatsoever.
  • In READMEs we could also add some notes, but this can be difficult to enforce and users may not read it.

We should also assess frequent reasons for breaking changes.

Try to find opportunities to improve the situation here.

Related issues

Activity

  1. Oddly commented on Feb 5, 2025

    @Oddly

    Not sure if this is the right place, but deprecation hints when using elastic-package to build packages would be very welcome for those of us who build our own packages.

  2. jlind23 commented on Feb 18, 2025

    @jlind23
    Contributor

    @kpollich @jamiehynds @nimarezainia instead of over engineering this could we imagine an easy solution which would be to display a pop up warning the users whenever there is major version bumped in the package ready to be installed? This would avoid us to implement any flags or any logic in the package spec itself. Any thoughts?

  3. kpollich commented on Feb 19, 2025

    @kpollich
    Member

    Do we enforce a major version bump in the integration's version when its targeted stack/Kibana version is bumped by a major? I think this could be a simple way to get some of this behavior, but I don't know that we have any kind of enforcement on package maintainers that would guarantee we trigger the pop-up when it's intended.

  4. ebeahan commented on Feb 19, 2025

    @ebeahan
    Member

    I don't know that we have any kind of enforcement on package maintainers that would guarantee we trigger the pop-up when it's intended.

    The changelog spec includes a breaking-change type maintainers should use for any breaking changes.

    Maybe the upgrade banner includes a warning if a newer changelog entry contains a breaking-change?

    Image
  5. kpollich commented on Feb 25, 2025

    @kpollich
    Member

    I think Eric's suggestion is the best path forward here. We can detect when the upgrade from current version to latest version includes a breaking change by parsing the changelog.yml. Then we can display a warning in this upgrade callout + the breaking change description as it appears in changelog.yml.

  6. jamiehynds commented on Mar 18, 2025

    @jamiehynds

    Could we take this a step further by not only providing a hint about a breaking change but also requiring users to acknowledge it before proceeding with an update? The need for acknowledgment could be based on the severity of the change, as determined by PM and engineering.

    For example, in this case, it would be beneficial to clearly inform users about the impact of the breaking change and require explicit acknowledgment before they update. This approach ensures users are fully aware of the implications and prevents any unexpected disruptions.

  7. jsoriano commented on Mar 18, 2025

    @jsoriano
    ContributorAuthor

    Could we take this a step further by not only providing a hint about a breaking change but also requiring users to acknowledge it before proceeding with an update?

    Something like this is proposed in this linked issue: elastic/kibana#187481

  8. kpollich commented on Mar 25, 2025

    @kpollich
    Member

    Moving this out of our iteration and will flesh out elastic/kibana#187481 with some UX mockups to make it actionable.

  9. efd6 commented on May 11, 2025

    @efd6
    Contributor

    An issue exists with the changes.type field in that it makes the implicit claim that breaking-change is orthogonal to both bugfix and enhancement since only one of the three possible options can be used in any given change, but this is not the case; a breaking change is necessarily either a bugfix or an enhancement, so it should be the case that you can set both. Ideally, it would have been a separate boolean field but that horse has already bolted, so it would be good if the type could be relaxed to support an array of string so that they could be treated as tags.

  10. jsoriano commented on May 13, 2025

    @jsoriano
    ContributorAuthor

    I remember someone [maybe you? 🤔] suggested once the introduction of a new type like breaking-bugfix, that would be both a bugfix and a breaking change. breaking-change would be used then for other changes, like enhancements, that are also breaking changes.

  11. efd6 commented on May 13, 2025

    @efd6
    Contributor

    I don't think that was me. It would work, but it seems like a hack to work around the the type system here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Team:EcosystemLabel for the Packages Ecosystem team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions