Skip to content

Commit

Permalink
Merge pull request #24180 from geoand/#24132
Browse files Browse the repository at this point in the history
Fix openapi service loader issue in native mode
  • Loading branch information
gsmet authored Mar 8, 2022
2 parents 523f5c4 + f89a699 commit 45b8274
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import org.eclipse.microprofile.openapi.annotations.responses.APIResponses;
import org.eclipse.microprofile.openapi.annotations.security.SecurityRequirement;
import org.eclipse.microprofile.openapi.models.OpenAPI;
import org.eclipse.microprofile.openapi.spi.OASFactoryResolver;
import org.jboss.jandex.AnnotationInstance;
import org.jboss.jandex.AnnotationTarget;
import org.jboss.jandex.AnnotationValue;
Expand Down Expand Up @@ -156,9 +157,10 @@ void contributeClassesToIndex(BuildProducer<AdditionalIndexedClassesBuildItem> a
}

@BuildStep
void registerNativeImageResources(BuildProducer<ServiceProviderBuildItem> serviceProvider) throws IOException {
void registerNativeImageResources(BuildProducer<ServiceProviderBuildItem> serviceProvider) {
// To map from smallrye and mp config to quarkus
serviceProvider.produce(ServiceProviderBuildItem.allProvidersFromClassPath(OpenApiConfigMapping.class.getName()));
serviceProvider.produce(ServiceProviderBuildItem.allProvidersFromClassPath(OASFactoryResolver.class.getName()));
}

@BuildStep
Expand Down

0 comments on commit 45b8274

Please sign in to comment.