You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by lb...@apache.org on 2020/01/23 05:07:29 UTC

[camel-quarkus] branch master updated (0223c2b -> 7f9ec9c)

This is an automated email from the ASF dual-hosted git repository.

lburgazzoli pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git.


    from 0223c2b  Determine the Camel version at build time
     new 6bec185  Use application.properties rather than pom.xml for addAllCharsets
     new 7f9ec9c  Fix #599 Document the need to set quarkus.native.add-all-charsets = true in HTTP extensions

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 docs/modules/ROOT/nav.adoc                         |  1 +
 docs/modules/ROOT/pages/extensions/ahc.adoc        | 28 ++++++++++++++++++++++
 docs/modules/ROOT/pages/extensions/http.adoc       | 27 +++++++++++++++++++++
 docs/modules/ROOT/pages/extensions/netty-http.adoc |  4 ++++
 .../ROOT/pages/extensions/platform-http.adoc       |  6 +++++
 .../pages/list-of-camel-quarkus-extensions.adoc    |  4 ++--
 docs/modules/ROOT/pages/native-mode.adoc           | 25 +++++++++++++++++++
 extensions/readme.adoc                             |  4 ++--
 integration-tests/platform-http/pom.xml            |  1 -
 .../src/main/resources/application.properties      |  3 +++
 10 files changed, 98 insertions(+), 5 deletions(-)
 create mode 100644 docs/modules/ROOT/pages/extensions/ahc.adoc
 create mode 100644 docs/modules/ROOT/pages/extensions/http.adoc
 create mode 100644 docs/modules/ROOT/pages/native-mode.adoc


[camel-quarkus] 02/02: Fix #599 Document the need to set quarkus.native.add-all-charsets = true in HTTP extensions

Posted by lb...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

lburgazzoli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git

commit 7f9ec9cfe1c30765f3d554f561c28deabe0d5dff
Author: Peter Palaga <pp...@redhat.com>
AuthorDate: Tue Jan 21 11:49:07 2020 +0100

    Fix #599 Document the need to set quarkus.native.add-all-charsets = true in HTTP extensions
---
 docs/modules/ROOT/nav.adoc                         |  1 +
 docs/modules/ROOT/pages/extensions/ahc.adoc        | 28 ++++++++++++++++++++++
 docs/modules/ROOT/pages/extensions/http.adoc       | 27 +++++++++++++++++++++
 docs/modules/ROOT/pages/extensions/netty-http.adoc |  4 ++++
 .../ROOT/pages/extensions/platform-http.adoc       |  6 +++++
 .../pages/list-of-camel-quarkus-extensions.adoc    |  4 ++--
 docs/modules/ROOT/pages/native-mode.adoc           | 25 +++++++++++++++++++
 extensions/readme.adoc                             |  4 ++--
 8 files changed, 95 insertions(+), 4 deletions(-)

diff --git a/docs/modules/ROOT/nav.adoc b/docs/modules/ROOT/nav.adoc
index 8bf3411..bcb2e35 100644
--- a/docs/modules/ROOT/nav.adoc
+++ b/docs/modules/ROOT/nav.adoc
@@ -1,6 +1,7 @@
 * xref:user-guide.adoc[User guide]
 ** xref:first-steps.adoc[First steps]
 ** xref:cdi.adoc[CDI]
+** xref:native-mode.adoc[Native mode]
 ** xref:examples.adoc[Examples]
 * xref:contributor-guide.adoc[Contributor guide]
 * xref:list-of-camel-quarkus-extensions.adoc[List of Camel Quarkus extensions]
diff --git a/docs/modules/ROOT/pages/extensions/ahc.adoc b/docs/modules/ROOT/pages/extensions/ahc.adoc
new file mode 100644
index 0000000..8ea06a3
--- /dev/null
+++ b/docs/modules/ROOT/pages/extensions/ahc.adoc
@@ -0,0 +1,28 @@
+[[ahc]]
+= Async HTTP Client (AHC) Extension
+
+*Since Camel Quarkus 1.0.0*
+
+The AHC component provides HTTP based endpoints for consuming external HTTP resources (as a client to call external
+servers using HTTP). It is using the https://github.com/AsyncHttpClient/async-http-client[Async Http Client library]
+under the hood.
+
+Maven users will need to add the following dependency to their `pom.xml` for this extension.
+
+[source,xml]
+----
+<dependency>
+    <groupId>org.apache.camel.quarkus</groupId>
+    <artifactId>camel-quarkus-ahc</artifactId>
+</dependency>
+----
+
+== Usage
+
+Please refer to the https://camel.apache.org/components/latest/ahc-component.html[AHC] component page.
+
+
+== Configuration
+
+* Check the xref:native-mode.adoc#charsets[Character encodings section] of the Native mode guide if you expect
+  your application to send or receive requests using non-default encodings.
diff --git a/docs/modules/ROOT/pages/extensions/http.adoc b/docs/modules/ROOT/pages/extensions/http.adoc
new file mode 100644
index 0000000..06ac77c
--- /dev/null
+++ b/docs/modules/ROOT/pages/extensions/http.adoc
@@ -0,0 +1,27 @@
+[[http]]
+= HTTP Extension
+
+*Since Camel Quarkus 1.0.0*
+
+The HTTP component provides HTTP based endpoints for calling external HTTP resources (as a client to call external
+servers using HTTP).
+
+Maven users will need to add the following dependency to their `pom.xml` for this extension.
+
+[source,xml]
+----
+<dependency>
+    <groupId>org.apache.camel.quarkus</groupId>
+    <artifactId>camel-quarkus-http</artifactId>
+</dependency>
+----
+
+== Usage
+
+Please refer to the https://camel.apache.org/components/latest/http-component.html[HTTP] component page.
+
+
+== Configuration
+
+* Check the xref:native-mode.adoc#charsets[Character encodings section] of the Native mode guide if you expect
+  your application to send or receive requests using non-default encodings.
diff --git a/docs/modules/ROOT/pages/extensions/netty-http.adoc b/docs/modules/ROOT/pages/extensions/netty-http.adoc
index 23595bb..df899d6 100644
--- a/docs/modules/ROOT/pages/extensions/netty-http.adoc
+++ b/docs/modules/ROOT/pages/extensions/netty-http.adoc
@@ -42,3 +42,7 @@ public class CamelRoute extends RouteBuilder {
 }
 ----
 
+== Configuration
+
+* Check the xref:native-mode.adoc#charsets[Character encodings section] of the Native mode guide if you expect
+  your application to send or receive requests using non-default encodings.
diff --git a/docs/modules/ROOT/pages/extensions/platform-http.adoc b/docs/modules/ROOT/pages/extensions/platform-http.adoc
index 64e00e4..01b60b0 100644
--- a/docs/modules/ROOT/pages/extensions/platform-http.adoc
+++ b/docs/modules/ROOT/pages/extensions/platform-http.adoc
@@ -97,3 +97,9 @@ from("platform-http:/upload/multipart?fileNameExtWhitelist=adoc,txt&httpMethodRe
 
 Also check the `quarkus.http.body.*` configuration options in
 https://quarkus.io/guides/all-config[Quarkus documentation], esp. `quarkus.http.body.handle-file-uploads`, `quarkus.http.body.uploads-directory` and `quarkus.http.body.delete-uploaded-files-on-end`.
+
+
+== Configuration
+
+* Check the xref:native-mode.adoc#charsets[Character encodings section] of the Native mode guide if you expect
+  your application to send or receive requests using non-default encodings.
diff --git a/docs/modules/ROOT/pages/list-of-camel-quarkus-extensions.adoc b/docs/modules/ROOT/pages/list-of-camel-quarkus-extensions.adoc
index cdc5eee..7c22ea0 100644
--- a/docs/modules/ROOT/pages/list-of-camel-quarkus-extensions.adoc
+++ b/docs/modules/ROOT/pages/list-of-camel-quarkus-extensions.adoc
@@ -21,7 +21,7 @@ Number of Camel components: 60 in 51 JAR artifacts (0 deprecated)
 |===
 | Component | Since | Description
 
-| link:https://camel.apache.org/components/latest/ahc-component.html[AHC] (camel-quarkus-ahc) +
+| xref:extensions/ahc.adoc[AHC] (camel-quarkus-ahc) +
 `ahc:httpUri` | 1.2.0 | To call external HTTP services using Async Http Client.
 
 | link:https://camel.apache.org/components/latest/ahc-ws-component.html[AHC Websocket] (camel-quarkus-ahc-ws) +
@@ -102,7 +102,7 @@ Number of Camel components: 60 in 51 JAR artifacts (0 deprecated)
 | link:https://camel.apache.org/components/latest/ftps-component.html[FTPS] (camel-quarkus-ftp) +
 `ftps:host:port/directoryName` | 1.0.0-M1 | The \ftps (FTP secure SSL/TLS) component is used for uploading or downloading files from FTP servers.
 
-| link:https://camel.apache.org/components/latest/http-component.html[HTTP] (camel-quarkus-http) +
+| xref:extensions/http.adoc[HTTP] (camel-quarkus-http) +
 `http:httpUri` | 1.0.0 | For calling out to external HTTP servers using Apache HTTP Client 4.x.
 
 | link:https://camel.apache.org/components/latest/infinispan-component.html[Infinispan] (camel-quarkus-infinispan) +
diff --git a/docs/modules/ROOT/pages/native-mode.adoc b/docs/modules/ROOT/pages/native-mode.adoc
new file mode 100644
index 0000000..f1f8d73
--- /dev/null
+++ b/docs/modules/ROOT/pages/native-mode.adoc
@@ -0,0 +1,25 @@
+= Native mode
+
+Things to consider before you run your application in the native mode.
+
+[[charsets]]
+== Character encodings
+
+By default only a the following `Charsets` are available in the native mode (https://github.com/oracle/graal/blob/vm-19.3.0/substratevm/src/com.oracle.svm.core/src/com/oracle/svm/core/jdk/LocalizationFeature.java#L149-L163[source]):
+
+[code,text]
+----
+Charset.defaultCharset(), US-ASCII, ISO-8859-1, UTF-8, UTF-16BE, UTF-16LE, UTF-16
+----
+
+If you expect your application to need any encoding not included in this set or if you see
+an `UnsupportedCharsetException` thrown in the native mode, please add the following entry to your
+`application.properties`:
+
+[code,properties]
+----
+quarkus.native.add-all-charsets = true
+----
+
+See also https://quarkus.io/guides/all-config#quarkus-core_quarkus.native.add-all-charsets[quarkus.native.add-all-charsets]
+in Quarkus documentation.
diff --git a/extensions/readme.adoc b/extensions/readme.adoc
index 2a78678..9a2f8f3 100644
--- a/extensions/readme.adoc
+++ b/extensions/readme.adoc
@@ -11,7 +11,7 @@ Number of Camel components: 60 in 51 JAR artifacts (0 deprecated)
 |===
 | Component | Since | Description
 
-| link:https://camel.apache.org/components/latest/ahc-component.html[AHC] (camel-quarkus-ahc) +
+| xref:extensions/ahc.adoc[AHC] (camel-quarkus-ahc) +
 `ahc:httpUri` | 1.2.0 | To call external HTTP services using Async Http Client.
 
 | link:https://camel.apache.org/components/latest/ahc-ws-component.html[AHC Websocket] (camel-quarkus-ahc-ws) +
@@ -92,7 +92,7 @@ Number of Camel components: 60 in 51 JAR artifacts (0 deprecated)
 | link:https://camel.apache.org/components/latest/ftps-component.html[FTPS] (camel-quarkus-ftp) +
 `ftps:host:port/directoryName` | 1.0.0-M1 | The \ftps (FTP secure SSL/TLS) component is used for uploading or downloading files from FTP servers.
 
-| link:https://camel.apache.org/components/latest/http-component.html[HTTP] (camel-quarkus-http) +
+| xref:extensions/http.adoc[HTTP] (camel-quarkus-http) +
 `http:httpUri` | 1.0.0 | For calling out to external HTTP servers using Apache HTTP Client 4.x.
 
 | link:https://camel.apache.org/components/latest/infinispan-component.html[Infinispan] (camel-quarkus-infinispan) +


[camel-quarkus] 01/02: Use application.properties rather than pom.xml for addAllCharsets

Posted by lb...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

lburgazzoli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git

commit 6bec1855b28d5c8ea63836090aea80004586dfd4
Author: Peter Palaga <pp...@redhat.com>
AuthorDate: Mon Jan 20 11:51:32 2020 +0100

    Use application.properties rather than pom.xml for addAllCharsets
---
 integration-tests/platform-http/pom.xml                                | 1 -
 .../platform-http/src/main/resources/application.properties            | 3 +++
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/integration-tests/platform-http/pom.xml b/integration-tests/platform-http/pom.xml
index a966ba5..ae09986 100644
--- a/integration-tests/platform-http/pom.xml
+++ b/integration-tests/platform-http/pom.xml
@@ -128,7 +128,6 @@
                                     <enableJni>true</enableJni>
                                     <enableAllSecurityServices>true</enableAllSecurityServices>
                                     <disableReports>true</disableReports>
-                                    <addAllCharsets>true</addAllCharsets><!-- Required by the encoding() test -->
                                 </configuration>
                             </execution>
                         </executions>
diff --git a/integration-tests/platform-http/src/main/resources/application.properties b/integration-tests/platform-http/src/main/resources/application.properties
index 33ed67b..f6591cf 100644
--- a/integration-tests/platform-http/src/main/resources/application.properties
+++ b/integration-tests/platform-http/src/main/resources/application.properties
@@ -22,3 +22,6 @@ quarkus.http.body.uploads-directory=target/uploads
 quarkus.log.file.enable = false
 quarkus.log.category."org.apache.camel.quarkus.core.deployment".level = INFO
 quarkus.log.category."org.apache.camel.quarkus.component.platform.http".level = INFO
+
+# Required by the encoding() test
+quarkus.native.add-all-charsets = true