Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes to include usage in Quarkus docs #25915

Merged
merged 1 commit into from
Jun 3, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions docs/src/main/asciidoc/amazon-lambda-http.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ Amazon has a https://docs.aws.amazon.com/apigateway/latest/developerguide/http-a

Like most Quarkus extensions, the Quarkus AWS Lambda HTTP/REST extensions support Live Coding.

include::./status-include.adoc[]
include::{includes}/extension-status.adoc[]

== Prerequisites

:prerequisites-time: 30 minutes
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]
* https://aws.amazon.com[An Amazon AWS account]
* https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html[AWS SAM CLI]

Expand Down Expand Up @@ -68,7 +68,7 @@ mvn archetype:generate \

Build the project:

include::includes/devtools/build.adoc[]
include::{includes}/devtools/build.adoc[]

This will compile the code and run the unit tests included within the generated project.
Unit testing is the same as any other Java project and does not require running on Amazon. Quarkus dev mode is also
Expand All @@ -77,13 +77,13 @@ available with this extension.
If you want to build a native executable, make sure you have GraalVM installed correctly and just add a `native` property
to the build

include::includes/devtools/build-native.adoc[]
include::{includes}/devtools/build-native.adoc[]

NOTE: If you are building on a non-Linux system, you will need to also pass in a property instructing quarkus to use a Docker build as Amazon
Lambda requires Linux binaries. You can do this by passing `-Dquarkus.native.container-build=true` to your build command.
This requires you to have Docker installed locally, however.

include::includes/devtools/build-native-container.adoc[]
include::{includes}/devtools/build-native-container.adoc[]

== Extra Build Generated Files

Expand Down Expand Up @@ -216,7 +216,7 @@ you may need to manually manage that encoding.

To deploy a native executable, you must build it with GraalVM.

include::includes/devtools/build-native-container.adoc[]
include::{includes}/devtools/build-native-container.adoc[]

You can then test the executable locally with sam local

Expand Down
10 changes: 5 additions & 5 deletions docs/src/main/asciidoc/amazon-lambda.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ bring up your Quarkus lambda project in dev or test mode and code on your projec
== Prerequisites

:prerequisites-time: 30 minutes
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]
* https://aws.amazon.com[An Amazon AWS account]
* https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-install.html[AWS CLI]
* https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-sam-cli-install.html[AWS SAM CLI], for local testing
Expand Down Expand Up @@ -111,7 +111,7 @@ create, update, delete, and invoke your lambdas for pure Java and native deploym

Build the project:

include::includes/devtools/build.adoc[]
include::{includes}/devtools/build.adoc[]

This will compile and package your code.

Expand Down Expand Up @@ -232,13 +232,13 @@ code to a native executable. Just make sure to rebuild your project with the `-

For Linux hosts, execute:

include::includes/devtools/build-native.adoc[]
include::{includes}/devtools/build-native.adoc[]

NOTE: If you are building on a non-Linux system, you will need to also pass in a property instructing Quarkus to use a docker build as Amazon
Lambda requires linux binaries. You can do this by passing this property to your build:
`-Dquarkus.native.container-build=true`. This requires you to have Docker installed locally, however.

include::includes/devtools/build-native-container.adoc[]
include::{includes}/devtools/build-native-container.adoc[]

Either of these commands will compile and create a native executable image. It also generates a zip file `target/function.zip`.
This zip file contains your native executable image renamed to `bootstrap`. This is a requirement of the AWS Lambda
Expand Down Expand Up @@ -305,7 +305,7 @@ While running in Quarkus Dev Mode, you can feed events to it by doing an HTTP PO
The mock event server will receive the events and your lambda will be invoked. You can perform live coding on your lambda
and changes will automatically be recompiled and available the next invocation you make. Here's an example:

include::includes/devtools/dev.adoc[]
include::{includes}/devtools/dev.adoc[]

[source,bash]
----
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/amqp-reference.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ To use the connector, you need to add the `quarkus-smallrye-reactive-messaging-a
You can add the extension to your project using:

:add-extension-extensions: quarkus-smallrye-reactive-messaging-amqp
include::includes/devtools/extension-add.adoc[]
include::{includes}/devtools/extension-add.adoc[]

Or just add the following dependency to your project:

Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/amqp.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ documentation.
== Prerequisites

:prerequisites-docker-compose:
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]

== Architecture

Expand Down Expand Up @@ -57,7 +57,7 @@ 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-post-command:
include::includes/devtools/create-app.adoc[]
include::{includes}/devtools/create-app.adoc[]

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

Expand All @@ -69,7 +69,7 @@ To create the _processor_ project, from the same directory, run:
:create-app-artifact-id: amqp-quickstart-processor
:create-app-extensions: smallrye-reactive-messaging-amqp
:create-app-post-command:
include::includes/devtools/create-app.adoc[]
include::{includes}/devtools/create-app.adoc[]

At that point you should have the following structure:

Expand Down
1 change: 1 addition & 0 deletions docs/src/main/asciidoc/attributes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
:idseparator: -
:icons: font
:imagesdir: ./images
:includes: ./includes
4 changes: 2 additions & 2 deletions docs/src/main/asciidoc/azure-functions-http.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ Undertow (servlet), Reactive Routes, or xref:funqy-http.adoc[Funqy HTTP] and mak

One azure function deployment can represent any number of JAX-RS, servlet, Reactive Routes, or xref:funqy-http.adoc[Funqy HTTP] endpoints.

include::./status-include.adoc[]
include::{includes}/extension-status.adoc[]

NOTE: Only text based media types are supported at the moment as Azure Functions HTTP Trigger for Java does not support a binary format

== Prerequisites

include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]
* https://azure.microsoft.com[An Azure Account]. Free accounts work.
* https://docs.microsoft.com/en-us/cli/azure/install-azure-cli[Azure CLI Installed]

Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/building-my-first-extension.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Keep in mind it's not representative of the power of moving things to build time

:prerequisites-time: 30 minutes
:prerequisites-no-graalvm:
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]

== Basic Concepts

Expand Down
12 changes: 6 additions & 6 deletions docs/src/main/asciidoc/building-native-image.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ and https://github.com/graalvm/mandrel/releases[Mandrel releases].

:prerequisites-docker:
:prerequisites-graalvm-mandatory:
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]
* A xref:configuring-c-development[working C development environment]
* The code of the application developed in the xref:getting-started.adoc[Getting Started Guide].

Expand Down Expand Up @@ -197,7 +197,7 @@ this allows native image tests to also be run.

Create a native executable using:

include::includes/devtools/build-native.adoc[]
include::{includes}/devtools/build-native.adoc[]

[[graal-and-windows]]
[NOTE]
Expand Down Expand Up @@ -349,7 +349,7 @@ to install as little software as possible).
To this end, Quarkus provides a very convenient way of creating a native Linux executable by leveraging a container runtime such as Docker or podman.
The easiest way of accomplishing this task is to execute:

include::includes/devtools/build-native-container.adoc[]
include::{includes}/devtools/build-native-container.adoc[]

[TIP]
====
Expand All @@ -359,13 +359,13 @@ If you want to explicitely select the container runtime, you can do it with:
For Docker:

:build-additional-parameters: -Dquarkus.native.container-runtime=docker
include::includes/devtools/build-native-container-parameters.adoc[]
include::{includes}/devtools/build-native-container-parameters.adoc[]
:!build-additional-parameters:

For podman:

:build-additional-parameters: -Dquarkus.native.container-runtime=podman
include::includes/devtools/build-native-container-parameters.adoc[]
include::{includes}/devtools/build-native-container-parameters.adoc[]
:!build-additional-parameters:

These are normal Quarkus config properties, so if you always want to build in a container
Expand All @@ -389,7 +389,7 @@ The reason for this is that the local build driver invoked through `-Dquarkus.na
Building with Mandrel requires a custom builder image parameter to be passed additionally:

:build-additional-parameters: -Dquarkus.native.builder-image=quay.io/quarkus/ubi-quarkus-mandrel:{mandrel-flavor}
include::includes/devtools/build-native-container-parameters.adoc[]
include::{includes}/devtools/build-native-container-parameters.adoc[]
:!build-additional-parameters:

Please note that the above command points to a floating tag.
Expand Down
10 changes: 5 additions & 5 deletions docs/src/main/asciidoc/cache.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ include::./attributes.adoc[]

In this guide, you will learn how to enable application data caching in any CDI managed bean of your Quarkus application.

include::./status-include.adoc[]
include::{includes}/extension-status.adoc[]

== Prerequisites

include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]

== Scenario

Expand All @@ -39,15 +39,15 @@ 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
include::includes/devtools/create-app.adoc[]
include::{includes}/devtools/create-app.adoc[]

This command generates the project and imports the `cache` and `resteasy-reactive-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:

:add-extension-extensions: cache
include::includes/devtools/extension-add.adoc[]
include::{includes}/devtools/extension-add.adoc[]

This will add the following to your build file:

Expand Down Expand Up @@ -182,7 +182,7 @@ We're all done! Let's check if everything's working.

First, run the application using dev mode from the project directory:

include::includes/devtools/dev.adoc[]
include::{includes}/devtools/dev.adoc[]

Then, call `http://localhost:8080/weather?city=Raleigh` from a browser.
After six long seconds, the application will answer something like this:
Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/cassandra.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ include::./platform-include.adoc[]

== Prerequisites

include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]
* A running link:https://cassandra.apache.org[Apache Cassandra],
link:https://www.datastax.fr/products/datastax-enterprise[DataStax Enterprise] (DSE) or
link:https://astra.datastax.com[DataStax Astra] database; or alternatively, a fresh Docker
Expand Down
6 changes: 3 additions & 3 deletions docs/src/main/asciidoc/centralized-log-management.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ By default, it is disabled, if you enable it but still use another handler (by d
== Prerequisites

:prerequisites-docker-compose:
include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]

== Example application

Expand All @@ -29,13 +29,13 @@ Create an application with the `quarkus-logging-gelf` extension. You can use the

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

If you already have your Quarkus project configured, you can add the `logging-gelf` extension
to your project by running the following command in your project base directory:

:add-extension-extensions: logging-gelf
include::includes/devtools/extension-add.adoc[]
include::{includes}/devtools/extension-add.adoc[]

This will add the following dependency to your build file:

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 @@ -11,7 +11,7 @@ include::./attributes.adoc[]
The `quarkus` command lets you create projects, manage extensions and
do essential build and dev commands using the underlying project build tool.

include::./status-include.adoc[]
include::{includes}/extension-status.adoc[]

== Installing the CLI

Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/command-mode-reference.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ in order to unblock the main thread and initiate the shutdown process.
Also for command mode applications the dev mode is supported.
When you start your application in dev mode, the command mode application is executed:

include::includes/devtools/dev.adoc[]
include::{includes}/devtools/dev.adoc[]

As command mode applications will often require arguments to be passed on the command line, this is also possible in dev mode:

Expand Down
2 changes: 1 addition & 1 deletion docs/src/main/asciidoc/config-yaml.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Quarkus offers the possibility to use YAML in addition to the standard Java Prop
To enable YAML configuration, add the `quarkus-config-yaml` extension:

:add-extension-extensions: quarkus-config-yaml
include::includes/devtools/extension-add.adoc[]
include::{includes}/devtools/extension-add.adoc[]

You can also just add the following dependency into your project:

Expand Down
10 changes: 5 additions & 5 deletions docs/src/main/asciidoc/config.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ In this guide, we will learn how to configure a Quarkus application.

== Prerequisites

include::includes/devtools/prerequisites.adoc[]
include::{includes}/prerequisites.adoc[]

== Solution

Expand All @@ -34,7 +34,7 @@ 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
include::includes/devtools/create-app.adoc[]
include::{includes}/devtools/create-app.adoc[]

It generates:

Expand Down Expand Up @@ -164,7 +164,7 @@ public class GreetingResourceTest {

Run the application with:

include::includes/devtools/dev.adoc[]
include::{includes}/devtools/dev.adoc[]

Open your browser to http://localhost:8080/greeting.

Expand All @@ -173,13 +173,13 @@ You can add the `greeting.suffix`, remove the other properties, change the value

As usual, the application can be packaged using:

include::includes/devtools/build.adoc[]
include::{includes}/devtools/build.adoc[]

and executed using `java -jar target/quarkus-app/quarkus-run.jar`.

You can also generate the native executable with:

include::includes/devtools/build-native.adoc[]
include::{includes}/devtools/build-native.adoc[]

== Programmatically access the configuration

Expand Down
Loading