Skip to content

Conversation

@lagudomeze
Copy link

fix groups is always empty

fix groups is always empty
definitions.stream().filter(routeDefinition -> routeDefinition.getId().matches(".*-service")).forEach(routeDefinition -> {
String name = routeDefinition.getId().replaceAll("-service", "");
GroupedOpenApi.builder().pathsToMatch("/" + name + "/**").group(name).build();
GroupedOpenApi api = GroupedOpenApi.builder().pathsToMatch("/" + name + "/**").group(name).build();

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems, this Bean definition has no impact. The groups are created based on springdoc.swagger-ui.urls config.

https://github.com/springdoc/springdoc-openapi-demos/blob/2.x/demo-microservices/config-service/src/main/resources/config/gateway-service.yml#L66

I commented out this bean definition and it still works.

@bnasslahsen
Copy link
Collaborator

demos code has been updated

@lagudomeze lagudomeze deleted the patch-1 branch April 11, 2024 01:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants