-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* #18388: Add Mutiny support to JaxRS * Updated samples * Updated doccs * Updated example to 3_0 * Updated sample
- Loading branch information
1 parent
7b0f963
commit 213564a
Showing
89 changed files
with
15,217 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
generatorName: jaxrs-spec | ||
outputDir: samples/server/petstore/jaxrs-spec-quarkus-mutiny | ||
inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml | ||
templateDir: modules/openapi-generator/src/main/resources/JavaJaxRS/spec | ||
additionalProperties: | ||
artifactId: jaxrs-spec-petstore-server | ||
serializableModel: "true" | ||
hideGenerationTimestamp: "true" | ||
implicitHeadersRegex: (api_key|enum_header_string) | ||
generateBuilders: "true" | ||
useMicroProfileOpenAPIAnnotations: "true" | ||
useAsync: "true" | ||
useMutiny: "true" | ||
library: "quarkus" | ||
dateLibrary: "java8-localdatetime" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
...tor/src/main/resources/JavaJaxRS/spec/libraries/quarkus/returnAsyncTypeInterface.mustache
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
{{#useMutiny}}Uni{{/useMutiny}}{{^useMutiny}}CompletionStage{{/useMutiny}}<{{#returnResponse}}Response{{/returnResponse}}{{^returnResponse}}{{#returnContainer}}{{#isMap}}Map<String, {{{returnBaseType}}}>{{/isMap}}{{#isArray}}{{{returnContainer}}}<{{{returnBaseType}}}>{{/isArray}}{{/returnContainer}}{{^returnContainer}}{{{returnBaseType}}}{{/returnContainer}}{{/returnResponse}}> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
samples/server/petstore/jaxrs-spec-quarkus-mutiny/.dockerignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
* | ||
!target/*-runner | ||
!target/*-runner.jar | ||
!target/lib/* |
23 changes: 23 additions & 0 deletions
23
samples/server/petstore/jaxrs-spec-quarkus-mutiny/.openapi-generator-ignore
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# OpenAPI Generator Ignore | ||
# Generated by openapi-generator https://github.com/openapitools/openapi-generator | ||
|
||
# Use this file to prevent files from being overwritten by the generator. | ||
# The patterns follow closely to .gitignore or .dockerignore. | ||
|
||
# As an example, the C# client generator defines ApiClient.cs. | ||
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: | ||
#ApiClient.cs | ||
|
||
# You can match any string of characters against a directory, file or extension with a single asterisk (*): | ||
#foo/*/qux | ||
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux | ||
|
||
# You can recursively match patterns against a directory, file or extension with a double asterisk (**): | ||
#foo/**/qux | ||
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux | ||
|
||
# You can also negate patterns with an exclamation (!). | ||
# For example, you can ignore all files in a docs folder with the file extension .md: | ||
#docs/*.md | ||
# Then explicitly reverse the ignore rule for a single file: | ||
#!docs/README.md |
66 changes: 66 additions & 0 deletions
66
samples/server/petstore/jaxrs-spec-quarkus-mutiny/.openapi-generator/FILES
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
.dockerignore | ||
README.md | ||
pom.xml | ||
src/gen/java/org/openapitools/api/AnotherFakeApi.java | ||
src/gen/java/org/openapitools/api/FakeApi.java | ||
src/gen/java/org/openapitools/api/FakeClassnameTestApi.java | ||
src/gen/java/org/openapitools/api/FooApi.java | ||
src/gen/java/org/openapitools/api/PetApi.java | ||
src/gen/java/org/openapitools/api/RestApplication.java | ||
src/gen/java/org/openapitools/api/RestResourceRoot.java | ||
src/gen/java/org/openapitools/api/StoreApi.java | ||
src/gen/java/org/openapitools/api/UserApi.java | ||
src/gen/java/org/openapitools/model/AdditionalPropertiesClass.java | ||
src/gen/java/org/openapitools/model/AllOfWithSingleRef.java | ||
src/gen/java/org/openapitools/model/Animal.java | ||
src/gen/java/org/openapitools/model/ArrayOfArrayOfNumberOnly.java | ||
src/gen/java/org/openapitools/model/ArrayOfNumberOnly.java | ||
src/gen/java/org/openapitools/model/ArrayTest.java | ||
src/gen/java/org/openapitools/model/Capitalization.java | ||
src/gen/java/org/openapitools/model/Cat.java | ||
src/gen/java/org/openapitools/model/Category.java | ||
src/gen/java/org/openapitools/model/ChildWithNullable.java | ||
src/gen/java/org/openapitools/model/ClassModel.java | ||
src/gen/java/org/openapitools/model/Client.java | ||
src/gen/java/org/openapitools/model/DeprecatedObject.java | ||
src/gen/java/org/openapitools/model/Dog.java | ||
src/gen/java/org/openapitools/model/EnumArrays.java | ||
src/gen/java/org/openapitools/model/EnumClass.java | ||
src/gen/java/org/openapitools/model/EnumTest.java | ||
src/gen/java/org/openapitools/model/FakeBigDecimalMap200Response.java | ||
src/gen/java/org/openapitools/model/FileSchemaTestClass.java | ||
src/gen/java/org/openapitools/model/Foo.java | ||
src/gen/java/org/openapitools/model/FooGetDefaultResponse.java | ||
src/gen/java/org/openapitools/model/FormatTest.java | ||
src/gen/java/org/openapitools/model/HasOnlyReadOnly.java | ||
src/gen/java/org/openapitools/model/HealthCheckResult.java | ||
src/gen/java/org/openapitools/model/MapTest.java | ||
src/gen/java/org/openapitools/model/MixedPropertiesAndAdditionalPropertiesClass.java | ||
src/gen/java/org/openapitools/model/Model200Response.java | ||
src/gen/java/org/openapitools/model/ModelApiResponse.java | ||
src/gen/java/org/openapitools/model/ModelFile.java | ||
src/gen/java/org/openapitools/model/ModelList.java | ||
src/gen/java/org/openapitools/model/ModelReturn.java | ||
src/gen/java/org/openapitools/model/Name.java | ||
src/gen/java/org/openapitools/model/NullableClass.java | ||
src/gen/java/org/openapitools/model/NumberOnly.java | ||
src/gen/java/org/openapitools/model/ObjectWithDeprecatedFields.java | ||
src/gen/java/org/openapitools/model/Order.java | ||
src/gen/java/org/openapitools/model/OuterComposite.java | ||
src/gen/java/org/openapitools/model/OuterEnum.java | ||
src/gen/java/org/openapitools/model/OuterEnumDefaultValue.java | ||
src/gen/java/org/openapitools/model/OuterEnumInteger.java | ||
src/gen/java/org/openapitools/model/OuterEnumIntegerDefaultValue.java | ||
src/gen/java/org/openapitools/model/OuterObjectWithEnumProperty.java | ||
src/gen/java/org/openapitools/model/ParentWithNullable.java | ||
src/gen/java/org/openapitools/model/Pet.java | ||
src/gen/java/org/openapitools/model/ReadOnlyFirst.java | ||
src/gen/java/org/openapitools/model/SingleRefType.java | ||
src/gen/java/org/openapitools/model/SpecialModelName.java | ||
src/gen/java/org/openapitools/model/Tag.java | ||
src/gen/java/org/openapitools/model/TestInlineFreeformAdditionalPropertiesRequest.java | ||
src/gen/java/org/openapitools/model/User.java | ||
src/main/docker/Dockerfile.jvm | ||
src/main/docker/Dockerfile.native | ||
src/main/resources/META-INF/openapi.yaml | ||
src/main/resources/application.properties |
1 change: 1 addition & 0 deletions
1
samples/server/petstore/jaxrs-spec-quarkus-mutiny/.openapi-generator/VERSION
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
7.5.0-SNAPSHOT |
33 changes: 33 additions & 0 deletions
33
samples/server/petstore/jaxrs-spec-quarkus-mutiny/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# JAX-RS server with OpenAPI using Quarkus | ||
|
||
## Overview | ||
This server was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using an | ||
[OpenAPI-Spec](https://openapis.org), you can easily generate a server stub. | ||
|
||
This is an example of building a OpenAPI-enabled JAX-RS server. | ||
This example uses the [JAX-RS](https://jax-rs-spec.java.net/) framework and | ||
the [Eclipse-MicroProfile-OpenAPI](https://github.com/eclipse/microprofile-open-api) addition. | ||
|
||
The pom file is configured to use [Quarkus](https://quarkus.io/) as application server. | ||
|
||
|
||
To start the server in dev mode, run this maven command: | ||
|
||
```bash | ||
mvn compile quarkus:dev | ||
``` | ||
|
||
You can then call your server endpoints under: | ||
|
||
``` | ||
http://localhost:8080/ | ||
``` | ||
|
||
In dev-mode, you can open Swagger-UI at: | ||
|
||
``` | ||
http://localhost:8080/swagger-ui/ | ||
``` | ||
|
||
Read more in the [Quarkus OpenAPI guide](https://quarkus.io/guides/openapi-swaggerui-guide). | ||
|
Oops, something went wrong.