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

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 507017ec5b6 CAMEL-18015: camel-jt400 - Endpoint syntax is wrong in 
metadata
507017ec5b6 is described below

commit 507017ec5b647ab57e3d6caa4972142eed70f17c
Author: Claus Ibsen <[email protected]>
AuthorDate: Tue Apr 26 18:43:35 2022 +0200

    CAMEL-18015: camel-jt400 - Endpoint syntax is wrong in metadata
---
 .../org/apache/camel/catalog/components/jt400.json         |  2 +-
 .../apache/camel/catalog/CamelCatalogJsonSchemaTest.java   | 14 +++++++++++++-
 .../camel/component/jt400/Jt400EndpointUriFactory.java     |  2 +-
 .../resources/org/apache/camel/component/jt400/jt400.json  |  2 +-
 components/camel-jt400/src/main/docs/jt400-component.adoc  |  6 +++---
 .../org/apache/camel/component/jt400/Jt400Endpoint.java    |  2 +-
 .../src/generated/resources/metadata.json                  |  2 +-
 .../camel/builder/endpoint/StaticEndpointBuilders.java     | 10 ++++++----
 .../builder/endpoint/dsl/Jt400EndpointBuilderFactory.java  | 10 ++++++----
 9 files changed, 33 insertions(+), 17 deletions(-)

diff --git 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jt400.json
 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jt400.json
index 145c96fdf3c..15e5178cacb 100644
--- 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jt400.json
+++ 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jt400.json
@@ -14,7 +14,7 @@
     "version": "3.17.0-SNAPSHOT",
     "scheme": "jt400",
     "extendsScheme": "",
-    "syntax": "jt400:userID:password\/systemName\/objectPath.type",
+    "syntax": "jt400:userID:password@systemName\/QSYS.LIB\/objectPath.type",
     "async": false,
     "api": false,
     "consumerOnly": false,
diff --git 
a/catalog/camel-catalog/src/test/java/org/apache/camel/catalog/CamelCatalogJsonSchemaTest.java
 
b/catalog/camel-catalog/src/test/java/org/apache/camel/catalog/CamelCatalogJsonSchemaTest.java
index d5583f0aa29..d1956c595e4 100644
--- 
a/catalog/camel-catalog/src/test/java/org/apache/camel/catalog/CamelCatalogJsonSchemaTest.java
+++ 
b/catalog/camel-catalog/src/test/java/org/apache/camel/catalog/CamelCatalogJsonSchemaTest.java
@@ -75,7 +75,19 @@ public class CamelCatalogJsonSchemaTest {
                 }
             }
         }
-        List<String> syntaxParts = Arrays.asList(syntax.split("[/:#.]"));
+        // special for jt400
+        List<String> syntaxParts;
+        if ("jt400".equals(name)) {
+            syntaxParts = new ArrayList<>();
+            syntaxParts.add("jt400");
+            syntaxParts.add("userID");
+            syntaxParts.add("password");
+            syntaxParts.add("systemName");
+            syntaxParts.add("objectPath");
+            syntaxParts.add("type");
+        } else {
+            syntaxParts = Arrays.asList(syntax.split("[/:#.]"));
+        }
         assertEquals(name, syntaxParts.get(0), "Syntax must start with 
component name");
 
         for (String part : syntaxParts.subList(1, syntaxParts.size())) {
diff --git 
a/components/camel-jt400/src/generated/java/org/apache/camel/component/jt400/Jt400EndpointUriFactory.java
 
b/components/camel-jt400/src/generated/java/org/apache/camel/component/jt400/Jt400EndpointUriFactory.java
index 75e7cd0be9b..85611814ce9 100644
--- 
a/components/camel-jt400/src/generated/java/org/apache/camel/component/jt400/Jt400EndpointUriFactory.java
+++ 
b/components/camel-jt400/src/generated/java/org/apache/camel/component/jt400/Jt400EndpointUriFactory.java
@@ -15,7 +15,7 @@ import org.apache.camel.spi.EndpointUriFactory;
  */
 public class Jt400EndpointUriFactory extends 
org.apache.camel.support.component.EndpointUriFactorySupport implements 
EndpointUriFactory {
 
-    private static final String BASE = 
":userID:password/systemName/objectPath.type";
+    private static final String BASE = 
":userID:password@systemName/QSYS.LIB/objectPath.type";
 
     private static final Set<String> PROPERTY_NAMES;
     private static final Set<String> SECRET_PROPERTY_NAMES;
diff --git 
a/components/camel-jt400/src/generated/resources/org/apache/camel/component/jt400/jt400.json
 
b/components/camel-jt400/src/generated/resources/org/apache/camel/component/jt400/jt400.json
index 145c96fdf3c..15e5178cacb 100644
--- 
a/components/camel-jt400/src/generated/resources/org/apache/camel/component/jt400/jt400.json
+++ 
b/components/camel-jt400/src/generated/resources/org/apache/camel/component/jt400/jt400.json
@@ -14,7 +14,7 @@
     "version": "3.17.0-SNAPSHOT",
     "scheme": "jt400",
     "extendsScheme": "",
-    "syntax": "jt400:userID:password\/systemName\/objectPath.type",
+    "syntax": "jt400:userID:password@systemName\/QSYS.LIB\/objectPath.type",
     "async": false,
     "api": false,
     "consumerOnly": false,
diff --git a/components/camel-jt400/src/main/docs/jt400-component.adoc 
b/components/camel-jt400/src/main/docs/jt400-component.adoc
index b78b24d816c..63d446aca7f 100644
--- a/components/camel-jt400/src/main/docs/jt400-component.adoc
+++ b/components/camel-jt400/src/main/docs/jt400-component.adoc
@@ -35,19 +35,19 @@ for this component:
 To send or receive data from a data queue
 
 ----------------------------------------------------------------------
-jt400://user:password@system/QSYS.LIB/LIBRARY.LIB/QUEUE.DTAQ[?options]
+jt400://user:password/system/QSYS.LIB/library.LIB/queue.DTAQ[?options]
 ----------------------------------------------------------------------
 
 To send or receive messages from a message queue
 
 ----------------------------------------------------------------------
-jt400://user:password@system/QSYS.LIB/LIBRARY.LIB/QUEUE.MSGQ[?options]
+jt400://user:password/system/QSYS.LIB/library.LIB/queue.MSGQ[?options]
 ----------------------------------------------------------------------
 
 To call program
 
 -----------------------------------------------------------------------
-jt400://user:password@system/QSYS.LIB/LIBRARY.LIB/program.PGM[?options]
+jt400://user:password/system/QSYS.LIB/library.LIB/program.PGM[?options]
 -----------------------------------------------------------------------
 
 
diff --git 
a/components/camel-jt400/src/main/java/org/apache/camel/component/jt400/Jt400Endpoint.java
 
b/components/camel-jt400/src/main/java/org/apache/camel/component/jt400/Jt400Endpoint.java
index c8f2fbdf57f..794ebd669e4 100644
--- 
a/components/camel-jt400/src/main/java/org/apache/camel/component/jt400/Jt400Endpoint.java
+++ 
b/components/camel-jt400/src/main/java/org/apache/camel/component/jt400/Jt400Endpoint.java
@@ -40,7 +40,7 @@ import org.apache.camel.util.URISupport;
  * for AS/400 and iSeries servers.
  */
 @UriEndpoint(firstVersion = "1.5.0", scheme = "jt400", title = "JT400",
-             syntax = "jt400:userID:password/systemName/objectPath.type", 
category = { Category.MESSAGING },
+             syntax = 
"jt400:userID:password@systemName/QSYS.LIB/objectPath.type", category = { 
Category.MESSAGING },
              headersClass = Jt400Constants.class)
 public class Jt400Endpoint extends ScheduledPollEndpoint implements 
MultipleConsumersSupport {
 
diff --git a/dsl/camel-componentdsl/src/generated/resources/metadata.json 
b/dsl/camel-componentdsl/src/generated/resources/metadata.json
index 2e671a7a807..72f63a08646 100644
--- a/dsl/camel-componentdsl/src/generated/resources/metadata.json
+++ b/dsl/camel-componentdsl/src/generated/resources/metadata.json
@@ -4100,7 +4100,7 @@
     "version": "3.17.0-SNAPSHOT",
     "scheme": "jt400",
     "extendsScheme": "",
-    "syntax": "jt400:userID:password\/systemName\/objectPath.type",
+    "syntax": "jt400:userID:password@systemName\/QSYS.LIB\/objectPath.type",
     "async": false,
     "api": false,
     "consumerOnly": false,
diff --git 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
index db31f9437f3..c88406eadc5 100644
--- 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
+++ 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
@@ -8442,7 +8442,8 @@ public class StaticEndpointBuilders {
      * Since: 1.5
      * Maven coordinates: org.apache.camel:camel-jt400
      * 
-     * Syntax: <code>jt400:userID:password/systemName/objectPath.type</code>
+     * Syntax:
+     * <code>jt400:userID:password@systemName/QSYS.LIB/objectPath.type</code>
      * 
      * Path parameter: userID (required)
      * Returns the ID of the IBM i user.
@@ -8461,7 +8462,7 @@ public class StaticEndpointBuilders {
      * Whether to work with data queues or remote program call
      * There are 4 enums and the value can be one of: DTAQ, PGM, SRVPGM, MSGQ
      * 
-     * @param path userID:password/systemName/objectPath.type
+     * @param path userID:password@systemName/QSYS.LIB/objectPath.type
      * @return the dsl builder
      */
     public static 
org.apache.camel.builder.endpoint.dsl.Jt400EndpointBuilderFactory.Jt400EndpointBuilder
 jt400(
@@ -8478,7 +8479,8 @@ public class StaticEndpointBuilders {
      * Since: 1.5
      * Maven coordinates: org.apache.camel:camel-jt400
      * 
-     * Syntax: <code>jt400:userID:password/systemName/objectPath.type</code>
+     * Syntax:
+     * <code>jt400:userID:password@systemName/QSYS.LIB/objectPath.type</code>
      * 
      * Path parameter: userID (required)
      * Returns the ID of the IBM i user.
@@ -8499,7 +8501,7 @@ public class StaticEndpointBuilders {
      * 
      * @param componentName to use a custom component name for the endpoint
      * instead of the default name
-     * @param path userID:password/systemName/objectPath.type
+     * @param path userID:password@systemName/QSYS.LIB/objectPath.type
      * @return the dsl builder
      */
     public static 
org.apache.camel.builder.endpoint.dsl.Jt400EndpointBuilderFactory.Jt400EndpointBuilder
 jt400(
diff --git 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Jt400EndpointBuilderFactory.java
 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Jt400EndpointBuilderFactory.java
index e3847e9424d..889f990d0a0 100644
--- 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Jt400EndpointBuilderFactory.java
+++ 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/Jt400EndpointBuilderFactory.java
@@ -1558,7 +1558,8 @@ public interface Jt400EndpointBuilderFactory {
          * Since: 1.5
          * Maven coordinates: org.apache.camel:camel-jt400
          * 
-         * Syntax: 
<code>jt400:userID:password/systemName/objectPath.type</code>
+         * Syntax:
+         * 
<code>jt400:userID:password@systemName/QSYS.LIB/objectPath.type</code>
          * 
          * Path parameter: userID (required)
          * Returns the ID of the IBM i user.
@@ -1578,7 +1579,7 @@ public interface Jt400EndpointBuilderFactory {
          * There are 4 enums and the value can be one of: DTAQ, PGM, SRVPGM,
          * MSGQ
          * 
-         * @param path userID:password/systemName/objectPath.type
+         * @param path userID:password@systemName/QSYS.LIB/objectPath.type
          * @return the dsl builder
          */
         default Jt400EndpointBuilder jt400(String path) {
@@ -1594,7 +1595,8 @@ public interface Jt400EndpointBuilderFactory {
          * Since: 1.5
          * Maven coordinates: org.apache.camel:camel-jt400
          * 
-         * Syntax: 
<code>jt400:userID:password/systemName/objectPath.type</code>
+         * Syntax:
+         * 
<code>jt400:userID:password@systemName/QSYS.LIB/objectPath.type</code>
          * 
          * Path parameter: userID (required)
          * Returns the ID of the IBM i user.
@@ -1616,7 +1618,7 @@ public interface Jt400EndpointBuilderFactory {
          * 
          * @param componentName to use a custom component name for the endpoint
          * instead of the default name
-         * @param path userID:password/systemName/objectPath.type
+         * @param path userID:password@systemName/QSYS.LIB/objectPath.type
          * @return the dsl builder
          */
         default Jt400EndpointBuilder jt400(String componentName, String path) {

Reply via email to