Repository: camel Updated Branches: refs/heads/master 6de292723 -> e7118d8ad
Hostname should be configured Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/a8e974f8 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/a8e974f8 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/a8e974f8 Branch: refs/heads/master Commit: a8e974f80da442e0b17f7139900b25dad9080d9b Parents: 6de2927 Author: Claus Ibsen <davscl...@apache.org> Authored: Sun Jan 10 13:21:42 2016 +0100 Committer: Claus Ibsen <davscl...@apache.org> Committed: Sun Jan 10 13:23:48 2016 +0100 ---------------------------------------------------------------------- .../component/hdfs/FromFileToHdfsTest.java | 2 +- .../camel/component/hdfs/HdfsConsumerTest.java | 28 ++++++++++---------- .../hdfs/HdfsProducerConsumerTest.java | 4 +-- .../component/hdfs/HdfsProducerSplitTest.java | 10 +++---- .../camel/component/hdfs/HdfsProducerTest.java | 26 +++++++++--------- .../component/hdfs2/FromFileToHdfsTest.java | 2 +- .../camel/component/hdfs2/HdfsConsumerTest.java | 28 ++++++++++---------- .../hdfs2/HdfsProducerConsumerTest.java | 4 +-- .../component/hdfs2/HdfsProducerSplitTest.java | 10 +++---- .../camel/component/hdfs2/HdfsProducerTest.java | 26 +++++++++--------- 10 files changed, 70 insertions(+), 70 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/FromFileToHdfsTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/FromFileToHdfsTest.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/FromFileToHdfsTest.java index 059a212..ade15c0 100644 --- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/FromFileToHdfsTest.java +++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/FromFileToHdfsTest.java @@ -104,7 +104,7 @@ public class FromFileToHdfsTest extends HdfsTestSupport { @Override public void configure() throws Exception { from("file:target/inbox?delete=true") - .to("hdfs:///" + TEMP_DIR.toUri() + "/output.txt?fileSystemType=LOCAL"); + .to("hdfs:localhost/" + TEMP_DIR.toUri() + "/output.txt?fileSystemType=LOCAL"); } }; } http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsConsumerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsConsumerTest.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsConsumerTest.java index 3386e8d..e85362c 100644 --- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsConsumerTest.java +++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsConsumerTest.java @@ -104,7 +104,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -173,7 +173,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -206,7 +206,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=42&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=42&initialDelay=0").to("mock:result"); } }); context.start(); @@ -233,7 +233,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -263,7 +263,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.getParent().toUri() + "?consumerProperties=#cprops&pattern=*&fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0&readSuffix=handled").to("mock:result"); + from("hdfs:localhost/" + file.getParent().toUri() + "?consumerProperties=#cprops&pattern=*&fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0&readSuffix=handled").to("mock:result"); } }); Map<String, Object> props = new HashMap<String, Object>(); @@ -307,7 +307,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -341,7 +341,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -372,7 +372,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -403,7 +403,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -434,7 +434,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -465,7 +465,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -496,7 +496,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -527,7 +527,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -560,7 +560,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs:///" + file.getParent().toUri() + "?fileSystemType=LOCAL&fileType=ARRAY_FILE&initialDelay=0").to("mock:result"); + from("hdfs:localhost/" + file.getParent().toUri() + "?fileSystemType=LOCAL&fileType=ARRAY_FILE&initialDelay=0").to("mock:result"); } }); context.start(); http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerConsumerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerConsumerTest.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerConsumerTest.java index 4f93257..56a54dd 100644 --- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerConsumerTest.java +++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerConsumerTest.java @@ -55,8 +55,8 @@ public class HdfsProducerConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { @Override public void configure() { - from("direct:start").to("hdfs:///" + file.toUri() + "?fileSystemType=LOCAL&splitStrategy=BYTES:5,IDLE:1000"); - from("hdfs:///" + file.toUri() + "?initialDelay=2000&fileSystemType=LOCAL&chunkSize=5").to("mock:result"); + from("direct:start").to("hdfs:localhost/" + file.toUri() + "?fileSystemType=LOCAL&splitStrategy=BYTES:5,IDLE:1000"); + from("hdfs:localhost/" + file.toUri() + "?initialDelay=2000&fileSystemType=LOCAL&chunkSize=5").to("mock:result"); } }); context.start(); http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerSplitTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerSplitTest.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerSplitTest.java index 2ecc4ff..44ebbb4 100644 --- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerSplitTest.java +++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerSplitTest.java @@ -123,11 +123,11 @@ public class HdfsProducerSplitTest extends HdfsTestSupport { return new RouteBuilder() { @Override public void configure() throws Exception { - from("direct:start1").to("hdfs:///" + BASE_FILE.toUri() + "1?fileSystemType=LOCAL&splitStrategy=MESSAGES:1"); - from("direct:start2").to("hdfs:///" + BASE_FILE.toUri() + "2?fileSystemType=LOCAL&splitStrategy=BYTES:5"); - from("direct:start3").to("hdfs:///" + BASE_FILE.toUri() + "3?fileSystemType=LOCAL&splitStrategy=IDLE:1000"); - from("direct:start4").to("hdfs:///" + BASE_FILE.toUri() + "4?fileSystemType=LOCAL&splitStrategy=IDLE:1000,MESSAGES:1"); - from("direct:start5").to("hdfs:///" + BASE_FILE.toUri() + "5?fileSystemType=LOCAL&splitStrategy=IDLE:1000,BYTES:5"); + from("direct:start1").to("hdfs:localhost/" + BASE_FILE.toUri() + "1?fileSystemType=LOCAL&splitStrategy=MESSAGES:1"); + from("direct:start2").to("hdfs:localhost/" + BASE_FILE.toUri() + "2?fileSystemType=LOCAL&splitStrategy=BYTES:5"); + from("direct:start3").to("hdfs:localhost/" + BASE_FILE.toUri() + "3?fileSystemType=LOCAL&splitStrategy=IDLE:1000"); + from("direct:start4").to("hdfs:localhost/" + BASE_FILE.toUri() + "4?fileSystemType=LOCAL&splitStrategy=IDLE:1000,MESSAGES:1"); + from("direct:start5").to("hdfs:localhost/" + BASE_FILE.toUri() + "5?fileSystemType=LOCAL&splitStrategy=IDLE:1000,BYTES:5"); } }; } http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerTest.java b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerTest.java index a219190..7ff7007 100644 --- a/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerTest.java +++ b/components/camel-hdfs/src/test/java/org/apache/camel/component/hdfs/HdfsProducerTest.java @@ -402,35 +402,35 @@ public class HdfsProducerTest extends HdfsTestSupport { @Override public void configure() throws Exception { - from("direct:start1").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:start1").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); /* For testing writables */ - from("direct:write_boolean").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-boolean?fileSystemType=LOCAL&valueType=BOOLEAN&fileType=SEQUENCE_FILE"); + from("direct:write_boolean").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-boolean?fileSystemType=LOCAL&valueType=BOOLEAN&fileType=SEQUENCE_FILE"); - from("direct:write_byte").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-byte?fileSystemType=LOCAL&valueType=BYTE&fileType=SEQUENCE_FILE"); + from("direct:write_byte").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-byte?fileSystemType=LOCAL&valueType=BYTE&fileType=SEQUENCE_FILE"); - from("direct:write_int").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-int?fileSystemType=LOCAL&valueType=INT&fileType=SEQUENCE_FILE"); + from("direct:write_int").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-int?fileSystemType=LOCAL&valueType=INT&fileType=SEQUENCE_FILE"); - from("direct:write_float").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-float?fileSystemType=LOCAL&valueType=FLOAT&fileType=SEQUENCE_FILE"); + from("direct:write_float").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-float?fileSystemType=LOCAL&valueType=FLOAT&fileType=SEQUENCE_FILE"); - from("direct:write_long").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-long?fileSystemType=LOCAL&valueType=LONG&fileType=SEQUENCE_FILE"); + from("direct:write_long").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-long?fileSystemType=LOCAL&valueType=LONG&fileType=SEQUENCE_FILE"); - from("direct:write_double").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-double?fileSystemType=LOCAL&valueType=DOUBLE&fileType=SEQUENCE_FILE"); + from("direct:write_double").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-double?fileSystemType=LOCAL&valueType=DOUBLE&fileType=SEQUENCE_FILE"); - from("direct:write_text1").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-text1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:write_text1").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-text1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); /* For testing key and value writing */ - from("direct:write_text2").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-text2?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:write_text2").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-text2?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=SEQUENCE_FILE"); - from("direct:write_text3").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-text3?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=MAP_FILE"); + from("direct:write_text3").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-text3?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=MAP_FILE"); /* For testing ArrayFile */ - from("direct:write_text4").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-text4?fileSystemType=LOCAL&valueType=TEXT&fileType=ARRAY_FILE"); + from("direct:write_text4").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-text4?fileSystemType=LOCAL&valueType=TEXT&fileType=ARRAY_FILE"); /* For testing BloomMapFile */ - from("direct:write_text5").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-text5?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=BLOOMMAP_FILE"); + from("direct:write_text5").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-text5?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=BLOOMMAP_FILE"); - from("direct:write_dynamic_filename").to("hdfs:///" + TEMP_DIR.toUri() + "/test-camel-dynamic/?fileSystemType=LOCAL&valueType=TEXT"); + from("direct:write_dynamic_filename").to("hdfs:localhost/" + TEMP_DIR.toUri() + "/test-camel-dynamic/?fileSystemType=LOCAL&valueType=TEXT"); } }; } http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/FromFileToHdfsTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/FromFileToHdfsTest.java b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/FromFileToHdfsTest.java index ebb0b1e..d81d413 100644 --- a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/FromFileToHdfsTest.java +++ b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/FromFileToHdfsTest.java @@ -104,7 +104,7 @@ public class FromFileToHdfsTest extends HdfsTestSupport { @Override public void configure() throws Exception { from("file:target/inbox?delete=true") - .to("hdfs2:///" + TEMP_DIR.toUri() + "/output.txt?fileSystemType=LOCAL"); + .to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/output.txt?fileSystemType=LOCAL"); } }; } http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsConsumerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsConsumerTest.java b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsConsumerTest.java index a55c421..58643f8 100644 --- a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsConsumerTest.java +++ b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsConsumerTest.java @@ -105,7 +105,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -174,7 +174,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -207,7 +207,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=42&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&chunkSize=42&initialDelay=0").to("mock:result"); } }); context.start(); @@ -233,7 +233,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&chunkSize=4096&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&chunkSize=4096&initialDelay=0").to("mock:result"); } }); context.start(); @@ -262,7 +262,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.getParent().toUri() + "?consumerProperties=#cprops&pattern=*&fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0&readSuffix=handled").to("mock:result"); + from("hdfs2:localhost/" + file.getParent().toUri() + "?consumerProperties=#cprops&pattern=*&fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0&readSuffix=handled").to("mock:result"); } }); Map<String, Object> props = new HashMap<String, Object>(); @@ -305,7 +305,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -338,7 +338,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -368,7 +368,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -398,7 +398,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "??fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -428,7 +428,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -458,7 +458,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -488,7 +488,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -518,7 +518,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&fileType=SEQUENCE_FILE&initialDelay=0").to("mock:result"); } }); context.start(); @@ -551,7 +551,7 @@ public class HdfsConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { public void configure() { - from("hdfs2:///" + file.getParent().toUri() + "?fileSystemType=LOCAL&fileType=ARRAY_FILE&initialDelay=0").to("mock:result"); + from("hdfs2:localhost/" + file.getParent().toUri() + "?fileSystemType=LOCAL&fileType=ARRAY_FILE&initialDelay=0").to("mock:result"); } }); context.start(); http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerConsumerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerConsumerTest.java b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerConsumerTest.java index 89d1179..e3fb332 100644 --- a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerConsumerTest.java +++ b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerConsumerTest.java @@ -55,8 +55,8 @@ public class HdfsProducerConsumerTest extends HdfsTestSupport { context.addRoutes(new RouteBuilder() { @Override public void configure() { - from("direct:start").to("hdfs2:///" + file.toUri() + "?fileSystemType=LOCAL&splitStrategy=BYTES:5,IDLE:1000"); - from("hdfs2:///" + file.toUri() + "?initialDelay=2000&fileSystemType=LOCAL&chunkSize=5").to("mock:result"); + from("direct:start").to("hdfs2:localhost/" + file.toUri() + "?fileSystemType=LOCAL&splitStrategy=BYTES:5,IDLE:1000"); + from("hdfs2:localhost/" + file.toUri() + "?initialDelay=2000&fileSystemType=LOCAL&chunkSize=5").to("mock:result"); } }); context.start(); http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerSplitTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerSplitTest.java b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerSplitTest.java index 9c26633..a5407cd 100644 --- a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerSplitTest.java +++ b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerSplitTest.java @@ -123,11 +123,11 @@ public class HdfsProducerSplitTest extends HdfsTestSupport { return new RouteBuilder() { @Override public void configure() throws Exception { - from("direct:start1").to("hdfs2:///" + BASE_FILE.toUri() + "1?fileSystemType=LOCAL&splitStrategy=MESSAGES:1"); - from("direct:start2").to("hdfs2:///" + BASE_FILE.toUri() + "2?fileSystemType=LOCAL&splitStrategy=BYTES:5"); - from("direct:start3").to("hdfs2:///" + BASE_FILE.toUri() + "3?fileSystemType=LOCAL&splitStrategy=IDLE:1000"); - from("direct:start4").to("hdfs2:///" + BASE_FILE.toUri() + "4?fileSystemType=LOCAL&splitStrategy=IDLE:1000,MESSAGES:1"); - from("direct:start5").to("hdfs2:///" + BASE_FILE.toUri() + "5?fileSystemType=LOCAL&splitStrategy=IDLE:1000,BYTES:5"); + from("direct:start1").to("hdfs2:localhost/" + BASE_FILE.toUri() + "1?fileSystemType=LOCAL&splitStrategy=MESSAGES:1"); + from("direct:start2").to("hdfs2:localhost/" + BASE_FILE.toUri() + "2?fileSystemType=LOCAL&splitStrategy=BYTES:5"); + from("direct:start3").to("hdfs2:localhost/" + BASE_FILE.toUri() + "3?fileSystemType=LOCAL&splitStrategy=IDLE:1000"); + from("direct:start4").to("hdfs2:localhost/" + BASE_FILE.toUri() + "4?fileSystemType=LOCAL&splitStrategy=IDLE:1000,MESSAGES:1"); + from("direct:start5").to("hdfs2:localhost/" + BASE_FILE.toUri() + "5?fileSystemType=LOCAL&splitStrategy=IDLE:1000,BYTES:5"); } }; } http://git-wip-us.apache.org/repos/asf/camel/blob/a8e974f8/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerTest.java ---------------------------------------------------------------------- diff --git a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerTest.java b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerTest.java index 5f2071b..5a5a827 100644 --- a/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerTest.java +++ b/components/camel-hdfs2/src/test/java/org/apache/camel/component/hdfs2/HdfsProducerTest.java @@ -388,35 +388,35 @@ public class HdfsProducerTest extends HdfsTestSupport { @Override public void configure() throws Exception { - from("direct:start1").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:start1").to("hdfs2://localhost/" + TEMP_DIR.toUri() + "/test-camel1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); /* For testing writables */ - from("direct:write_boolean").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-boolean?fileSystemType=LOCAL&valueType=BOOLEAN&fileType=SEQUENCE_FILE"); + from("direct:write_boolean").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-boolean?fileSystemType=LOCAL&valueType=BOOLEAN&fileType=SEQUENCE_FILE"); - from("direct:write_byte").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-byte?fileSystemType=LOCAL&valueType=BYTE&fileType=SEQUENCE_FILE"); + from("direct:write_byte").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-byte?fileSystemType=LOCAL&valueType=BYTE&fileType=SEQUENCE_FILE"); - from("direct:write_int").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-int?fileSystemType=LOCAL&valueType=INT&fileType=SEQUENCE_FILE"); + from("direct:write_int").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-int?fileSystemType=LOCAL&valueType=INT&fileType=SEQUENCE_FILE"); - from("direct:write_float").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-float?fileSystemType=LOCAL&valueType=FLOAT&fileType=SEQUENCE_FILE"); + from("direct:write_float").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-float?fileSystemType=LOCAL&valueType=FLOAT&fileType=SEQUENCE_FILE"); - from("direct:write_long").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-long?fileSystemType=LOCAL&valueType=LONG&fileType=SEQUENCE_FILE"); + from("direct:write_long").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-long?fileSystemType=LOCAL&valueType=LONG&fileType=SEQUENCE_FILE"); - from("direct:write_double").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-double?fileSystemType=LOCAL&valueType=DOUBLE&fileType=SEQUENCE_FILE"); + from("direct:write_double").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-double?fileSystemType=LOCAL&valueType=DOUBLE&fileType=SEQUENCE_FILE"); - from("direct:write_text1").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-text1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:write_text1").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-text1?fileSystemType=LOCAL&valueType=TEXT&fileType=SEQUENCE_FILE"); /* For testing key and value writing */ - from("direct:write_text2").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-text2?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=SEQUENCE_FILE"); + from("direct:write_text2").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-text2?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=SEQUENCE_FILE"); - from("direct:write_text3").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-text3?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=MAP_FILE"); + from("direct:write_text3").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-text3?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=MAP_FILE"); /* For testing ArrayFile */ - from("direct:write_text4").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-text4?fileSystemType=LOCAL&valueType=TEXT&fileType=ARRAY_FILE"); + from("direct:write_text4").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-text4?fileSystemType=LOCAL&valueType=TEXT&fileType=ARRAY_FILE"); /* For testing BloomMapFile */ - from("direct:write_text5").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-text5?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=BLOOMMAP_FILE"); + from("direct:write_text5").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-text5?fileSystemType=LOCAL&keyType=TEXT&valueType=TEXT&fileType=BLOOMMAP_FILE"); - from("direct:write_dynamic_filename").to("hdfs2:///" + TEMP_DIR.toUri() + "/test-camel-dynamic/?fileSystemType=LOCAL&valueType=TEXT"); + from("direct:write_dynamic_filename").to("hdfs2:localhost/" + TEMP_DIR.toUri() + "/test-camel-dynamic/?fileSystemType=LOCAL&valueType=TEXT"); } }; }