operator-framework / olm-docs

Hugo doc site for https://github.com/operator-framework/operator-lifecycle-manager
10 stars 82 forks source link

Clarify replaces chain requirement for building channels #223

Open joelanford opened 2 years ago

joelanford commented 2 years ago

Originally posted by @amisevsk in https://github.com/operator-framework/operator-registry/issues/822#issuecomment-1018687671

The entry specifying the skipRange will be presented as a direct (one hop) update to any version from that package within that range. The versions in this range do not need to be in the catalog in order for bundle addition to be successful.

(i.e. "but could be" -- nothing is mentioned about still requiring a linear replaces chain)

It would be useful if the documentation mentioned that replaces is still required with skipRange when there is more than one version. Compare this to the example used for the "Skips" section, which includes the replaces field even though the catalog does not contain myoperator.v1.0.0:

  - name: myoperator.v1.0.3
    replaces: myoperator.v1.0.0
    skips:
      - myoperator.v1.0.1
      - myoperator.v1.0.2

Perhaps the "SkipRange" example should be

  - name: myoperator.v1.0.3
    replaces: myoperator.v1.0.0
    skipRange: ">=1.0.0 <1.0.3"

to match.

@joelanford 's response

Thanks for re-iterating the gaps in the documentation. I agree.

I think we need to add something to that doc (perhaps at the top, outside of the Replaces, Skips and SkipRange sections), that states:

  1. There must be exactly one linear acyclic replaces chain
  2. All entries in the channel must either: a) be reachable from the channel head via the replaces chain, OR b) be one-hop via a skip edge from an entry on the replaces chain.