Skip to content

Restentpoints with same name get mix up #2876

Closed
@Uwe-Br

Description

@Uwe-Br

Describe the bug

I updated springdoc-openapi-starter-webmvc-ui from Version 2.6.0 to Version 2.8.4 (Version 2.7.0, same issue). And I updated spring-boot-starter-parent from 3.3.5 to 3.4.2.
After the update, I recognize a problem with the swagger UI. Restpoints with the same name get mixed up. The UI shows the correct header, but if I open one, both open. Both use the from the first restpoint.

Expected behavior

springdoc-openapi-starter-webmvc-ui Version 2.8.4 should have same behavior as Version 2.6.0

Screenshots

UI with same Restentpoints names:
Image

In the old (2.6.0) HTML code, both areas had different IDs. With the new Version, both areas get the samIDId.

Old Version:
OldVersion

New Version:
NewVersion

Additional context

@ApiResponse(responseCode = "200", description = "Liste aller Verfahren", content = { @Content(mediaType = "application/json", schema = @Schema(anyOf = { VerfahrenDtoRestKurz.class, VerfahrenDtoRest.class })) }) @ApiResponse(responseCode = "409", description = "Interner Fehler beim Aulesen der Daten.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @ApiResponse(responseCode = "404", description = "Kein Verfahren wurde gefunden.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @ApiResponse(responseCode = "403", description = "Keine Zugriffsrechte", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @ApiResponse(responseCode = "400", description = "Parameter ist unbekannt.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @GetMapping(produces = MediaType.APPLICATION_JSON_VALUE) public Set<Object> getVerfahren( @Parameter(required = false, description = "Wird als Parameter 'lang' angeben, wird VerfahrenLang zurück geben ansonsten VerfahrenKurz.") @RequestParam(name = "darstellung", required = false) final Optional<String> darstellung) throws KeineDatenException {

@ApiResponse(responseCode = "409", description = "Interner Fehler beim Aulesen der Daten.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaTypes.HTTP_PROBLEM_DETAILS_JSON_VALUE) }) @ApiResponse(responseCode = "404", description = "Kein Verfahren wurde gefunden.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaTypes.HTTP_PROBLEM_DETAILS_JSON_VALUE) }) @ApiResponse(responseCode = "403", description = "Keine Zugriffsrechte", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @ApiResponse(responseCode = "400", description = "Parameter ist unbekannt.", content = { @Content(schema = @Schema(implementation = ProblemErrors.class), mediaType = MediaType.APPLICATION_PROBLEM_JSON_VALUE) }) @GetMapping(value = "/{vvpId}", produces = MediaType.APPLICATION_JSON_VALUE) public VerfahrenDtoRest getVerfahren(@PathVariable("vvpId") final Long vvpId) throws KeineDatenException {

Metadata

Metadata

Assignees

No one assigned

    Labels

    incompleteincomplete description: Make sure you Provide a Minimal, Reproducible Example - with HelloController

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions