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
Copy file name to clipboardExpand all lines: documentation/directory-structure.md
+21-16Lines changed: 21 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,34 +50,30 @@ A `service` **must version uniformly**. This means that the service,
50
50
all its dependencies, and all artifacts generated from the service,
51
51
**must** have the same version.
52
52
53
-
In practice, this means, for an example service with version `2024-03-25`:
53
+
In practice this means, for an example service with version `2024-03-25`:
54
54
55
55
- All the OpenAPI specification `.json` files the service is composed of must have the same version of `2024-03-25`.
56
-
- All the shared specifications (i.e. `common-types`) the service depends on must have the same version.
56
+
- All the shared specifications (i.e. `common-types`) the service depends on must have the same version,
57
+
[e.g. `v6`][common-types v6] (but it can be different from the version of the service).
57
58
- In case of ARM service, all the resource types must have the same version of `2024-03-25`.
58
59
- The language SDKs generated from the service must have the same version of `2024-03-25`.
59
60
- The documentation published for the service must have the same version of `2024-03-25`.
60
61
- Update to any version of the above requires update of all the other versions.
61
-
For example, if `common-types` published an updated version of `2024-04-17`,
62
+
For example, if `common-types` published an updated version of `v7`,
62
63
then if the service wants to take dependency on it, it can only do it in
63
-
a new version of`2024-04-17`.
64
+
a new version. For example,`2024-04-17`.
64
65
Because the service version is now `2024-04-17`, all the OpenAPI specification `.json` files the service is composed
65
-
of must have the same version of `2024-04-17`.
66
+
of must have the same version of `2024-04-17` and the `info.version` property must say `2024-04-17`.
66
67
In addition, a new SDK must be generated from the service, and new documentation published, both tagged with
67
68
version `2024-04-17`.
68
69
- As a consequence of the above, if given service version uses `-preview` version anywhere, then the service
69
70
version itself must be `-preview`, it can depend **only** on `-preview` versions, and the generated SDK
70
71
and published docs must denote they are in `preview` too.
71
72
72
-
TODO:
73
-
- These rules seem too strict. What if cadence of releasing `common-types` does not align with cadence of releasing
74
-
given service? Same for resource types?
75
-
- For example, service got released on `2024-01-01`, then new `common-types` got released on `2024-02-01` and on
76
-
`2024-03-01` new service version is to be released? Can a `2024-03-01` service version depend on `2024-02-01``common-types`?
77
-
- If a service version can depend on `common-types` of a different version, can the generated SDK also depend
78
-
on different `.json` versions?
79
-
See e.g. [this bad setup of compute rm 2024-03-01](https://github.com/Azure/azure-rest-api-specs/blob/main/specification/compute/resource-manager/readme.md#tag-package-2024-03-01).
80
-
Could we make package `2024-03-01` depend on, say, `common-types` of `2024-02-01` and all other `.json` files of, say, `2024-02-15` ?
73
+
TODO:
74
+
- Per the rules above, a service and everything related must have exactly the same version, with the singular exception
75
+
of `common-types`, which use different versioning scheme anyway (`v1`, `v2`, ...). Is this what we want?
76
+
What about `common-types` specific to a service group?
81
77
- What is the difference between resource types and OpenAPI specification `.json` files?
82
78
Can one deduce the resource type version by looking at the source OpenAPI `.json` ?
83
79
- What does it mean for OpenAPI specification `.json` to "have a version"? Are we talking about it being in appropriate
@@ -245,6 +241,8 @@ One service has one SDK package and one documentation portal, while a service gr
245
241
In case of a `service group`, the structure is like for `service`, but the contents of each
246
242
`resource-manager/<RPNS>` and `data-plane/<dataPlaneSubfolder>` is instead additionally nested in a `<service>` parent, for each service in the service group.
247
243
244
+
The Azure team that has a service group has following directory structure:
- Specifically, if given directory has `stable` and `preview` children, is it allowed to also have other children?
289
+
This is the case that is necessary in case of migration: `<azureTeam>/resource-manager/<RPNS>/` has `stable` and `preview` children, but with the service
290
+
group addition, it also has `<service>` child, beside `stable` and `preview`.
291
+
- Do we allow any other sharing of common types than `common-types` ? In the example PR we have `operations`. Also, these
292
+
operations are versioned like API versions, not like the global `common-types`.
289
293
290
294
## Deprecated structure and hand-written OpenAPI specs
291
295
@@ -317,6 +321,7 @@ All of the aforementioned cases are considered legacy and are not allowed going
0 commit comments