Skip to content

Commit ea06bf8

Browse files
committed
fix: reconcile RC1 API catalog contracts
1 parent f41dcf6 commit ea06bf8

24 files changed

Lines changed: 105930 additions & 18659 deletions

.github/workflows/validate-examples.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ jobs:
4747
git -C "${OPENMETADATA_SOURCE}" sparse-checkout init --cone
4848
git -C "${OPENMETADATA_SOURCE}" sparse-checkout set \
4949
openmetadata-service/src/main/java/org/openmetadata/service/resources \
50+
openmetadata-service/src/main/java/org/openmetadata/service/security \
5051
openmetadata-spec/src/main/resources/json/schema
5152
git -C "${OPENMETADATA_SOURCE}" fetch --depth=1 origin "${OPENMETADATA_SOURCE_COMMIT}"
5253
git -C "${OPENMETADATA_SOURCE}" checkout --detach FETCH_HEAD

README.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,15 @@ rename-service, test-suite, webhook, resource, and destructive-script demos were
3535
of presenting code that no longer runs against current releases. The unused OpenMetadata
3636
submodule, stale Snowflake workflow, and retired Python and Java SDK tutorials also remain absent.
3737

38-
The `platform-api` catalog normalizes all 1,748 HTTP-annotated methods found in the pinned OSS
39-
source and maps all 112 generated `create*.py` model classes to deterministic fixtures and
40-
scenarios. Its 32 SDK mappings resolve to callable RC1 interfaces; the other 1,716 operations use
41-
explicit REST renderers. These counts are generator-derived and enforced by CI.
42-
43-
That exhaustive inventory includes 115 hidden, 20 internal, one diagnostic, and eight test-support
38+
The `platform-api` catalog expands 1,748 HTTP-annotated methods found in the pinned OSS source
39+
into 1,985 concrete normalized operations and maps all 112 generated `create*.py` model classes
40+
to deterministic fixtures and scenarios. It also records 319 response models: 187 JSON Schema
41+
fixtures, 106 source-declared result-list envelopes, two Java scalars, and 24 shape-only fixtures
42+
with explicit validation boundaries. Its 32 SDK mappings have signature-checked argument bindings;
43+
the other 1,953 operations use explicit REST renderers. These counts are generator-derived and
44+
enforced by CI.
45+
46+
That exhaustive inventory includes 133 hidden, one internal, one diagnostic, and eight test-support
4447
operations for source completeness. Those routes are unstable and unsupported for customer
4548
integrations. The catalog has no host, credential, or live-network execution mode and does not
4649
certify server acceptance or authorization behavior.

platform-api/README.md

Lines changed: 33 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -19,22 +19,32 @@ Hidden, internal, diagnostic, and test-support routes are included for inventory
1919
completeness. They are unstable and unsupported for customer integrations. Use the public
2020
product documentation—not this catalog—for stable SDK learning tutorials.
2121

22+
The pinned repository does not ship a static published OpenAPI document to compare. The
23+
manifest's `customer-facing` surface classification means the route has public source annotations
24+
and is eligible for generated OpenAPI; it does not claim independently verified publication.
25+
`source-only` identifies hidden, internal, diagnostic, or test-support routes. Neither label is a
26+
promise of API stability.
27+
2228
## What Is Included
2329

2430
The generated catalog currently derives these values from the pinned source rather than
2531
from an approximate route scan:
2632

2733
| Contract | RC1 coverage |
2834
| --- | ---: |
29-
| Normalized HTTP operations | 1,748 |
35+
| HTTP-annotated Java methods | 1,748 |
36+
| Concrete normalized operations | 1,985 |
3037
| Generated `create*.py` models | 112 |
38+
| Response fixtures | 319 (187 JSON Schema, 106 Java result-list, 2 scalar, 24 shape-only) |
3139
| Explicitly verified Python SDK mappings | 32 |
32-
| Deterministic REST renderers | 1,716 |
40+
| Deterministic REST renderers | 1,953 |
3341

3442
- [Operation matrix](docs/generated/operations.md): verb, normalized path, Java method,
3543
visibility, authentication, safety, SDK or REST interface, scenarios, and source line.
3644
- [Asset and fixture matrix](docs/generated/assets.md): every generated create-model class,
3745
source schema, validation boundary, scenarios, and deterministic request body.
46+
- [Response fixture matrix](docs/generated/responses.md): every extracted response model,
47+
fixture body, matching schema where available, and explicit shape-only boundaries.
3848
- [Scenario catalog](docs/generated/scenarios.md): scenario purpose, operation count,
3949
visibility mix, barriers, command, and expected output.
4050
- [Coverage summary](docs/generated/README.md): generator-derived totals and model-validation
@@ -98,8 +108,8 @@ Expected summary:
98108
{
99109
"dryRunOnly": true,
100110
"errorStatus": null,
101-
"operations": 437,
102-
"recordedRequests": 437,
111+
"operations": 497,
112+
"recordedRequests": 497,
103113
"scenario": "core-catalog-assets"
104114
}
105115
```
@@ -118,8 +128,9 @@ Confirm that every normalized operation belongs to at least one scenario:
118128
.venv/bin/python -m openmetadata_demo_api coverage
119129
```
120130

121-
A complete catalog reports an empty `missingOperations` list and matching source and
122-
scenario operation totals.
131+
A complete catalog reports an empty `missingOperations` list. `sourceOperations` counts
132+
annotated Java methods before inheritance; `normalizedOperations` and `scenarioOperations`
133+
count the concrete routes after inherited methods are bound to each resource.
123134

124135
## Dependency Ordering
125136

@@ -128,27 +139,31 @@ parents:
128139

129140
```mermaid
130141
flowchart LR
131-
service["Services"] --> parent["Parent assets"]
142+
service["Service creation"] --> status["Service validation and status"]
143+
status --> parent["Parent assets"]
132144
parent --> child["Child assets"]
133145
child --> leaf["Leaf assets"]
134146
leaf --> enrichment["Lineage, profiles, sample data, usage, and status"]
135147
enrichment --> platform["Relationships and supporting platform records"]
136-
platform --> teardown["Delete and restore lifecycle requests"]
148+
platform --> teardown["Destructive lifecycle requests"]
149+
teardown --> restore["Restore requests"]
137150
```
138151

139152
The planner topologically sorts every scenario, rejects missing dependencies, rejects
140153
cycles and duplicate step IDs, and records service requests before dependent assets.
141154

142155
## SDK and REST Classification
143156

144-
An operation receives an SDK mapping only when the named interface exists and is callable
145-
in `openmetadata-ingestion==2.0.0.0rc1`. All other operations use an explicit REST request
146-
renderer. `REST only` does not mean that a route is recommended or stable; consult its
147-
visibility and safety columns first.
157+
An operation receives an SDK mapping only when the named interface exists in
158+
`openmetadata-ingestion==2.0.0.0rc1` and every required parameter has a deterministic binding.
159+
The generated call descriptor is checked against the installed method signature. All other
160+
operations use an explicit REST request renderer. `REST only` does not mean that a route is
161+
recommended or stable; consult its visibility and safety columns first.
148162

149163
The recording boundary treats both classifications identically: neither can open a network
150-
connection. Success, validation failure, unauthorized, forbidden, not found, conflict, and
151-
unsupported-operation fixtures are deterministic where applicable.
164+
connection. Source-declared error responses are recorded separately from validation,
165+
authorization, lookup, conflict, and server-boundary simulations. The operation matrix labels
166+
that provenance instead of implying that every simulated response is declared by the Java API.
152167

153168
## Reproduce the Catalog
154169

@@ -181,9 +196,12 @@ The package proves that:
181196
- every operation renders without unresolved path parameters or network access;
182197
- every operation has authentication, visibility, safety, response, and applicable error
183198
classifications;
199+
- every extracted response model has either a pinned-schema-valid fixture or an explicit
200+
shape-only boundary;
184201
- every generated create-model has a deterministic fixture and scenario;
185202
- dependency graphs are acyclic and order parent records before dependent records; and
186-
- verified SDK mappings resolve to callable RC1 interfaces.
203+
- verified SDK mappings resolve to callable RC1 interfaces with complete required-argument
204+
bindings.
187205

188206
It does not prove server acceptance, authorization-policy behavior, persistence, deployment,
189207
or compatibility with another OpenMetadata release. After 2.0 GA, regenerate from the GA

platform-api/docs/generated/README.md

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,29 +6,36 @@
66
77
- Source ref: `2.0.0-rc1-release`
88
- Source commit: `8e199f486b63df9f44d4c827a9f43559d9e56e07`
9-
- Operations: 1748
9+
- HTTP-annotated Java methods: 1748
10+
- Concrete normalized operations: 1985
1011
- Generated `create*.py` models: 112
12+
- Response models and fixtures: 319
1113
- Verified SDK interfaces: 32
12-
- Explicit REST renderers: 1716
14+
- Explicit REST renderers: 1953
1315

1416
## Reference Pages
1517

1618
- [Operation catalog](operations.md)
1719
- [Generated model and fixture catalog](assets.md)
20+
- [Response fixture catalog](responses.md)
1821
- [Dry-run scenario catalog](scenarios.md)
1922

2023
## Visibility
2124

2225
| Visibility | Operations |
2326
| --- | ---: |
2427
| `diagnostic` | 1 |
25-
| `hidden` | 115 |
26-
| `internal` | 20 |
27-
| `public` | 1604 |
28+
| `hidden` | 133 |
29+
| `internal` | 1 |
30+
| `public` | 1842 |
2831
| `test-support` | 8 |
2932

3033
Hidden, internal, diagnostic, and test-support routes are listed for source
3134
completeness. They are unsupported for customer integrations.
35+
The pinned source tree does not contain a static published OpenAPI document to diff.
36+
`customer-facing` therefore classifies public source annotations, not
37+
independently verified publication; `source-only` means hidden or explicitly
38+
classified as internal/supporting here.
3239

3340
## Fixture Validation
3441

@@ -38,3 +45,12 @@ completeness. They are unsupported for customer integrations.
3845
| `json-schema-compatible+pydantic` | 4 |
3946
| `json-schema-only` | 4 |
4047
| `pydantic-only` | 3 |
48+
49+
## Response Validation
50+
51+
| Validation boundary | Models |
52+
| --- | ---: |
53+
| `java-result-list` | 106 |
54+
| `java-scalar` | 2 |
55+
| `json-schema` | 187 |
56+
| `shape-only` | 24 |

0 commit comments

Comments
 (0)