nevzheng opened a new pull request, #11987: URL: https://github.com/apache/gravitino/pull/11987
### What changes were proposed in this pull request? Removes the `type: "null"` branch from `Statistic.value`'s `oneOf` in `docs/open-api/statistics.yaml` and gives the field a more useful description. ### Why are the changes needed? `type: "null"` is JSON Schema / OpenAPI **3.1** syntax. The document declares `openapi: 3.0.3`, where it is invalid — Redocly `recommended-strict` reports it as a `struct` error, the single hard structural error in the spec. `value` is already optional: `StatisticDTO` holds it as an `@Nullable` `Optional<StatisticValue<?>>` and it is not in the schema's `required` list, so "no value" is expressed by the field's absence. The null branch is therefore unnecessary, and dropping it keeps a clean typed `oneOf` for codegen. This is genuinely a 3.0.3 document with one stray 3.1 token, so it is fixed in place. Expressing a union-of-types-plus-null natively would require upgrading to 3.1, which removes the `nullable` keyword and would mean migrating ~130 `nullable` usages plus verifying tooling — a separate discussion, out of scope here. Part of #11985 ### Does this PR introduce _any_ user-facing change? No. Spec/docs-only. `Statistic.value` remains optional and typed; no REST API, schema, or property-key changes. ### How was this patch tested? `cd dev/openapi && npx redocly lint --extends=recommended-strict` — the `statistics.yaml` finding is cleared (total errors 10 → 9) with no new findings introduced. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
