[
https://issues.apache.org/jira/browse/FLINK-29504?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tiger (Apache) Wang updated FLINK-29504:
----------------------------------------
Description:
Install nodejs and run
{{$ npx --yes @openapitools/openapi-generator-cli generate -i
[https://nightlies.apache.org/flink/flink-docs-release-1.15/generated/rest_v1_dispatcher.yml]
-g typescript-axios -o .}}
Then it outputs error
{{Caused by: java.lang.RuntimeException: Request body cannot be null. Possible
cause: missing schema in body parameter (OAS v2): class RequestBody {}}
{{ description: null}}
{{ content: class Content {}}
{{ {application/x-java-archive=class MediaType {}}
{{ schema: null}}
{{ examples: null}}
{{ example: null}}
{{ encoding: null}}
{\{ }}}}
{\{ }}}
{{ required: true}}
{{}}}
This is because in the YAML:
{{}}{{ requestBody:}}
{{ content:}}
{{{} application/x-java-archive: {{}}}}
was:
Run
{{npx --yes @openapitools/openapi-generator-cli generate -i
https://nightlies.apache.org/flink/flink-docs-release-1.15/generated/rest_v1_dispatcher.yml
-g typescript-axios -o .}}
Then it outputs error
{{Caused by: java.lang.RuntimeException: Request body cannot be null. Possible
cause: missing schema in body parameter (OAS v2): class RequestBody {}}
{{ description: null}}
{{ content: class Content {}}
{{ {application/x-java-archive=class MediaType {}}
{{ schema: null}}
{{ examples: null}}
{{ example: null}}
{{ encoding: null}}
{{ }}}}
{{ }}}
{{ required: true}}
{{}}}
This is because in the YAML:
{{}}{{ requestBody:}}
{{ content:}}
{{ application/x-java-archive: {}}}
> [OpenAPI] `application/x-java-archive` should be followed by a structure
> instead of `{}`
> ----------------------------------------------------------------------------------------
>
> Key: FLINK-29504
> URL: https://issues.apache.org/jira/browse/FLINK-29504
> Project: Flink
> Issue Type: Improvement
> Components: API / Core
> Affects Versions: 1.15.2
> Reporter: Tiger (Apache) Wang
> Priority: Major
> Labels: openapi
>
> Install nodejs and run
> {{$ npx --yes @openapitools/openapi-generator-cli generate -i
> [https://nightlies.apache.org/flink/flink-docs-release-1.15/generated/rest_v1_dispatcher.yml]
> -g typescript-axios -o .}}
>
> Then it outputs error
>
> {{Caused by: java.lang.RuntimeException: Request body cannot be null.
> Possible cause: missing schema in body parameter (OAS v2): class RequestBody
> {}}
> {{ description: null}}
> {{ content: class Content {}}
> {{ {application/x-java-archive=class MediaType {}}
> {{ schema: null}}
> {{ examples: null}}
> {{ example: null}}
> {{ encoding: null}}
> {\{ }}}}
> {\{ }}}
> {{ required: true}}
> {{}}}
>
> This is because in the YAML:
> {{}}{{ requestBody:}}
> {{ content:}}
> {{{} application/x-java-archive: {{}}}}
>
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)