[GitHub] [camel-quarkus] github-actions[bot] opened a new issue #1148: [CI] - Quarkus Master Branch Build Failure

2020-04-25 Thread GitBox


github-actions[bot] opened a new issue #1148:
URL: https://github.com/apache/camel-quarkus/issues/1148


   The 
[quarkus-master](https://github.com/apache/camel-quarkus/tree/quarkus-master) 
branch build is failing:
   
   * Build ID: 87954770-3-c988ac20-51e5-48de-97d2-a17a8afa1977
   * Commit: e097e5b35cce4341c58028b69629d5bc744c7a88
   
   * Link to build: 
https://github.com/apache/camel-quarkus/actions/runs/87954770
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[camel-spring-boot] branch automatic-periodic-sync updated (3112277 -> d06e32d)

2020-04-25 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch automatic-periodic-sync
in repository https://gitbox.apache.org/repos/asf/camel-spring-boot.git.


omit 3112277  [create-pull-request] automated change
 add 1c9dce7  [create-pull-request] automated change
 add d06e32d  [create-pull-request] automated change

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (3112277)
\
 N -- N -- N   refs/heads/automatic-periodic-sync (d06e32d)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

No new revisions were added by this update.

Summary of changes:
 .../resources/org/apache/camel/springboot/catalog/components/sftp.json   | 1 +
 1 file changed, 1 insertion(+)



[GitHub] [camel-spring-boot] github-actions[bot] opened a new pull request #56: [Github Actions] Periodic Sync Camel Spring Boot Master Branch

2020-04-25 Thread GitBox


github-actions[bot] opened a new pull request #56:
URL: https://github.com/apache/camel-spring-boot/pull/56


   Periodic Sync of Camel Spring Boot Master Branch with main Camel Master.
   see 
https://github.com/apache/camel-spring-boot/blob/master/.github/workflows/automatic-sync-master.yml



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [camel-k] michaelwjoyner opened a new issue #1429: Vanilla Minishift install not working.

2020-04-25 Thread GitBox


michaelwjoyner opened a new issue #1429:
URL: https://github.com/apache/camel-k/issues/1429


   Syndesis is already installed fwiw.
   
   I followed the step guide and the CRD is having problems. I am new to 
Minishift so I might have problems diagnosis obvious things.
   
   
![image](https://user-images.githubusercontent.com/17679881/80293490-a4ab3200-8714-11ea-8001-c9de93367080.png)
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[camel-kafka-connector] branch master updated (11eafb9 -> 8e7b7cd)

2020-04-25 Thread valdar
This is an automated email from the ASF dual-hosted git repository.

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


from 11eafb9  Fixed github action issue with never released builts.
 new e9df138  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0
 new 8e7b7cd  [maven-release-plugin] prepare for next development iteration

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:
 buildingtools/pom.xml   | 2 +-
 connectors/camel-activemq-kafka-connector/pom.xml   | 2 +-
 connectors/camel-ahc-kafka-connector/pom.xml| 2 +-
 connectors/camel-ahc-ws-kafka-connector/pom.xml | 2 +-
 connectors/camel-ahc-wss-kafka-connector/pom.xml| 2 +-
 connectors/camel-amqp-kafka-connector/pom.xml   | 2 +-
 connectors/camel-apns-kafka-connector/pom.xml   | 2 +-
 connectors/camel-as2-kafka-connector/pom.xml| 2 +-
 connectors/camel-asterisk-kafka-connector/pom.xml   | 2 +-
 connectors/camel-atmos-kafka-connector/pom.xml  | 2 +-
 connectors/camel-atmosphere-websocket-kafka-connector/pom.xml   | 2 +-
 connectors/camel-atom-kafka-connector/pom.xml   | 2 +-
 connectors/camel-atomix-map-kafka-connector/pom.xml | 2 +-
 connectors/camel-atomix-messaging-kafka-connector/pom.xml   | 2 +-
 connectors/camel-atomix-multimap-kafka-connector/pom.xml| 2 +-
 connectors/camel-atomix-queue-kafka-connector/pom.xml   | 2 +-
 connectors/camel-atomix-set-kafka-connector/pom.xml | 2 +-
 connectors/camel-atomix-value-kafka-connector/pom.xml   | 2 +-
 connectors/camel-avro-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws-cw-kafka-connector/pom.xml | 2 +-
 connectors/camel-aws-ddb-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-ddbstream-kafka-connector/pom.xml  | 2 +-
 connectors/camel-aws-ec2-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-ecs-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-eks-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-iam-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-kinesis-firehose-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws-kinesis-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-kms-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-lambda-kafka-connector/pom.xml | 2 +-
 connectors/camel-aws-mq-kafka-connector/pom.xml | 2 +-
 connectors/camel-aws-msk-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-s3-kafka-connector/pom.xml | 2 +-
 connectors/camel-aws-sdb-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-ses-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-sns-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-sqs-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-swf-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws-translate-kafka-connector/pom.xml  | 2 +-
 connectors/camel-aws2-cw-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws2-ddb-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-ddbstream-kafka-connector/pom.xml | 2 +-
 connectors/camel-aws2-ec2-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-ecs-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-eks-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-iam-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-kms-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-mq-kafka-connector/pom.xml| 2 +-
 connectors/camel-aws2-msk-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-ses-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-sns-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-sqs-kafka-connector/pom.xml   | 2 +-
 connectors/camel-aws2-translate-kafka-connector/pom.xml | 2 +-
 connectors/camel-azure-blob-kafka-connector/pom.xml | 2 +-
 connectors/camel-azure-queue-kafka-connector/pom.xml| 2 +-
 connectors/camel-bean-kafka-connector/pom.xml   | 2 +-
 connectors/camel-bean-validator-kafka-connector/pom.xml

[GitHub] [camel-kafka-connector] valdar opened a new pull request #154: Release0.1.0

2020-04-25 Thread GitBox


valdar opened a new pull request #154:
URL: https://github.com/apache/camel-kafka-connector/pull/154


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[camel-kafka-connector] branch release0.1.0 created (now c22cbff)

2020-04-25 Thread valdar
This is an automated email from the ASF dual-hosted git repository.

valdar pushed a change to branch release0.1.0
in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git.


  at c22cbff  [maven-release-plugin] prepare for next development iteration

No new revisions were added by this update.



[camel-kafka-connector] branch master updated (8629ba3 -> 11eafb9)

2020-04-25 Thread valdar
This is an automated email from the ASF dual-hosted git repository.

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


from 8629ba3  Merge pull request #152 from apache/oscerd-patch-1
 add 11eafb9  Fixed github action issue with never released builts.

No new revisions were added by this update.

Summary of changes:
 .github/workflows/master-pr-build.yml   | 2 +-
 .github/workflows/master-push-build.yml | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)



[camel-kafka-connector] branch master updated (a9d6041 -> 8629ba3)

2020-04-25 Thread acosentino
This is an automated email from the ASF dual-hosted git repository.

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


from a9d6041  Moved from camel-core to camel-core-engine as a dependecnies. 
Removed unused dependencies.
 add 2839510  Upgrade testcontainers to version 1.14.1
 add 8629ba3  Merge pull request #152 from apache/oscerd-patch-1

No new revisions were added by this update.

Summary of changes:
 parent/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



[GitHub] [camel-kafka-connector] valdar opened a new pull request #153: Fixed github action issue with never released builts.

2020-04-25 Thread GitBox


valdar opened a new pull request #153:
URL: https://github.com/apache/camel-kafka-connector/pull/153


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[camel-kafka-connector] branch oscerd-patch-1 created (now 2839510)

2020-04-25 Thread acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a change to branch oscerd-patch-1
in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git.


  at 2839510  Upgrade testcontainers to version 1.14.1

This branch includes the following new commits:

 new 2839510  Upgrade testcontainers to version 1.14.1

The 1 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.




[camel-kafka-connector] 01/01: Upgrade testcontainers to version 1.14.1

2020-04-25 Thread acosentino
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch oscerd-patch-1
in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git

commit 28395100dc2d904f1cdefa4a84dd584ed98c72b9
Author: Andrea Cosentino 
AuthorDate: Sat Apr 25 19:58:40 2020 +0200

Upgrade testcontainers to version 1.14.1
---
 parent/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/parent/pom.xml b/parent/pom.xml
index 9119a55..e5c0624 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -49,7 +49,7 @@
 2.22.2
 3.0.0-M4
 2.12.4
-1.14.0
+1.14.1
 0.50.0
 
1.6.0
 



[GitHub] [camel-kafka-connector] oscerd opened a new pull request #152: Upgrade testcontainers to version 1.14.1

2020-04-25 Thread GitBox


oscerd opened a new pull request #152:
URL: https://github.com/apache/camel-kafka-connector/pull/152


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [camel-kafka-connector] valdar opened a new pull request #151: Release0.1.0

2020-04-25 Thread GitBox


valdar opened a new pull request #151:
URL: https://github.com/apache/camel-kafka-connector/pull/151


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[camel-website] branch master updated: upgrade antora, simplify xref-check dependencies, remove unneeded attribute

2020-04-25 Thread djencks
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new f0966a4  upgrade antora, simplify xref-check dependencies, remove 
unneeded attribute
f0966a4 is described below

commit f0966a432bfbbee7a20568dc2f55e126b1fde032
Author: David Jencks 
AuthorDate: Fri Apr 24 21:06:17 2020 -0700

upgrade antora, simplify xref-check dependencies, remove unneeded attribute
---
 antora-playbook.yml |   1 -
 package.json|  21 +++-
 yarn.lock   | 145 ++--
 3 files changed, 80 insertions(+), 87 deletions(-)

diff --git a/antora-playbook.yml b/antora-playbook.yml
index 56f1a01..83014a9 100644
--- a/antora-playbook.yml
+++ b/antora-playbook.yml
@@ -71,5 +71,4 @@ asciidoc:
 - ./extensions/inline-styles.js
 - "@djencks/asciidoctor-antora-indexer"
   attributes:
-camel-quarkus-last-release: 1.0.0-M6
 eip-vc: latest@components
diff --git a/package.json b/package.json
index fcfd3a7..bdbfde3 100644
--- a/package.json
+++ b/package.json
@@ -15,13 +15,13 @@
 "checks": "run-s check:*"
   },
   "devDependencies": {
-"@antora/asciidoc-loader": "2.3.0-beta.2",
-"@antora/cli": "2.3.0-beta.2",
-"@antora/content-aggregator": "2.3.0-beta.2",
-"@antora/content-classifier": "2.3.0-beta.2",
-"@antora/document-converter": "2.3.0-beta.2",
-"@antora/playbook-builder": "2.3.0-beta.2",
-"@antora/site-generator-default": "2.3.0-beta.2",
+"@antora/asciidoc-loader": "2.3.0",
+"@antora/cli": "2.3.0",
+"@antora/content-aggregator": "2.3.0",
+"@antora/content-classifier": "2.3.0",
+"@antora/document-converter": "2.3.0",
+"@antora/playbook-builder": "2.3.0",
+"@antora/site-generator-default": "2.3.0",
 "@antora/xref-validator": "gitlab:antora/xref-validator",
 "@djencks/asciidoctor-antora-indexer": "^0.0.2",
 "escape-string-regexp": "~2.0",
@@ -34,13 +34,6 @@
 "opal-runtime": "1.0.11",
 "toml": "~3.0"
   },
-  "resolutions": {
-"@antora/asciidoc-loader": "2.3.0-beta.2",
-"@antora/content-aggregator": "2.3.0-beta.2",
-"@antora/content-classifier": "2.3.0-beta.2",
-"@antora/document-converter": "2.3.0-beta.2",
-"@antora/playbook-builder": "2.3.0-beta.2"
-  },
   "installConfig": {
 "pnp": true
   }
diff --git a/yarn.lock b/yarn.lock
index 15b510d..9b6e2d4 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -2,25 +2,26 @@
 # yarn lockfile v1
 
 
-"@antora/asciidoc-loader@2.3.0-beta.2":
-  version "2.3.0-beta.2"
-  resolved 
"https://registry.yarnpkg.com/@antora/asciidoc-loader/-/asciidoc-loader-2.3.0-beta.2.tgz#62612b055eaa6576426b45495df7679bf6e08274;
-  integrity 
sha512-AHQIQfBaPjjWR27LllnzfAwRrwE6a03v9/bBjoLIaswA0XrSQ0UZXXvS8DRIWIG0ySxkpsCIcrJQp5WkQFsKTQ==
+"@antora/asciidoc-loader@2.3.0":
+  version "2.3.0"
+  resolved 
"https://registry.yarnpkg.com/@antora/asciidoc-loader/-/asciidoc-loader-2.3.0.tgz#e9917dd0a61ede76b337f32ac59abc27d3398f8f;
+  integrity 
sha512-mncSlmkk6rYH5SGplZtHjuieG3ve5bhm4x0f9WIFE+GhqajIogDjxTBNWNr9B2dVA4bMves7Sy+c5h+f9V3iVw==
   dependencies:
 asciidoctor.js "1.5.9"
+opal-runtime "1.0.11"
 
-"@antora/cli@2.3.0-beta.2":
-  version "2.3.0-beta.2"
-  resolved 
"https://registry.yarnpkg.com/@antora/cli/-/cli-2.3.0-beta.2.tgz#bfa77269e0576e15221c84f8423a4c5074daee44;
-  integrity 
sha512-bL2ZvGVxdvNWS+LlYV0MQp+8hEiIgMN/qK4mMJRuoiGFPXRk5HVa2Gks84A1vcMr4o0ZWAypkxq/D1TMcBGu9w==
+"@antora/cli@2.3.0":
+  version "2.3.0"
+  resolved 
"https://registry.yarnpkg.com/@antora/cli/-/cli-2.3.0.tgz#e8bc5509fa7742249c338ec49ad28582c3765e35;
+  integrity 
sha512-YiAP7Ib4zhAE+owOKg1/cJ+1AQX4BGfvaMnGkHaSf6srutoLLCRIbD0InpSNobf+ouSMqqk6fiLmBVt/cu03og==
   dependencies:
-"@antora/playbook-builder" "2.3.0-beta.2"
+"@antora/playbook-builder" "2.3.0"
 commander "~5.0"
 
-"@antora/content-aggregator@2.3.0-beta.2":
-  version "2.3.0-beta.2"
-  resolved 
"https://registry.yarnpkg.com/@antora/content-aggregator/-/content-aggregator-2.3.0-beta.2.tgz#da4e43e9371e6b4bae9c27ca9d048b672b8c3a17;
-  integrity 
sha512-IWhvzCRlMGvNk9gIx5IKCQ9qdqWqeY1Vd2+nKJwMv13SrIFA+eIZk+01rA7VMsKKupt5dMlXaZVK0HgjtIExhw==
+"@antora/content-aggregator@2.3.0":
+  version "2.3.0"
+  resolved 
"https://registry.yarnpkg.com/@antora/content-aggregator/-/content-aggregator-2.3.0.tgz#a2a2d0d38b4ebb65cef834aa510ac01fe131fa2b;
+  integrity 
sha512-LbH65Hw5uk3QCX8sCsJGnIVapQbtkxgyaDAfxYJlXnBI4jjd92391k0vitFL7f+9dzEvSdzxUHJU/lPyi9eB6g==
   dependencies:
 "@antora/expand-path-helper" "~1.0"
 braces "~3.0"
@@ -37,45 +38,45 @@
 vinyl "~2.2"
 vinyl-fs "~3.0"
 
-"@antora/content-classifier@2.3.0-beta.2":
-  version "2.3.0-beta.2"
-  resolved 
"https://registry.yarnpkg.com/@antora/content-classifier/-/content-classifier-2.3.0-beta.2.tgz#b696f40be27b8c2923ebb0976302047ff61fe032;
-  integrity 

[camel-kafka-connector] branch release0.1.0 updated (a2d46dc -> c22cbff)

2020-04-25 Thread valdar
This is an automated email from the ASF dual-hosted git repository.

valdar pushed a change to branch release0.1.0
in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git.


 discard a2d46dc  [maven-release-plugin] prepare for next development iteration
 discard 3a96b87  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0
 discard 41394d2  [maven-release-plugin] rollback the release of 
camel-kafka-connector-0.1.0
 discard e0be8f5  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0
 discard 523d7b1  [maven-release-plugin] prepare for next development iteration
 discard 8a18583  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0
 add 7fff238  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0
 new c22cbff  [maven-release-plugin] prepare for next development iteration

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (a2d46dc)
\
 N -- N -- N   refs/heads/release0.1.0 (c22cbff)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 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:



[camel-kafka-connector] tag camel-kafka-connector-0.1.0 created (now 7fff238)

2020-04-25 Thread valdar
This is an automated email from the ASF dual-hosted git repository.

valdar pushed a change to tag camel-kafka-connector-0.1.0
in repository https://gitbox.apache.org/repos/asf/camel-kafka-connector.git.


  at 7fff238  (commit)
This tag includes the following new commits:

 new 7fff238  [maven-release-plugin] prepare release 
camel-kafka-connector-0.1.0

The 1 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.




[camel] branch master updated: CAMEL-14923: Deprecated inOnly and inOut EIPs as you should use to EIP instead and specify the pattern.

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 7f311f6  CAMEL-14923: Deprecated inOnly and inOut EIPs as you should 
use to EIP instead and specify the pattern.
7f311f6 is described below

commit 7f311f6e0d3936143bd0eafb15c7937982569d9f
Author: Claus Ibsen 
AuthorDate: Sat Apr 25 12:23:38 2020 +0200

CAMEL-14923: Deprecated inOnly and inOut EIPs as you should use to EIP 
instead and specify the pattern.
---
 .../src/main/java/org/apache/camel/model/ProcessorDefinition.java   | 2 ++
 1 file changed, 2 insertions(+)

diff --git 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
index 5e90a10..2c53c7c 100644
--- 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
+++ 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
@@ -537,6 +537,7 @@ public abstract class ProcessorDefinition
  * @param endpoints list of endpoints to send to
  * @return the builder
  */
+@Deprecated
 public Type to(ExchangePattern pattern, Iterable endpoints) {
 for (Endpoint endpoint : endpoints) {
 addOutput(new ToDefinition(endpoint, pattern));
@@ -994,6 +995,7 @@ public abstract class ProcessorDefinition
  * @param endpoints list of endpoints
  * @return the builder
  */
+@Deprecated
 public Type pipeline(Collection endpoints) {
 PipelineDefinition answer = new PipelineDefinition();
 for (Endpoint endpoint : endpoints) {



[camel] branch master updated: CAMEL-14923: Deprecated inOnly and inOut EIPs as you should use to EIP instead and specify the pattern.

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 329b44b  CAMEL-14923: Deprecated inOnly and inOut EIPs as you should 
use to EIP instead and specify the pattern.
329b44b is described below

commit 329b44bfabf2fdd850ed00684b8ac308c6739b7c
Author: Claus Ibsen 
AuthorDate: Sat Apr 25 12:17:56 2020 +0200

CAMEL-14923: Deprecated inOnly and inOut EIPs as you should use to EIP 
instead and specify the pattern.
---
 .../resources/org/apache/camel/model/inOnly.json   |  2 +-
 .../resources/org/apache/camel/model/inOut.json|  2 +-
 .../org/apache/camel/model/InOnlyDefinition.java   |  1 +
 .../org/apache/camel/model/InOutDefinition.java|  1 +
 .../apache/camel/model/ProcessorDefinition.java| 25 +-
 .../camel/processor/FromToInOutUsingToTest.java| 55 ++
 6 files changed, 83 insertions(+), 3 deletions(-)

diff --git 
a/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOnly.json
 
b/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOnly.json
index ebc50a8..fbf5926 100644
--- 
a/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOnly.json
+++ 
b/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOnly.json
@@ -4,7 +4,7 @@
 "name": "inOnly",
 "title": "In Only",
 "description": "Marks the exchange pattern for the route to one way",
-"deprecated": false,
+"deprecated": true,
 "label": "eip,endpoint,routing",
 "javaType": "org.apache.camel.model.InOnlyDefinition",
 "input": true,
diff --git 
a/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOut.json
 
b/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOut.json
index 7133977..0282841 100644
--- 
a/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOut.json
+++ 
b/core/camel-core-engine/src/generated/resources/org/apache/camel/model/inOut.json
@@ -4,7 +4,7 @@
 "name": "inOut",
 "title": "In Out",
 "description": "Marks the exchange pattern for the route to 
request\/reply",
-"deprecated": false,
+"deprecated": true,
 "label": "eip,endpoint,routing",
 "javaType": "org.apache.camel.model.InOutDefinition",
 "input": true,
diff --git 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/InOnlyDefinition.java
 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/InOnlyDefinition.java
index b7313a1..486be6c 100644
--- 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/InOnlyDefinition.java
+++ 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/InOnlyDefinition.java
@@ -30,6 +30,7 @@ import org.apache.camel.spi.Metadata;
 @Metadata(label = "eip,endpoint,routing")
 @XmlRootElement(name = "inOnly")
 @XmlAccessorType(XmlAccessType.FIELD)
+@Deprecated
 public class InOnlyDefinition extends SendDefinition {
 
 public InOnlyDefinition() {
diff --git 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/InOutDefinition.java
 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/InOutDefinition.java
index 65e9e45..fad827a 100644
--- 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/InOutDefinition.java
+++ 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/InOutDefinition.java
@@ -30,6 +30,7 @@ import org.apache.camel.spi.Metadata;
 @Metadata(label = "eip,endpoint,routing")
 @XmlRootElement(name = "inOut")
 @XmlAccessorType(XmlAccessType.FIELD)
+@Deprecated
 public class InOutDefinition extends SendDefinition {
 
 public InOutDefinition() {
diff --git 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
index d4b9db3..5e90a10 100644
--- 
a/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
+++ 
b/core/camel-core-engine/src/main/java/org/apache/camel/model/ProcessorDefinition.java
@@ -477,6 +477,7 @@ public abstract class ProcessorDefinition
  * @param endpoints list of endpoints to send to
  * @return the builder
  */
+@Deprecated
 public Type to(Iterable endpoints) {
 for (Endpoint endpoint : endpoints) {
 addOutput(new ToDefinition(endpoint));
@@ -586,7 +587,9 @@ public abstract class ProcessorDefinition
  *
  * @param uri The endpoint uri which is used for sending the exchange
  * @return the builder
+ * @deprecated use to where you can specify the exchange pattern as well
  */
+@Deprecated
 public Type inOnly(@AsEndpointUri String uri) {
 return to(ExchangePattern.InOnly, uri);
 }
@@ -602,7 +605,9 @@ public abstract class ProcessorDefinition
  *
  * @param endpoint The endpoint which is 

[camel] branch master updated (813d966 -> d15d559)

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


from 813d966  CAMEL-14947: camel-sftp: check for existance of remote 
directory using ls is very slow. Polished the prev PR and rename the option to 
a better name.
 new 686fca6  CAMEL-14915: camel-ftp consumer should not try to create 
starting directory if its empty/home.
 new d15d559  CAMEL-14947: camel-sftp: check for existance of remote 
directory using ls is very slow. Polished the prev PR and rename the option to 
a better name.

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:
 .../apache/camel/component/file/remote/sftp.json   |  2 +-
 .../camel-ftp/src/main/docs/sftp-component.adoc|  2 +-
 .../camel/component/file/remote/FtpConsumer.java   |  9 +--
 .../component/file/remote/RemoteFileConsumer.java  | 13 +
 .../component/file/remote/SftpConfiguration.java   |  8 +--
 .../camel/component/file/remote/SftpConsumer.java  |  9 +--
 ...ava => SftpSimpleConsumeNoStartingDirTest.java} | 25 
 .../endpoint/dsl/SftpEndpointBuilderFactory.java   | 66 ++
 8 files changed, 74 insertions(+), 60 deletions(-)
 copy 
components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/{SftpKeyUriConsumeFromClasspathTest.java
 => SftpSimpleConsumeNoStartingDirTest.java} (70%)



[camel] 01/02: CAMEL-14915: camel-ftp consumer should not try to create starting directory if its empty/home.

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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

commit 686fca65ab92a828bb8359608d15a80d0085c434
Author: Claus Ibsen 
AuthorDate: Sat Apr 25 11:43:23 2020 +0200

CAMEL-14915: camel-ftp consumer should not try to create starting directory 
if its empty/home.
---
 .../camel/component/file/remote/FtpConsumer.java   |  9 ++--
 .../component/file/remote/RemoteFileConsumer.java  | 13 +
 .../camel/component/file/remote/SftpConsumer.java  |  9 ++--
 .../sftp/SftpSimpleConsumeNoStartingDirTest.java   | 63 ++
 4 files changed, 86 insertions(+), 8 deletions(-)

diff --git 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
index ccc7a70..c278947 100644
--- 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
+++ 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
@@ -70,14 +70,15 @@ public class FtpConsumer extends 
RemoteFileConsumer {
 setStartScheduler(false);
 try {
 super.doStart();
-if (endpoint.isAutoCreate()) {
-LOG.debug("Auto creating directory: {}", 
endpoint.getConfiguration().getDirectory());
+if (endpoint.isAutoCreate() && hasStartingDirectory()) {
+String dir = endpoint.getConfiguration().getDirectory();
+LOG.debug("Auto creating directory: {}", dir);
 try {
 connectIfNecessary();
-
operations.buildDirectory(endpoint.getConfiguration().getDirectory(), true);
+operations.buildDirectory(dir, true);
 } catch (GenericFileOperationFailedException e) {
 // log a WARN as we want to start the consumer.
-LOG.warn("Error auto creating directory: " + 
endpoint.getConfiguration().getDirectory() + " due " + e.getMessage() + ". This 
exception is ignored.", e);
+LOG.warn("Error auto creating directory: " + dir + " due " 
+ e.getMessage() + ". This exception is ignored.", e);
 }
 }
 } finally {
diff --git 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
index 63e2635..aaca933 100644
--- 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
+++ 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileConsumer.java
@@ -28,6 +28,7 @@ import org.apache.camel.component.file.GenericFileConsumer;
 import org.apache.camel.component.file.GenericFileOperationFailedException;
 import org.apache.camel.component.file.GenericFileProcessStrategy;
 import org.apache.camel.support.SynchronizationAdapter;
+import org.apache.camel.util.ObjectHelper;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -150,6 +151,18 @@ public abstract class RemoteFileConsumer extends 
GenericFileConsumer {
 return getEndpoint().isDownload();
 }
 
+/**
+ * Whether there is a starting directory configured.
+ */
+protected boolean hasStartingDirectory() {
+String dir = endpoint.getConfiguration().getDirectory();
+if (ObjectHelper.isEmpty(dir)) {
+return false;
+}
+// should not be a empty separator
+return !dir.equals("/") && !dir.equals("\\");
+}
+
 @Override
 protected void doStop() throws Exception {
 super.doStop();
diff --git 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
index e2a3c8c..58529f8 100644
--- 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
+++ 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
@@ -60,14 +60,15 @@ public class SftpConsumer extends 
RemoteFileConsumer {
 setStartScheduler(false);
 try {
 super.doStart();
-if (endpoint.isAutoCreate()) {
-LOG.debug("Auto creating directory: {}", 
endpoint.getConfiguration().getDirectory());
+if (endpoint.isAutoCreate() && hasStartingDirectory()) {
+String dir = endpoint.getConfiguration().getDirectory();
+LOG.debug("Auto creating directory: {}", dir);
 try {
 connectIfNecessary();
-
operations.buildDirectory(endpoint.getConfiguration().getDirectory(), true);
+operations.buildDirectory(dir, true);
 

[camel] 02/02: CAMEL-14947: camel-sftp: check for existance of remote directory using ls is very slow. Polished the prev PR and rename the option to a better name.

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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

commit d15d559848b0a210bf23405b70da88f554a5424b
Author: Claus Ibsen 
AuthorDate: Sat Apr 25 12:05:00 2020 +0200

CAMEL-14947: camel-sftp: check for existance of remote directory using ls 
is very slow. Polished the prev PR and rename the option to a better name.
---
 .../apache/camel/component/file/remote/sftp.json   |  2 +-
 .../camel-ftp/src/main/docs/sftp-component.adoc|  2 +-
 .../component/file/remote/SftpConfiguration.java   |  8 +--
 .../endpoint/dsl/SftpEndpointBuilderFactory.java   | 66 ++
 4 files changed, 36 insertions(+), 42 deletions(-)

diff --git 
a/components/camel-ftp/src/generated/resources/org/apache/camel/component/file/remote/sftp.json
 
b/components/camel-ftp/src/generated/resources/org/apache/camel/component/file/remote/sftp.json
index 386def2..156bb1e 100644
--- 
a/components/camel-ftp/src/generated/resources/org/apache/camel/component/file/remote/sftp.json
+++ 
b/components/camel-ftp/src/generated/resources/org/apache/camel/component/file/remote/sftp.json
@@ -78,7 +78,7 @@
 "bulkRequests": { "kind": "parameter", "displayName": "Bulk Requests", 
"group": "advanced", "label": "advanced", "required": false, "type": "integer", 
"javaType": "java.lang.Integer", "deprecated": false, "secret": false, 
"configurationClass": 
"org.apache.camel.component.file.remote.SftpConfiguration", 
"configurationField": "configuration", "description": "Specifies how many 
requests may be outstanding at any one time. Increasing this value may slightly 
improve file transfer speed bu [...]
 "compression": { "kind": "parameter", "displayName": "Compression", 
"group": "advanced", "label": "advanced", "required": false, "type": "integer", 
"javaType": "int", "deprecated": false, "secret": false, "configurationClass": 
"org.apache.camel.component.file.remote.SftpConfiguration", 
"configurationField": "configuration", "description": "To use compression. 
Specify a level from 1 to 10. Important: You must manually add the needed JSCH 
zlib JAR to the classpath for compression support." },
 "connectTimeout": { "kind": "parameter", "displayName": "Connect Timeout", 
"group": "advanced", "label": "advanced", "required": false, "type": "integer", 
"javaType": "int", "deprecated": false, "secret": false, "defaultValue": 
"1", "configurationClass": 
"org.apache.camel.component.file.remote.SftpConfiguration", 
"configurationField": "configuration", "description": "Sets the connect timeout 
for waiting for a connection to be established Used by both FTPClient and JSCH" 
},
-"existDirCheckUsingLs": { "kind": "parameter", "displayName": "Exist Dir 
Check Using Ls", "group": "advanced", "label": "advanced", "required": false, 
"type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, 
"defaultValue": "true", "configurationClass": 
"org.apache.camel.component.file.remote.SftpConfiguration", 
"configurationField": "configuration", "description": "Whether to check for 
existing directory using LS command instead of CD. By default CD is used wh 
[...]
+"existDirCheckUsingLs": { "kind": "parameter", "displayName": "Exist Dir 
Check Using Ls", "group": "advanced", "label": "advanced", "required": false, 
"type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, 
"defaultValue": "true", "configurationClass": 
"org.apache.camel.component.file.remote.SftpConfiguration", 
"configurationField": "configuration", "description": "Whether to check for 
existing directory using LS command or CD. By default LS is used which is s 
[...]
 "maximumReconnectAttempts": { "kind": "parameter", "displayName": "Maximum 
Reconnect Attempts", "group": "advanced", "label": "advanced", "required": 
false, "type": "integer", "javaType": "int", "deprecated": false, "secret": 
false, "description": "Specifies the maximum reconnect attempts Camel performs 
when it tries to connect to the remote FTP server. Use 0 to disable this 
behavior." },
 "proxy": { "kind": "parameter", "displayName": "Proxy", "group": 
"advanced", "label": "advanced", "required": false, "type": "object", 
"javaType": "com.jcraft.jsch.Proxy", "deprecated": false, "secret": false, 
"description": "To use a custom configured com.jcraft.jsch.Proxy. This proxy is 
used to consume\/send messages from the target SFTP host." },
 "reconnectDelay": { "kind": "parameter", "displayName": "Reconnect Delay", 
"group": "advanced", "label": "advanced", "required": false, "type": "integer", 
"javaType": "long", "deprecated": false, "secret": false, "description": "Delay 
in millis Camel will wait before performing a reconnect attempt." },
diff --git a/components/camel-ftp/src/main/docs/sftp-component.adoc 
b/components/camel-ftp/src/main/docs/sftp-component.adoc
index bb3c5d2..552a324 100644
--- 

[GitHub] [camel] onderson commented on a change in pull request #3777: CAMEL-2933 - resteasy component

2020-04-25 Thread GitBox


onderson commented on a change in pull request #3777:
URL: https://github.com/apache/camel/pull/3777#discussion_r415009728



##
File path: 
components/camel-resteasy/src/test/java/org/apache/camel/component/resteasy/test/ResteasyConsumerTest.java
##
@@ -0,0 +1,222 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.resteasy.test;
+
+import java.io.File;
+import java.net.URI;
+import java.nio.file.Files;
+
+import javax.ws.rs.client.Client;
+import javax.ws.rs.client.ClientBuilder;
+import javax.ws.rs.client.Entity;
+import javax.ws.rs.client.WebTarget;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+
+import org.apache.camel.component.resteasy.test.beans.Customer;
+import org.apache.camel.component.resteasy.test.beans.CustomerList;
+import org.apache.camel.component.resteasy.test.beans.CustomerService;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.container.test.api.RunAsClient;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.arquillian.junit.InSequence;
+import org.jboss.arquillian.test.api.ArquillianResource;
+import org.jboss.shrinkwrap.api.Archive;
+import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.jboss.shrinkwrap.resolver.api.maven.Maven;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+@RunWith(Arquillian.class)
+@RunAsClient
+public class ResteasyConsumerTest {
+
+@ArquillianResource
+URI baseUri;
+
+@Deployment
+public static Archive createTestArchive() {
+
+return ShrinkWrap.create(WebArchive.class, "test.war")
+.addClasses(Customer.class, CustomerService.class, 
CustomerList.class)
+.addPackage("org.apache.camel.component.resteasy")
+.addPackage("org.apache.camel.component.resteasy.servlet")
+.addAsLibraries(Maven.resolver().loadPomFromFile("pom.xml")
+
.importRuntimeAndTestDependencies().resolve().withTransitivity().asFile())
+.addAsWebInfResource(new 
File("src/test/resources/contexts/basicConsumer.xml"), "applicationContext.xml")
+.addAsWebInfResource("web.xml");
+
+}
+
+private Response createCustomer(Customer customer) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/createCustomer");
+Response response = target.request(MediaType.APPLICATION_JSON)
+.post(Entity.entity(customer, 
MediaType.APPLICATION_JSON_TYPE));
+
+Assert.assertEquals(200, response.getStatus());
+return response;
+}
+
+private Response deleteCustomer(int id) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/deleteCustomer?id=" + id);
+Response response = target.request().delete();
+
+Assert.assertEquals(200, response.getStatus());
+
+return response;
+}
+
+private Customer getCustomer(int id) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/getCustomer?id=" + id);
+Response response = target.request().get();
+
+Assert.assertEquals(200, response.getStatus());
+
+return response.readEntity(Customer.class);
+}
+
+@Test
+@InSequence(1)
+public void testGetAll() throws Exception {
+String expectedUser1 = 
"{\"name\":\"Roman\",\"surname\":\"Jakubco\",\"id\":1}";
+String expectedUser2 = 
"{\"name\":\"Camel\",\"surname\":\"Rider\",\"id\":2}";
+
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/getAll");
+Response response = target.request().get();
+
+Assert.assertEquals(200, response.getStatus());
+
+String users = response.readEntity(String.class);
+Assert.assertTrue(users.contains(expectedUser1));
+Assert.assertTrue(users.contains(expectedUser2));
+
+File file = new 

[camel] branch master updated: CAMEL-14947: camel-sftp: check for existance of remote directory using ls is very slow. Polished the prev PR and rename the option to a better name.

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 813d966  CAMEL-14947: camel-sftp: check for existance of remote 
directory using ls is very slow. Polished the prev PR and rename the option to 
a better name.
813d966 is described below

commit 813d966440ff952dcc962f4c43f864405a62ad2e
Author: Claus Ibsen 
AuthorDate: Sat Apr 25 08:59:35 2020 +0200

CAMEL-14947: camel-sftp: check for existance of remote directory using ls 
is very slow. Polished the prev PR and rename the option to a better name.
---
 .../remote/sftp/SftpProducerFileWithPathTest.java  | 49 ++
 1 file changed, 49 insertions(+)

diff --git 
a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpProducerFileWithPathTest.java
 
b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpProducerFileWithPathTest.java
index d6bc681..8489194 100644
--- 
a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpProducerFileWithPathTest.java
+++ 
b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/sftp/SftpProducerFileWithPathTest.java
@@ -44,4 +44,53 @@ public class SftpProducerFileWithPathTest extends 
SftpServerTestSupport {
 assertEquals("Hello World", IOConverter.toString(file, null));
 }
 
+@Test
+public void testProducerFileWithPathTwice() throws Exception {
+if (!canTest()) {
+return;
+}
+
+template.sendBodyAndHeader(getFtpUrl(), "Hello World", 
Exchange.FILE_NAME, "hello/claus.txt");
+template.sendBodyAndHeader(getFtpUrl(), "Hello Again World", 
Exchange.FILE_NAME, "hello/andrea.txt");
+
+File file = new File(FTP_ROOT_DIR + "/hello/claus.txt");
+assertTrue(file.exists(), "The uploaded file should exists");
+assertEquals("Hello World", IOConverter.toString(file, null));
+
+file = new File(FTP_ROOT_DIR + "/hello/andrea.txt");
+assertTrue(file.exists(), "The uploaded file should exists");
+assertEquals("Hello Again World", IOConverter.toString(file, null));
+}
+
+@Test
+public void testProducerFileWithPathExistDirCheckUsingLs() throws 
Exception {
+if (!canTest()) {
+return;
+}
+
+template.sendBodyAndHeader(getFtpUrl() + 
"=false", "Bye World", Exchange.FILE_NAME, 
"bye/andrea.txt");
+
+File file = new File(FTP_ROOT_DIR + "/bye/andrea.txt");
+assertTrue(file.exists(), "The uploaded file should exists");
+assertEquals("Bye World", IOConverter.toString(file, null));
+}
+
+@Test
+public void testProducerFileWithPathExistDirCheckUsingLsTwice() throws 
Exception {
+if (!canTest()) {
+return;
+}
+
+template.sendBodyAndHeader(getFtpUrl() + 
"=false", "Bye World", Exchange.FILE_NAME, 
"bye/andrea.txt");
+template.sendBodyAndHeader(getFtpUrl() + 
"=false", "Bye Again World", Exchange.FILE_NAME, 
"bye/claus.txt");
+
+File file = new File(FTP_ROOT_DIR + "/bye/andrea.txt");
+assertTrue(file.exists(), "The uploaded file should exists");
+assertEquals("Bye World", IOConverter.toString(file, null));
+
+file = new File(FTP_ROOT_DIR + "/bye/claus.txt");
+assertTrue(file.exists(), "The uploaded file should exists");
+assertEquals("Bye Again World", IOConverter.toString(file, null));
+}
+
 }



[GitHub] [camel] dmvolod commented on a change in pull request #3777: CAMEL-2933 - resteasy component

2020-04-25 Thread GitBox


dmvolod commented on a change in pull request #3777:
URL: https://github.com/apache/camel/pull/3777#discussion_r414999677



##
File path: 
components/camel-resteasy/src/test/java/org/apache/camel/component/resteasy/test/ResteasyConsumerTest.java
##
@@ -0,0 +1,222 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.resteasy.test;
+
+import java.io.File;
+import java.net.URI;
+import java.nio.file.Files;
+
+import javax.ws.rs.client.Client;
+import javax.ws.rs.client.ClientBuilder;
+import javax.ws.rs.client.Entity;
+import javax.ws.rs.client.WebTarget;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+
+import org.apache.camel.component.resteasy.test.beans.Customer;
+import org.apache.camel.component.resteasy.test.beans.CustomerList;
+import org.apache.camel.component.resteasy.test.beans.CustomerService;
+import org.jboss.arquillian.container.test.api.Deployment;
+import org.jboss.arquillian.container.test.api.RunAsClient;
+import org.jboss.arquillian.junit.Arquillian;
+import org.jboss.arquillian.junit.InSequence;
+import org.jboss.arquillian.test.api.ArquillianResource;
+import org.jboss.shrinkwrap.api.Archive;
+import org.jboss.shrinkwrap.api.ShrinkWrap;
+import org.jboss.shrinkwrap.api.spec.WebArchive;
+import org.jboss.shrinkwrap.resolver.api.maven.Maven;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+@RunWith(Arquillian.class)
+@RunAsClient
+public class ResteasyConsumerTest {
+
+@ArquillianResource
+URI baseUri;
+
+@Deployment
+public static Archive createTestArchive() {
+
+return ShrinkWrap.create(WebArchive.class, "test.war")
+.addClasses(Customer.class, CustomerService.class, 
CustomerList.class)
+.addPackage("org.apache.camel.component.resteasy")
+.addPackage("org.apache.camel.component.resteasy.servlet")
+.addAsLibraries(Maven.resolver().loadPomFromFile("pom.xml")
+
.importRuntimeAndTestDependencies().resolve().withTransitivity().asFile())
+.addAsWebInfResource(new 
File("src/test/resources/contexts/basicConsumer.xml"), "applicationContext.xml")
+.addAsWebInfResource("web.xml");
+
+}
+
+private Response createCustomer(Customer customer) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/createCustomer");
+Response response = target.request(MediaType.APPLICATION_JSON)
+.post(Entity.entity(customer, 
MediaType.APPLICATION_JSON_TYPE));
+
+Assert.assertEquals(200, response.getStatus());
+return response;
+}
+
+private Response deleteCustomer(int id) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/deleteCustomer?id=" + id);
+Response response = target.request().delete();
+
+Assert.assertEquals(200, response.getStatus());
+
+return response;
+}
+
+private Customer getCustomer(int id) {
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/getCustomer?id=" + id);
+Response response = target.request().get();
+
+Assert.assertEquals(200, response.getStatus());
+
+return response.readEntity(Customer.class);
+}
+
+@Test
+@InSequence(1)
+public void testGetAll() throws Exception {
+String expectedUser1 = 
"{\"name\":\"Roman\",\"surname\":\"Jakubco\",\"id\":1}";
+String expectedUser2 = 
"{\"name\":\"Camel\",\"surname\":\"Rider\",\"id\":2}";
+
+Client client = ClientBuilder.newBuilder().build();
+WebTarget target = client.target(baseUri.toString() + 
"customer/getAll");
+Response response = target.request().get();
+
+Assert.assertEquals(200, response.getStatus());
+
+String users = response.readEntity(String.class);
+Assert.assertTrue(users.contains(expectedUser1));
+Assert.assertTrue(users.contains(expectedUser2));
+
+File file = new 

[camel] branch master updated (89f16b3 -> f58b231)

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


from 89f16b3  CAMEL-14947 check for existance of remote directory using ls 
very slow (#3776)
 add 0f3a53d  Regen
 add f58b231  CAMEL-14947: camel-sftp: check for existance of remote 
directory using ls is very slow. Polished the prev PR and rename the option to 
a better name.

No new revisions were added by this update.

Summary of changes:
 .../org/apache/camel/component/atom/atom.json  |   2 +-
 .../file/remote/SftpEndpointConfigurer.java|   5 +
 .../apache/camel/component/file/remote/sftp.json   |   1 +
 .../camel-ftp/src/main/docs/sftp-component.adoc|   3 +-
 .../component/file/remote/RemoteFileEndpoint.java  |  21 
 .../component/file/remote/SftpConfiguration.java   |  18 
 .../component/file/remote/SftpOperations.java  |  17 +++-
 .../org/apache/camel/component/rss/rss.json|   2 +-
 .../camel-rss/src/main/docs/rss-component.adoc |   2 +-
 .../endpoint/dsl/AtomEndpointBuilderFactory.java   |   4 +-
 .../endpoint/dsl/RssEndpointBuilderFactory.java|   4 +-
 .../endpoint/dsl/SftpEndpointBuilderFactory.java   | 108 +
 .../modules/ROOT/pages/atom-component.adoc |   2 +-
 .../ROOT/pages/google-calendar-component.adoc  |   4 +-
 .../modules/ROOT/pages/google-mail-component.adoc  |   4 +-
 .../modules/ROOT/pages/rss-component.adoc  |   2 +-
 16 files changed, 160 insertions(+), 39 deletions(-)



[camel] branch master updated: CAMEL-14947 check for existance of remote directory using ls very slow (#3776)

2020-04-25 Thread davsclaus
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 89f16b3  CAMEL-14947 check for existance of remote directory using ls 
very slow (#3776)
89f16b3 is described below

commit 89f16b301dc3c07803c560e2cd76d8319a3904c9
Author: Chandrakant Hardahe 
AuthorDate: Sat Apr 25 11:41:59 2020 +0530

CAMEL-14947 check for existance of remote directory using ls very slow 
(#3776)

Co-authored-by: Chandrakant Hardahe 
---
 .../component/file/remote/RemoteFileEndpoint.java  | 22 ++
 .../component/file/remote/SftpOperations.java  |  6 +-
 2 files changed, 27 insertions(+), 1 deletion(-)

diff --git 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
index 273f6c6..1b3ef22 100644
--- 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
+++ 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
@@ -62,6 +62,13 @@ public abstract class RemoteFileEndpoint extends 
GenericFileEndpoint {
  + "option is set to 
false, then the message body will be null, but the consumer will still trigger 
a Camel "
  + "Exchange that has 
details about the file such as file name, file size, etc. It's just that the 
file will "
  + "not be 
downloaded.")
+
+private boolean  loadFullDirectory;
+@UriParam(label = "advanced", description = " If set this option to be 
true, camel-ftp will load the full directory listing and load it over the wire."
++ "If the remote directory has 
a lot of files then this option can be set to false, camel-ftp will use the "
++ "old way to check if 
directory exist via cd. This can be used to speed up the process If the remote"
++ " directory has a lot of 
files.", defaultValue = "false")
+
 private boolean download = true;
 
 public RemoteFileEndpoint() {
@@ -309,4 +316,19 @@ public abstract class RemoteFileEndpoint extends 
GenericFileEndpoint {
 public void setDownload(boolean download) {
 this.download = download;
 }
+
+public boolean isLoadFullDirectory() {
+return  loadFullDirectory;
+}
+
+/**
+ * If set this option to be true, camel-ftp will load the full directory 
listing and load it over the wire.
+ * If the remote directory has a lot of files then this option can be set 
to false, camel-ftp will use the
+ * old way to check if directory exist via cd. This can be used to speed 
up the process If the remote"
+ * directory has a lot of files.
+ */
+public void setLoadFullDirectory(boolean loadFullDirectory) {
+this.loadFullDirectory = loadFullDirectory;
+}
+
 }
diff --git 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
index 6203e2f..7bd4130 100644
--- 
a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
+++ 
b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
@@ -517,7 +517,11 @@ public class SftpOperations implements 
RemoteFileOperations {
 try {
 // maybe the full directory already exists
 try {
-channel.ls(directory);
+if (this.endpoint.isLoadFullDirectory()) {
+channel.ls(directory);
+} else {
+channel.cd(directory);
+}
 success = true;
 } catch (SftpException e) {
 // ignore, we could not change directory so try to create it