You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
semver template: update examples to use lower camel case
changes to the way we unmarshal meta blobs dictate that (at least the
meta) fields use lower camel case for their keys. This PR updates
examples and tests to use all lower camel case keys. Thankfully,
the demo gifs in the semver template README already use lower camel case
so there is no need to regenerate them.
Copy file name to clipboardExpand all lines: alpha/template/semver/README.md
+34-36Lines changed: 34 additions & 36 deletions
Original file line number
Diff line number
Diff line change
@@ -15,42 +15,42 @@ The `semver template` must have:
15
15
The resulting FBC must clearly indicate how generated channels relate to template entities
16
16
17
17
### Schema Anatomy
18
-
For convenience and simplicity, this template currently supports hard-coded channel names `Candidate`, `Fast`, and `Stable`, in order of increasing channel stability. We leverage this relationship to calculate the default channel for the package.
18
+
For convenience and simplicity, this template currently supports hard-coded channel names `candidate`, `fast`, and `stable`, in order of increasing channel stability. We leverage this relationship to calculate the default channel for the package.
19
19
20
-
`GenerateMajorChannels` and `GenerateMinorChannels` dictate whether this template will generate X-stream or Y-stream channels (attributes can be set independently). If omitted, only minor (Y-stream) channels will be generated.
20
+
`generateMajorChannels` and `generateMinorChannels` dictate whether this template will generate X-stream or Y-stream channels (attributes can be set independently). If omitted, only minor (Y-stream) channels will be generated.
21
21
22
22
Under each channel are a list of bundle image references which contribute to that channel.
23
23
24
24
With the following (hypothetical) example we define a mock bundle which has 11 versions, represented across each of the channel types:
25
25
```yaml
26
-
Schema: olm.semver
27
-
GenerateMajorChannels: true
28
-
GenerateMinorChannels: true
29
-
Candidate:
30
-
Bundles:
31
-
- Image: quay.io/foo/olm:testoperator.v0.1.0
32
-
- Image: quay.io/foo/olm:testoperator.v0.1.1
33
-
- Image: quay.io/foo/olm:testoperator.v0.1.2
34
-
- Image: quay.io/foo/olm:testoperator.v0.1.3
35
-
- Image: quay.io/foo/olm:testoperator.v0.2.0
36
-
- Image: quay.io/foo/olm:testoperator.v0.2.1
37
-
- Image: quay.io/foo/olm:testoperator.v0.2.2
38
-
- Image: quay.io/foo/olm:testoperator.v0.3.0
39
-
- Image: quay.io/foo/olm:testoperator.v1.0.0
40
-
- Image: quay.io/foo/olm:testoperator.v1.0.1
41
-
- Image: quay.io/foo/olm:testoperator.v1.1.0
42
-
Fast:
43
-
Bundles:
44
-
- Image: quay.io/foo/olm:testoperator.v0.2.1
45
-
- Image: quay.io/foo/olm:testoperator.v0.2.2
46
-
- Image: quay.io/foo/olm:testoperator.v0.3.0
47
-
- Image: quay.io/foo/olm:testoperator.v1.0.1
48
-
- Image: quay.io/foo/olm:testoperator.v1.1.0
49
-
Stable:
50
-
Bundles:
51
-
- Image: quay.io/foo/olm:testoperator.v1.0.1
26
+
schema: olm.semver
27
+
generateMajorChannels: true
28
+
generateMinorChannels: true
29
+
candidate:
30
+
bundles:
31
+
- image: quay.io/foo/olm:testoperator.v0.1.0
32
+
- image: quay.io/foo/olm:testoperator.v0.1.1
33
+
- image: quay.io/foo/olm:testoperator.v0.1.2
34
+
- image: quay.io/foo/olm:testoperator.v0.1.3
35
+
- image: quay.io/foo/olm:testoperator.v0.2.0
36
+
- image: quay.io/foo/olm:testoperator.v0.2.1
37
+
- image: quay.io/foo/olm:testoperator.v0.2.2
38
+
- image: quay.io/foo/olm:testoperator.v0.3.0
39
+
- image: quay.io/foo/olm:testoperator.v1.0.0
40
+
- image: quay.io/foo/olm:testoperator.v1.0.1
41
+
- image: quay.io/foo/olm:testoperator.v1.1.0
42
+
fast:
43
+
bundles:
44
+
- image: quay.io/foo/olm:testoperator.v0.2.1
45
+
- image: quay.io/foo/olm:testoperator.v0.2.2
46
+
- image: quay.io/foo/olm:testoperator.v0.3.0
47
+
- image: quay.io/foo/olm:testoperator.v1.0.1
48
+
- image: quay.io/foo/olm:testoperator.v1.1.0
49
+
stable:
50
+
bundles:
51
+
- image: quay.io/foo/olm:testoperator.v1.0.1
52
52
```
53
-
In this example, `Candidate` has the entire version range of bundles, `Fast` has a mix of older and more-recent versions, and `Stable` channel only has a single published entry.
53
+
In this example, `candidate` has the entire version range of bundles, `fast` has a mix of older and more-recent versions, and `stable` channel only has a single published entry.
54
54
55
55
### CLI Tool Usage
56
56
```
@@ -85,7 +85,7 @@ Note that if the command is called without a file argument and nothing passed in
85
85
the command will hang indefinitely. Either a file argument or file information passed
86
86
in on standard input is required by the command.
87
87
88
-
With the template attribute `GenerateMajorChannels: true` resulting major channels from the command are (filtering out `olm.bundle` content):
88
+
With the template attribute `generateMajorChannels: true` resulting major channels from the command are (filtering out `olm.bundle` content):
89
89
```yaml
90
90
---
91
91
defaultChannel: stable-v1
@@ -165,10 +165,10 @@ package: testoperator
165
165
schema: olm.channel
166
166
```
167
167
168
-
We generated a channel for each template channel entity corresponding to each of the 0.\#.\#, 1.\#.\# major version ranges with skips to the head of the highest semver in a channel. We also generated a replaces edge to traverse across minor version transitions within each major channel. Finally, we generated an `olm.package` object, setting as default the most-stable channel head we created. This process will prefer `Stable` channel over `Fast`, over `Candidate` and then a higher bundle version over a lower version.
168
+
We generated a channel for each template channel entity corresponding to each of the 0.\#.\#, 1.\#.\# major version ranges with skips to the head of the highest semver in a channel. We also generated a replaces edge to traverse across minor version transitions within each major channel. Finally, we generated an `olm.package` object, setting as default the most-stable channel head we created. This process will prefer `stable` channel over `fast`, over `candidate` and then a higher bundle version over a lower version.
169
169
(Please note that the naming of the generated channels indicates the digits of significance for that channel. For example, `fast-v1` is a decomposed channel of the `fast` type which contains only major versions of contributing bundles matching `v1`.)
170
170
171
-
For contrast, with the template attribute `GenerateMinorChannels: true` and running the command again (again skipping rendered bundle image output) we get a bunch more channels:
171
+
For contrast, with the template attribute `generateMinorChannels: true` and running the command again (again skipping rendered bundle image output) we get a bunch more channels:
172
172
```yaml
173
173
---
174
174
defaultChannel: stable-v1.0
@@ -278,9 +278,7 @@ Here, a channel is generated for each template channel which differs by minor ve
0 commit comments