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-k.git
commit ec51786bcb1f755a5b282c8248a71dc7fe8ba378 Author: nferraro <ni.ferr...@gmail.com> AuthorDate: Sun Dec 2 00:02:23 2018 +0100 (chore) reorganizing examples --- README.adoc | 16 ++++++++-------- docs/developers.adoc | 4 ++-- {runtime/examples => examples}/CaffeineCacheSample.java | 0 {runtime/examples => examples}/RestWithRestlet.java | 2 +- {runtime/examples => examples}/Sample.java | 0 {runtime/examples => examples}/camel-caffeine.groovy | 2 +- {runtime/examples => examples}/dns.js | 4 ++-- {runtime/examples => examples}/hello.xml | 0 {runtime/examples => examples}/kotlin-routes.kts | 4 ++-- {runtime/examples => examples}/props.js | 2 +- {runtime/examples => examples}/routes-rest.js | 2 +- {runtime/examples => examples}/routes.groovy | 4 ++-- {runtime/examples => examples}/routes.js | 0 {runtime/examples => examples}/simple.groovy | 0 {runtime/examples => examples}/simple.js | 0 15 files changed, 20 insertions(+), 20 deletions(-) diff --git a/README.adoc b/README.adoc index c50c564..91790ec 100644 --- a/README.adoc +++ b/README.adoc @@ -51,17 +51,17 @@ For Minishift, this means executing `oc login -u system:admin` then `kamel insta After the initial setup, you can run a Camel integration on the cluster by executing: ``` -kamel run runtime/examples/Sample.java +kamel run examples/Sample.java ``` -A "Sample.java" file is included in the link:/runtime/examples[/runtime/examples] folder of this repository. You can change the content of the file and execute the command again to see the changes. +A "Sample.java" file is included in the link:/examples[/examples] folder of this repository. You can change the content of the file and execute the command again to see the changes. ==== Configure Integration properties Properties associated to an integration can be configured either using a ConfigMap/Secret or by setting using the "--property" flag, i.e. ``` -kamel run --property my.message=test runtime/examples/props.js +kamel run --property my.message=test examples/props.js ``` ==== Configure Integration Logging @@ -92,7 +92,7 @@ camel.component.seda.queueSize = 10 If you want to iterate quickly on an integration to have fast feedback on the code you're writing, you can use by running it in **"dev" mode**: ``` -kamel run runtime/examples/Sample.java --dev +kamel run examples/Sample.java --dev ``` The `--dev` flag deploys immediately the integration and shows the integration logs in the console. You can then change the code and see @@ -103,7 +103,7 @@ The console follows automatically all redeploys of the integration. Here's an example of the output: ``` -[nferraro@localhost camel-k]$ kamel run runtime/examples/Sample.java --dev +[nferraro@localhost camel-k]$ kamel run examples/Sample.java --dev integration "sample" created integration "sample" in phase Building integration "sample" in phase Deploying @@ -160,9 +160,9 @@ Camel K supports multiple languages for writing integrations: More information about supported languages is provided in the link:docs/languages.adoc[languages guide]. -Integrations written in different languages are provided in the link:/runtime/examples[examples] directory. +Integrations written in different languages are provided in the link:/examples[examples] directory. -An example of integration written in JavaScript is the link:/runtime/examples/dns.js[/runtime/examples/dns.js] integration. +An example of integration written in JavaScript is the link:/examples/dns.js[/examples/dns.js] integration. Here's the content: ``` @@ -178,7 +178,7 @@ from('timer:dns?period=1s') To run it, you need just to execute: ``` -kamel run runtime/examples/dns.js +kamel run examples/dns.js ``` === Traits diff --git a/docs/developers.adoc b/docs/developers.adoc index b3a6a6c..9589be3 100644 --- a/docs/developers.adoc +++ b/docs/developers.adoc @@ -140,13 +140,13 @@ This command assumes you have an already running Minikube instance. Now you can play with Camel K: ``` -./kamel run runtime/examples/Sample.java +./kamel run examples/Sample.java ``` To add additional dependencies to your routes: ``` -./kamel run -d camel:dns runtime/examples/dns.js +./kamel run -d camel:dns examples/dns.js ``` [[debugging]] diff --git a/runtime/examples/CaffeineCacheSample.java b/examples/CaffeineCacheSample.java similarity index 100% rename from runtime/examples/CaffeineCacheSample.java rename to examples/CaffeineCacheSample.java diff --git a/runtime/examples/RestWithRestlet.java b/examples/RestWithRestlet.java similarity index 92% rename from runtime/examples/RestWithRestlet.java rename to examples/RestWithRestlet.java index 16c77c7..fa48418 100644 --- a/runtime/examples/RestWithRestlet.java +++ b/examples/RestWithRestlet.java @@ -1,7 +1,7 @@ // // To run this integrations use: // -// kamel run --name=rest-with-restlet --dependency=camel-restlet runtime/examples/RestWithRestlet.java +// kamel run --name=rest-with-restlet --dependency=camel-restlet examples/RestWithRestlet.java // public class RestWithRestlet extends org.apache.camel.builder.RouteBuilder { @Override diff --git a/runtime/examples/Sample.java b/examples/Sample.java similarity index 100% rename from runtime/examples/Sample.java rename to examples/Sample.java diff --git a/runtime/examples/camel-caffeine.groovy b/examples/camel-caffeine.groovy similarity index 95% rename from runtime/examples/camel-caffeine.groovy rename to examples/camel-caffeine.groovy index 1a70c25..d52deb6 100644 --- a/runtime/examples/camel-caffeine.groovy +++ b/examples/camel-caffeine.groovy @@ -1,7 +1,7 @@ // // To run this integrations use: // -// kamel run --runtime groovy runtime/examples/camel-caffeine.groovy +// kamel run --runtime groovy examples/camel-caffeine.groovy // import com.github.benmanes.caffeine.cache.Caffeine diff --git a/runtime/examples/dns.js b/examples/dns.js similarity index 68% rename from runtime/examples/dns.js rename to examples/dns.js index f7c90d2..9ae759c 100644 --- a/runtime/examples/dns.js +++ b/examples/dns.js @@ -1,11 +1,11 @@ // // To run this integrations use: // -// kamel run -d camel:dns runtime/examples/dns.js +// kamel run -d camel:dns examples/dns.js // // Or simply (since dependency auto-detection is enabled by default): // -// kamel run runtime/examples/dns.js +// kamel run examples/dns.js // from('timer:dns?period=1s') diff --git a/runtime/examples/hello.xml b/examples/hello.xml similarity index 100% rename from runtime/examples/hello.xml rename to examples/hello.xml diff --git a/runtime/examples/kotlin-routes.kts b/examples/kotlin-routes.kts similarity index 64% rename from runtime/examples/kotlin-routes.kts rename to examples/kotlin-routes.kts index 8b15930..1d6ce6c 100644 --- a/runtime/examples/kotlin-routes.kts +++ b/examples/kotlin-routes.kts @@ -1,11 +1,11 @@ // // To run this integrations use: // -// kamel run --runtime kotlin runtime/examples/kotlin-routes.kts +// kamel run --runtime kotlin examples/kotlin-routes.kts // // Or leveraging runtime detection // -// kamel run runtime/examples/kotlin-routes.kts +// kamel run examples/kotlin-routes.kts // val rnd = java.util.Random() diff --git a/runtime/examples/props.js b/examples/props.js similarity index 50% rename from runtime/examples/props.js rename to examples/props.js index a89b6ae..f3cde88 100644 --- a/runtime/examples/props.js +++ b/examples/props.js @@ -1,7 +1,7 @@ // // To run this integrations use: // -// kamel run -p my.message=test-props runtime/examples/props.js +// kamel run -p my.message=test-props examples/props.js // from('timer:props?period=1s') diff --git a/runtime/examples/routes-rest.js b/examples/routes-rest.js similarity index 87% rename from runtime/examples/routes-rest.js rename to examples/routes-rest.js index 97d41ec..34981a2 100644 --- a/runtime/examples/routes-rest.js +++ b/examples/routes-rest.js @@ -1,7 +1,7 @@ // // To run this integrations use: // -// kamel run --name=withrest --dependency=camel-undertow runtime/examples/routes-rest.js +// kamel run --name=withrest --dependency=camel-undertow examples/routes-rest.js // // **************** diff --git a/runtime/examples/routes.groovy b/examples/routes.groovy similarity index 83% rename from runtime/examples/routes.groovy rename to examples/routes.groovy index aef7ad3..c5d3b69 100644 --- a/runtime/examples/routes.groovy +++ b/examples/routes.groovy @@ -3,11 +3,11 @@ import java.util.concurrent.ThreadLocalRandom // // To run this integrations use: // -// kamel run --runtime groovy runtime/examples/routes.groovy +// kamel run --runtime groovy examples/routes.groovy // // Or leveraging runtime detection // -// kamel run runtime/examples/routes.groovy +// kamel run examples/routes.groovy // context { diff --git a/runtime/examples/routes.js b/examples/routes.js similarity index 100% rename from runtime/examples/routes.js rename to examples/routes.js diff --git a/runtime/examples/simple.groovy b/examples/simple.groovy similarity index 100% rename from runtime/examples/simple.groovy rename to examples/simple.groovy diff --git a/runtime/examples/simple.js b/examples/simple.js similarity index 100% rename from runtime/examples/simple.js rename to examples/simple.js