Невозможно сгенерировать спецификации OpenAPI с помощью плагина зависимостей smallrye openapi и интерфейса jaxrs.JAVA

Программисты JAVA общаются здесь
Ответить Пред. темаСлед. тема
Anonymous
 Невозможно сгенерировать спецификации OpenAPI с помощью плагина зависимостей smallrye openapi и интерфейса jaxrs.

Сообщение Anonymous »

Я разрабатываю микросервисы, состоящие из различных модулей maven.
Субмодуль rest-api — это тот, который я использую для определения интерфейсов REST API.
Интерфейс определен как таковой:
@Path("/identity")
@Consumes(MediaType.APPLICATION_JSON)
@Produces(MediaType.APPLICATION_JSON)
public interface IIdentityResource {

/**
* Request a Time Based One Time Password (TOTP) for user's email verification.
*
* @param email The user's email
* The email must be valid and not already verified
* The email must be associated to a user
* @return The generated TOTP
*/
@POST
@Path("/account/verification/send-totp")
@APIResponses(value = {
@APIResponse(
responseCode = "204",
description = "Account successfully verified"
),
@APIResponse(
responseCode = "400",
description = "Bad Request - Invalid account verification data",
content = @Content(schema = @Schema(implementation = ErrorResponseDTO.class))
),
@APIResponse(
responseCode = "401",
description = "Not Authorized - Invalid or expired credentials",
content = @Content(schema = @Schema(implementation = ErrorResponseDTO.class))
),
@APIResponse(
responseCode = "403",
description = "Forbidden - Access to resource is forbidden",
content = @Content(schema = @Schema(implementation = ErrorResponseDTO.class))
),
@APIResponse(
responseCode = "404",
description = "Not Found - Account or verification data not found",
content = @Content(schema = @Schema(implementation = ErrorResponseDTO.class))
),
@APIResponse(
responseCode = "500",
description = "Internal Server Error - Unexpected error",
content = @Content(schema = @Schema(implementation = ErrorResponseDTO.class))
)
})
void requestVerificationTOTP(@Valid AccountVerificationOTPRequest accountVerificationOTPRequest);

/**
* Verify the user's email with the given TOTP.
*
* @param email The user's email
* The email must be valid and not already verified
* The email must be associated to a user
* @param totp The TOTP
* @return The generated TOTP
*/
@POST
@Path("/account/verification/verify")
void verifyAccountTOTP(@Valid AccountVerificationRequest accountVerificationRequest) throws BadRequestException, NotFoundException, ForbiddenException, NotAuthorizedException, InternalServerErrorException ;

/**
* Request a Time Based One Time Password (TOTP) for user's password reset.
*
* @param email The user's email
* The email must be valid and not already verified
* The email must be associated to a user
* @return The generated TOTP
*/
@POST
@Path("/account/password-reset/send-totp")
void requestResetTOTP(@Valid PasswordResetOTPRequest passwordResetOTPRequest);

/**
* Reset the user's password with the given TOTP.
*
* @param email The user's email
* The email must be valid and not already verified
* The email must be associated to a user
* @param totp The TOTP
* @return The generated TOTP
*/
@POST
@Path("/account/password-reset/update-password")
void resetPasswordTOTP(@Valid PasswordResetRequest passwordResetRequest) throws BadRequestException, NotFoundException, ForbiddenException, NotAuthorizedException, InternalServerErrorException ;

}

И мой файл pom.xml:

4.0.0

xxx
api-composer
1.4.1


rest-api



io.smallrye
smallrye-open-api
3.13.0
pom


jakarta.ws.rs
jakarta.ws.rs-api
2.1.6


xxx
model
compile





smallrye-open-api-maven-plugin
io.smallrye
3.13.0



generate-schema




target/openapi.yaml







Когда я пытаюсь сгенерировать спецификации openapi с помощью >mvn clean compile -pl rest-api или просто mvn clean compile -pl rest-api smallrye-open-api:generate -schema определение пусто:
---
openapi: 3.0.3
info:
title: Generated API
version: "1.0"
paths: {}



Подробнее здесь: https://stackoverflow.com/questions/790 ... -and-jaxrs
Реклама
Ответить Пред. темаСлед. тема

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

  • Похожие темы
    Ответы
    Просмотры
    Последнее сообщение

Вернуться в «JAVA»