0

I have a Spring boot application that works perfectly fine with Springdoc until I add the following code to group the endpoints into a default group.

    @Bean
    public GroupedOpenApi hideApis() {
        return GroupedOpenApi.builder().group("default")
                .pathsToExclude("/api/v2/**", "/v2/**")
                .pathsToMatch("/api/v1/**", "/v1/**")
                .addOperationCustomizer(new customCustomizer())
                .build();
    }

As soon as this part of code is added I'm getting the below error

Failed to load Api Definition - Fetch error

Any idea what is wrong?

Springdoc v1.4.3

Spring-boot 2.x

Debargha Roy
  • 2,320
  • 1
  • 15
  • 34

1 Answers1

-1

Cause by a Null Pointer Exception in the OperationCustomizer class, i.e in the customCustomizer() of the given code.

Debargha Roy
  • 2,320
  • 1
  • 15
  • 34