Skip to content

Commit

Permalink
Further review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
tjquinno authored and romain-grecourt committed Aug 6, 2024
1 parent 0564b7c commit 1c800f5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/mp/openapi/openapi-generator.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ include::{rootdir}/includes/mp.adoc[]
:gen-inc: {incdir}/openapi-generator.adoc
:helidon-client-xref: {restclient-page}
include::{gen-inc}[tag=preamble]
include::{rootdir}/includes/openapi/openapi-generator.adoc[tag=preamble]
include::{gen-inc}[tags=intro;coords;config;usage;using-generated-code-intro;using-generated-code-server;using-generated-code-client-intro]
include::{rootdir}/includes/openapi/openapi-generator.adoc[tags=intro;coords;config;usage;using-generated-code-intro;using-generated-code-server;using-generated-code-client-intro]
The Helidon MP client generator creates a MicroProfile REST client interface for each API.
Each generated API interface is annotated so your code can `@Inject` the API into one of your own beans and then use the interface directly to invoke the remote service. Alternatively, you can also explicitly use the link:{microprofile-rest-client-javadoc-url}/org/eclipse/microprofile/rest/client/RestClientBuilder.html[`RestClientBuilder`] to create an instance programmatically and then invoke its methods to contact the remote service.
Expand All @@ -52,5 +52,5 @@ include::{sourcedir}/mp/openapi/OpenApiGeneratorSnippets.java[tag=class-declarat
<5> Invokes the remote service using the injected field and the parameter from the incoming request.
include::{gen-inc}[tag=common-references]
include::{rootdir}/includes/openapi/openapi-generator.adoc[tag=common-references]
* link:https://github.com/eclipse/microprofile-rest-client[MicroProfile REST Client specification]
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@
public class OpenApiGeneratorSnippets {

/*
To generate a project containing the types which need to be mocked--in case of changes in the upstream generator:
To generate a project containing the types which need to be mocked--in case of changes in the upstream generator.
Here {downloadLocation} is where you downloaded the generator JAR to, and {helidonRoot} is your root directory
for the Helidon source.
1. Download the generator: see [these instructions](https://github.com/OpenAPITools/openapi-generator?tab=readme-ov-file#13---download-jar).
2. `mkdir seServer`
Expand All @@ -41,7 +43,7 @@ public class OpenApiGeneratorSnippets {
java -jar {downloadLocation}/openapi-generator-cli.jar generate \
-g java-helidon-server \
--library se \
-i ~/mic/j4c/helidon/docs/src/main/resources/petstorex.yaml \
-i {helidonRoot}/docs/src/main/resources/petstorex.yaml \
-p useAbstractClass=true \
--helidonVersion x.y.z
```
Expand All @@ -52,7 +54,7 @@ public class OpenApiGeneratorSnippets {
java -jar {downloadLocation}/openapi-generator-cli.jar generate \
-g java-helidon-client \
--library se \
-i ~/mic/j4c/helidon/docs/src/main/resources/petstorex.yaml \
-i {helidonRoot}/docs/src/main/resources/petstorex.yaml \
--helidonVersion x.y.z
```
where `x.y.z` is the version of Helidon you are working with.
Expand Down
1 change: 0 additions & 1 deletion parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,6 @@
</developers>

<properties>
<version.plugin.build-helper>3.4.0</version.plugin.build-helper>
<version.plugin.clean>3.2.0</version.plugin.clean>
<version.plugin.deploy>3.1.1</version.plugin.deploy>
<version.plugin.gpg>1.6</version.plugin.gpg>
Expand Down

0 comments on commit 1c800f5

Please sign in to comment.