Package io.quarkus.smallrye.openapi
Annotation Interface OpenApiFilter
This extends the MP way to define an `org.eclipse.microprofile.openapi.OASFilter`.
Currently in MP, this needs to be added to a config `mp.openapi.filter` and only allows one filter (class) per application.
This quarkus specific annotation allows users to annotate a class extending
OASFilter as an OpenApiFilter. Such annotated classes will automatically be picked
up and run during the appropriate OpenApiFilter.RunStage.
The configured RunStages in stages() take precedence, if explicitly set. Otherwise, the RunStage from
value() is used, if explicitly set. Otherwise, the default
value of stages() is used.
-
Nested Class Summary
Nested Classes -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionString[]Names of the OpenAPI document configurations this filter should be applicable forintFilter with a higher priority will be applied firstThe stages at which this filter should run.Deprecated, for removal: This API element is subject to removal in a future version. -
Field Summary
Fields
-
Field Details
-
DEFAULT_DOCUMENT_NAME
Default document name which is used for the unnamed default document configuration.- See Also:
-
FILTER_RUN_FOR_ANY_DOCUMENT
Marker to indicate that a filter should run for any document name.- See Also:
-
-
Element Details
-
stages
OpenApiFilter.RunStage[] stagesThe stages at which this filter should run.Example:
@OpenApiFilter(stages = {OpenApiFilter.RunStage.BUILD, OpenApiFilter.RunStage.RUNTIME_STARTUP})Intentionally defaults to the deprecated
OpenApiFilter.RunStage.RUNas to not break backwards compatibility.- Default:
{RUN}
-
value
Deprecated, for removal: This API element is subject to removal in a future version.Usestages()instead.When this filter should run, default Runtime.- Default:
RUN
-
priority
int priorityFilter with a higher priority will be applied first- Returns:
- Default:
1
-
documentNames
String[] documentNamesNames of the OpenAPI document configurations this filter should be applicable for- Returns:
- Default:
{"<ALL>"}
-
stages()instead.