Skip to content

Commit

Permalink
Update the documentation for REST renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
gsmet committed Mar 11, 2024
1 parent 79cec21 commit a990a54
Show file tree
Hide file tree
Showing 138 changed files with 542 additions and 545 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ language:
resource:
class-name: GreetingResource
path: "/hello"
response: "Hello from RESTEasy Reactive"
response: "Hello from Quarkus REST"
dependencies:
- io.quarkus:quarkus-resteasy-reactive
test-dependencies:
Expand Down
4 changes: 2 additions & 2 deletions docs/src/main/asciidoc/amqp.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ First, we need to create two projects: the _producer_ and the _processor_.
To create the _producer_ project, in a terminal run:

:create-app-artifact-id: amqp-quickstart-producer
:create-app-extensions: resteasy-reactive-jackson,smallrye-reactive-messaging-amqp
:create-app-extensions: rest-jackson,smallrye-reactive-messaging-amqp
:create-app-post-command:
include::{includes}/devtools/create-app.adoc[]

This command creates the project structure and select the two Quarkus extensions we will be using:

1. RESTEasy Reactive and its Jackson support to handle JSON payloads
1. Quarkus REST (formerly RESTEasy Reactive) and its Jackson support to handle JSON payloads
2. The Reactive Messaging AMQP connector

To create the _processor_ project, from the same directory, run:
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/ansible.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ Apr 13 12:48:19 bd71f39642c8 java[853]: -/ /_/ / /_/ / __ |/ , _/ ,< / /_/ /\ \
Apr 13 12:48:19 bd71f39642c8 java[853]: --\___\_\____/_/ |_/_/|_/_/|_|\____/___/
Apr 13 12:48:19 bd71f39642c8 java[853]: 2023-04-13 12:48:19,284 INFO [io.quarkus] (main) getting-started 1.0.0-SNAPSHOT on JVM (powered by Quarkus 2.16.6.Final) started in 0.607s. Listening on: http://0.0.0.0:8080
Apr 13 12:48:19 bd71f39642c8 java[853]: 2023-04-13 12:48:19,309 INFO [io.quarkus] (main) Profile prod activated.
Apr 13 12:48:19 bd71f39642c8 java[853]: 2023-04-13 12:48:19,310 INFO [io.quarkus] (main) Installed features: [cdi, resteasy-reactive, smallrye-context-propagation, vertx]
Apr 13 12:48:19 bd71f39642c8 java[853]: 2023-04-13 12:48:19,310 INFO [io.quarkus] (main) Installed features: [cdi, rest, smallrye-context-propagation, vertx]
----

Manually, you can also test if the app is reachable:
Expand Down
8 changes: 4 additions & 4 deletions docs/src/main/asciidoc/aws-lambda-http.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ This guide is maintained in the main Quarkus repository
and pull requests should be submitted there:
https://github.com/quarkusio/quarkus/tree/main/docs/src/main/asciidoc
////
= AWS Lambda with RESTEasy Reactive, Undertow, or Reactive Routes
= AWS Lambda with Quarkus REST, Undertow, or Reactive Routes
:extension-status: preview
include::_attributes.adoc[]
:categories: cloud
Expand All @@ -13,7 +13,7 @@ include::_attributes.adoc[]
:extensions: io.quarkus:quarkus-amazon-lambda,io.quarkus:quarkus-amazon-lambda-http

With Quarkus you can deploy your favorite Java HTTP frameworks as AWS Lambda's using either the https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api.html[AWS Gateway HTTP API]
or https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-rest-api.html[AWS Gateway REST API]. This means that you can deploy your microservices written with RESTEasy Reactive (our Jakarta REST implementation),
or https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-rest-api.html[AWS Gateway REST API]. This means that you can deploy your microservices written with Quarkus REST (our Jakarta REST implementation),
Undertow (servlet), Reactive Routes, xref:funqy-http.adoc[Funqy HTTP] or any other Quarkus HTTP framework as an AWS Lambda.

IMPORTANT: You should only use single HTTP framework together with AWS Lambda extension to avoid unexpected conflicts and errors.
Expand Down Expand Up @@ -249,7 +249,7 @@ There is nothing special about the POM other than the inclusion of the `quarkus-
(if you are deploying an AWS Gateway HTTP API) or the `quarkus-amazon-lambda-rest` extension (if you are deploying an AWS Gateway REST API).
These extensions automatically generate everything you might need for your lambda deployment.

Also, at least in the generated Maven archetype `pom.xml`, the `quarkus-resteasy-reactive`, `quarkus-reactive-routes`, and `quarkus-undertow`
Also, at least in the generated Maven archetype `pom.xml`, the `quarkus-rest`, `quarkus-reactive-routes`, and `quarkus-undertow`
dependencies are all optional. Pick which HTTP framework(s) you want to use (Jakarta REST, Reactive Routes, and/or Servlet) and
remove the other dependencies to shrink your deployment.

Expand Down Expand Up @@ -298,7 +298,7 @@ HTTP response messages and the `sam.yaml` file must configure the API Gateway to

== Injectable AWS Context Variables

If you are using RESTEasy Reactive and Jakarta REST, you can inject various AWS Context variables into your Jakarta REST resource classes
If you are using Quarkus REST and Jakarta REST, you can inject various AWS Context variables into your Jakarta REST resource classes
using the Jakarta REST `@Context` annotation or anywhere else with the CDI `@Inject` annotation.

For the AWS HTTP API you can inject the AWS variables `com.amazonaws.services.lambda.runtime.Context` and
Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/azure-functions-http.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ This guide is maintained in the main Quarkus repository
and pull requests should be submitted there:
https://github.com/quarkusio/quarkus/tree/main/docs/src/main/asciidoc
////
= Azure Functions with RESTEasy Reactive, Undertow, or Reactive Routes
= Azure Functions with Quarkus REST, Undertow, or Reactive Routes
:extension-status: preview
include::_attributes.adoc[]
:categories: cloud
:summary: Deploy Vert.x Web, Servlet, or RESTEasy microservices as a Microsoft Azure Function.
:topics: azure,serverless,function,cloud
:extensions: io.quarkus:quarkus-azure-functions-http

The `quarkus-azure-functions-http` extension allows you to write microservices with RESTEasy Reactive (our Jakarta REST implementation),
The `quarkus-azure-functions-http` extension allows you to write microservices with Quarkus REST (our Jakarta REST implementation),
Undertow (servlet), Reactive Routes, or xref:funqy-http.adoc[Funqy HTTP] and make these microservices deployable to the Azure Functions runtime.
In other words, this extension is a bridge from the Azure Functions HttpTrigger and the Quarkus family
of HTTP APIs.
Expand All @@ -30,7 +30,7 @@ include::{includes}/prerequisites.adoc[]

== Solution

This guide walks you through running a maven project that can deploy a Resteasy Reactive endpoint to Azure Functions.
This guide walks you through running a maven project that can deploy a Quarkus REST endpoint to Azure Functions.
While only Jakarta REST is provided as an example, you can easily replace it with the HTTP framework of your choice.

== Creating the Maven/Gradle Project
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/building-native-image.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ __ ____ __ _____ ___ __ ____ ______
--\___\_\____/_/ |_/_/|_/_/|_|\____/___/
2023-05-05 10:55:52,068 INFO [io.quarkus] (main) getting-started 1.0.0-SNAPSHOT native (powered by Quarkus 3.0.2.Final) started in 0.009s. Listening on: http://0.0.0.0:8081
2023-05-05 10:55:52,069 INFO [io.quarkus] (main) Profile prod activated.
2023-05-05 10:55:52,069 INFO [io.quarkus] (main) Installed features: [cdi, resteasy-reactive, smallrye-context-propagation, vertx]
2023-05-05 10:55:52,069 INFO [io.quarkus] (main) Installed features: [cdi, rest, smallrye-context-propagation, vertx]
[INFO] Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.99 s - in org.acme.getting.started.GreetingResourceIT
...
----
Expand Down
4 changes: 2 additions & 2 deletions docs/src/main/asciidoc/cache.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ The solution is located in the `cache-quickstart` link:{quickstarts-tree-url}/ca
First, we need to create a new Quarkus project with the following command:

:create-app-artifact-id: cache-quickstart
:create-app-extensions: cache,resteasy-reactive-jackson
:create-app-extensions: cache,rest-jackson
include::{includes}/devtools/create-app.adoc[]

This command generates the project and imports the `cache` and `resteasy-reactive-jackson` extensions.
This command generates the project and imports the `cache` and `rest-jackson` extensions.

If you already have your Quarkus project configured, you can add the `cache` extension
to your project by running the following command in your project base directory:
Expand Down
8 changes: 4 additions & 4 deletions docs/src/main/asciidoc/cassandra.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -315,19 +315,19 @@ public class FruitDto {
}
----

The translation to and from JSON is done automatically by the Quarkus RESTEasy Reactive extension, which is
The translation to and from JSON is done automatically by the Quarkus REST (formerly RESTEasy Reactive) extension, which is
included in this guide's pom.xml file. If you want to add it manually to your application, add the
below snippet to your application's ppm.xml file:

[source,xml]
----
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-resteasy-reactive</artifactId>
<artifactId>quarkus-rest</artifactId>
</dependency>
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-resteasy-reactive-jackson</artifactId>
<artifactId>quarkus-rest-jackson</artifactId>
</dependency>
----

Expand Down Expand Up @@ -600,7 +600,7 @@ NOTE: The `getAll()` method above returns `Multi`, and the `add()` method return
are the same Mutiny types that we met before; they are automatically recognized by the Quarkus
reactive REST API, so we don't need to convert them into JSON ourselves.

RESTEasy Reactive natively supports the Mutiny reactive types e.g. `Uni` and `Multi`.
Quarkus REST natively supports the Mutiny reactive types e.g. `Uni` and `Multi`.

This dependency is already included in this guide's pom.xml, but if you are starting a new project
from scratch, make sure to include it.
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/centralized-log-management.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ The following examples will all be based on the same example application that yo
Create an application with the `quarkus-logging-gelf` extension. You can use the following command to create it:

:create-app-artifact-id: gelf-logging
:create-app-extensions: resteasy-reactive,logging-gelf
:create-app-extensions: rest,logging-gelf
include::{includes}/devtools/create-app.adoc[]

If you already have your Quarkus project configured, you can add the `logging-gelf` extension
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/cli-tooling.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ __ ____ __ _____ ___ __ ____ ______
--\___\_\____/_/ |_/_/|_/_/|_|\____/___/
2021-05-27 10:15:56,032 INFO [io.quarkus] (Quarkus Main Thread) code-with-quarkus 1.0.0-SNAPSHOT on JVM (powered by Quarkus 999-SNAPSHOT) started in 1.387s. Listening on: http://localhost:8080
2021-05-27 10:15:56,035 INFO [io.quarkus] (Quarkus Main Thread) Profile dev activated. Live Coding activated.
2021-05-27 10:15:56,035 INFO [io.quarkus] (Quarkus Main Thread) Installed features: [cdi, resteasy-reactive, smallrye-context-propagation]
2021-05-27 10:15:56,035 INFO [io.quarkus] (Quarkus Main Thread) Installed features: [cdi, rest, smallrye-context-propagation]

--
Tests paused, press [r] to resume
Expand Down
4 changes: 2 additions & 2 deletions docs/src/main/asciidoc/command-mode-reference.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ First, we need to create a new Quarkus project with the following command:
include::{includes}/devtools/create-app.adoc[]

NOTE: The suggested project creation command lines disable the codestarts to avoid including a REST server. Similarly, if you use code.quarkus.io to generate a
project, you need to go to *MORE OPTIONS -> Starter Code* and select *No* to avoid adding the RESTEasy Reactive extension.
project, you need to go to *MORE OPTIONS -> Starter Code* and select *No* to avoid adding the Quarkus REST (formerly RESTEasy Reactive) extension.

The RESTEasy Reactive extension is added automatically only if you ask for codestarts and you didn't specify any extensions.
The Quarkus REST extension is added automatically only if you ask for codestarts and you didn't specify any extensions.


== Writing Command Mode Applications
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/config.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ The solution is located in the `config-quickstart` link:{quickstarts-tree-url}/c
First, we need a new project. Create a new project with the following command:

:create-app-artifact-id: config-quickstart
:create-app-extensions: resteasy-reactive
:create-app-extensions: rest
include::{includes}/devtools/create-app.adoc[]

It generates:
Expand Down
14 changes: 7 additions & 7 deletions docs/src/main/asciidoc/context-propagation.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ include::_attributes.adoc[]
Traditional blocking code uses link:https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/ThreadLocal.html[`ThreadLocal`]
variables to store contextual objects in order to avoid
passing them as parameters everywhere. Many Quarkus extensions require those contextual objects to operate
properly: xref:rest-json.adoc[RESTEasy Reactive], xref:cdi-reference.adoc[ArC] and xref:transaction.adoc[Transaction]
properly: xref:rest-json.adoc[Quarkus REST (formerly RESTEasy Reactive)], xref:cdi-reference.adoc[ArC] and xref:transaction.adoc[Transaction]
for example.

If you write reactive/async code, you have to cut your work into a pipeline of code blocks that get executed
Expand Down Expand Up @@ -44,10 +44,10 @@ In other words, add the following dependencies to your build file:
[source,xml,role="primary asciidoc-tabs-target-sync-cli asciidoc-tabs-target-sync-maven"]
.pom.xml
----
<!-- RESTEasy Reactive extension if not already included -->
<!-- Quarkus REST extension if not already included -->
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-resteasy-reactive</artifactId>
<artifactId>quarkus-rest</artifactId>
</dependency>
<!-- Context Propagation extension -->
<dependency>
Expand All @@ -59,13 +59,13 @@ In other words, add the following dependencies to your build file:
[source,gradle,role="secondary asciidoc-tabs-target-sync-gradle"]
.build.gradle
----
// RESTEasy Reactive extension if not already included
implementation("io.quarkus:quarkus-resteasy-reactive")
// Quarkus REST extension if not already included
implementation("io.quarkus:quarkus-rest")
// Context Propagation extension
implementation("io.quarkus:quarkus-smallrye-context-propagation")
----

With this, you will get context propagation for ArC, RESTEasy Reactive and transactions, if you are using them.
With this, you will get context propagation for ArC, Quarkus REST and transactions, if you are using them.

== Usage example with Mutiny

Expand Down Expand Up @@ -218,7 +218,7 @@ their extensions:

|`Jakarta REST`
|N/A
|The RESTEasy Reactive or RESTEasy Classic context
|The Quarkus REST or RESTEasy Classic context

|`Application`
|https://javadoc.io/static/org.eclipse.microprofile.context-propagation/microprofile-context-propagation-api/1.2/org/eclipse/microprofile/context/ThreadContext.html#APPLICATION[`ThreadContext.APPLICATION`]
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/deploying-to-google-cloud.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ gcloud auth login
Quarkus supports deploying your application to Google Cloud Functions via the following extensions:

- xref:gcp-functions.adoc[Google Cloud Functions]: Build functions using the Google Cloud Functions API.
- xref:gcp-functions-http.adoc[Google Cloud Functions HTTP binding]: Build functions using Quarkus HTTP APIs: RESTEasy Reactive (Jakarta REST),
- xref:gcp-functions-http.adoc[Google Cloud Functions HTTP binding]: Build functions using Quarkus HTTP APIs: Quarkus REST (formerly RESTEasy Reactive, our Jakarta REST implementation),
Undertow (Servlet), Vert.x Web, or xref:funqy-http.adoc[Funqy HTTP].
- xref:funqy-gcp-functions.adoc[Funky Google Cloud Functions]: Build functions using Funqy.

Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/deploying-to-kubernetes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ include::{includes}/prerequisites.adoc[]
Let's create a new project that contains both the Kubernetes and Jib extensions:

:create-app-artifact-id: kubernetes-quickstart
:create-app-extensions: resteasy-reactive,kubernetes,jib
:create-app-extensions: rest,kubernetes,jib
:create-app-code:
include::{includes}/devtools/create-app.adoc[]

Expand All @@ -39,7 +39,7 @@ This added the following dependencies to the build file:
----
<dependency>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-resteasy-reactive</artifactId>
<artifactId>quarkus-rest</artifactId>
</dependency>
<dependency>
<groupId>io.quarkus</groupId>
Expand All @@ -54,7 +54,7 @@ This added the following dependencies to the build file:
[source,gradle,role="secondary asciidoc-tabs-target-sync-gradle"]
.build.gradle
----
implementation("io.quarkus:quarkus-resteasy-reactive")
implementation("io.quarkus:quarkus-rest")
implementation("io.quarkus:quarkus-kubernetes")
implementation("io.quarkus:quarkus-container-image-jib")
----
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/deploying-to-openshift.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ include::{includes}/prerequisites.adoc[]
First, we need a new project that contains the OpenShift extension. This can be done using the following command:

:create-app-artifact-id: openshift-quickstart
:create-app-extensions: resteasy-reactive,openshift
:create-app-extensions: rest,openshift
:create-app-code:
include::{includes}/devtools/create-app.adoc[]

Expand Down
8 changes: 4 additions & 4 deletions docs/src/main/asciidoc/duplicated-context.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ NOTE: This section is not an explanation of the reactive model. Refer to that xr
Under the hood, Quarkus uses a reactive engine.
This engine provides the efficiency and concurrency to cope with modern, containerized, and cloud-native applications.

For example, when you use RESTEasy Reactive or gRPC, Quarkus can invoke your business logic on I/O threads.
For example, when you use Quarkus REST (formerly RESTEasy Reactive) or gRPC, Quarkus can invoke your business logic on I/O threads.
These threads are named https://en.wikipedia.org/wiki/Event_loop[event loops] and implement a https://en.wikipedia.org/wiki/Reactor_pattern[multi-reactor pattern].

When using the imperative model, Quarkus associates a worker thread to each processing unit (like an HTTP request or a gRPC invocation).
Expand Down Expand Up @@ -176,7 +176,7 @@ You can mark a context _safe_.
It is meant for other extensions to integrate with to help identify which contexts are isolated and guarantee access by a unique thread.
Hibernate Reactive uses this feature to check if the current context is safe to store the currently opened session to protect users from mistakenly interleaving multiple reactive operations that could unintentionally share the same session.

Vert.x web will create a new duplicated context for each http web request; Quarkus RESTEasy Reactive will mark such contexts as safe.
Vert.x web will create a new duplicated context for each http web request; Quarkus REST will mark such contexts as safe.
Other extensions should follow a similar pattern when they are setting up a new context that is safe to be used for a local context guaranteeing sequential use, non-concurrent access, and scoped to the current reactive chain as a convenience not to have to pass a "context" object along explicitly.

In other cases, it might be helpful to mark the current context as not safe instead explicitly; for example, if an existing context needs to be shared across multiple workers to process some operations in parallel: by marking and un-marking appropriately the same
Expand All @@ -203,11 +203,11 @@ In general, Quarkus invokes reactive code on duplicated contexts.
So it can safely access the local data.
It is the case with:

- RESTEasy Reactive
- Quarkus REST
- gRPC
- Reactive Routes
- Vert.x Event Bus `@ConsumeEvent`
- Reactive REST Client
- REST Client
- Reactive Messaging (Kafka, AMQP)
- Funqy
- Quarkus scheduler and Quartz
Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/elasticsearch.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ The elements are stored in Elasticsearch.
First, we need a new project. Create a new project with the following command:

:create-app-artifact-id: elasticsearch-quickstart
:create-app-extensions: resteasy-reactive-jackson,elasticsearch-rest-client
:create-app-extensions: rest-jackson,elasticsearch-rest-client
include::{includes}/devtools/create-app.adoc[]

This command generates a Maven structure importing the RESTEasy Reactive, Jackson, and Elasticsearch low level REST client extensions.
This command generates a Maven structure importing the Quarkus REST (formerly RESTEasy Reactive), Jackson, and Elasticsearch low level REST client extensions.

The Elasticsearch low level REST client comes with the `quarkus-elasticsearch-rest-client` extension
that has been added to your build file.
Expand All @@ -55,7 +55,7 @@ If you want to use the Elasticsearch Java client instead, replace the `quarkus-e

[NOTE]
====
We use the `resteasy-reactive-jackson` extension here and not the JSON-B variant because we will use the Vert.x `JsonObject` helper
We use the `rest-jackson` extension here and not the JSON-B variant because we will use the Vert.x `JsonObject` helper
to serialize/deserialize our objects to/from Elasticsearch and it uses Jackson under the hood.
====

Expand Down
Loading

0 comments on commit a990a54

Please sign in to comment.