Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dressca の OpenAPI 仕様書にMaia / Maris 間で不要な差異がある #2103

Open
kenjiyoshid-a opened this issue Dec 2, 2024 · 1 comment
Labels
target: Dressca サンプルアプリケーションDresscaに関係がある

Comments

@kenjiyoshid-a
Copy link
Contributor

kenjiyoshid-a commented Dec 2, 2024

概要

Dressca の OpenAPI 仕様書にMaia / Maris 間で不要な差異がある。
それによりadminとconsumerの下記ファイルにて、Maia / Maris 間で不要な差分が生じてしまっている。

  • src\generated\api-client\api\assets-api.ts

※追加で修正が必要なファイルがあれば追記

詳細 / 機能詳細(オプション)

該当ファイルにおいて例えば、MaiaとMarisで以下のような差分がある。

  • Maia 側のコード
get(assetCode: string, options?: RawAxiosRequestConfig): AxiosPromise<File> {
  • Maris 側のコード
get(assetCode: string, options?: RawAxiosRequestConfig): AxiosPromise<void> {

該当箇所はOpenAPI Generatorを用いた自動生成されたプログラムであり、バックエンド側のAPI仕様書を読み込ませて生成させているため、フロントエンド側とバックエンド側の修正が必要である。
上記に例示した差分の直接の原因としては、Maia側はContent-Typeにimage/* を入れてbinaryを返す定義になっているが、Maris側は特に指定していないためである。APIの動作としては、Maia側のプログラムの方が期待に即しているため、Maris側をMaia側に合うように修正する。
他に修正が必要なファイルが見つかった場合にはMaia側とMaris側のどちらに合わせるかは適宜判断する。

完了条件

  • 差分の原因となるバックエンド側のAPI定義を修正している
  • Maia / Maris間でOpenAPI Generatorで生成されたコードに不要な差分がないことを確認する
@kenjiyoshid-a kenjiyoshid-a added not triaged 精緻化、分析がされていない target: Dressca サンプルアプリケーションDresscaに関係がある target: Azure AD B2C Auth Azure AD B2C認証の要件別サンプルに関係がある and removed not triaged 精緻化、分析がされていない target: Azure AD B2C Auth Azure AD B2C認証の要件別サンプルに関係がある labels Dec 2, 2024
@kenjiyoshid-a kenjiyoshid-a changed the title OpenAPI Generator に生成されたフロントエンドのコードにMaia / Maris 間で差異がある OpenAPI 仕様書にMaia / Maris 間で不要な差異がある Dec 2, 2024
@kenjiyoshid-a kenjiyoshid-a changed the title OpenAPI 仕様書にMaia / Maris 間で不要な差異がある Dressca の OpenAPI 仕様書にMaia / Maris 間で不要な差異がある Dec 2, 2024
@KentaHizume
Copy link
Contributor

既知の事象として、下記の件が知られています。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
target: Dressca サンプルアプリケーションDresscaに関係がある
Projects
None yet
Development

No branches or pull requests

2 participants