You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ni...@apache.org on 2014/10/11 07:58:14 UTC
[2/6] git commit: CAMEL-7900 Honored chunksize in camel-hdfs
CAMEL-7900 Honored chunksize in camel-hdfs
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/fae7008d
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/fae7008d
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/fae7008d
Branch: refs/heads/camel-2.14.x
Commit: fae7008d2f93575cde20461539d215970c89025c
Parents: 230c0dd
Author: Willem Jiang <wi...@gmail.com>
Authored: Fri Oct 10 21:58:47 2014 +0800
Committer: Willem Jiang <wi...@gmail.com>
Committed: Sat Oct 11 13:56:35 2014 +0800
----------------------------------------------------------------------
.../main/java/org/apache/camel/component/hdfs/HdfsFileType.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/fae7008d/components/camel-hdfs/src/main/java/org/apache/camel/component/hdfs/HdfsFileType.java
----------------------------------------------------------------------
diff --git a/components/camel-hdfs/src/main/java/org/apache/camel/component/hdfs/HdfsFileType.java b/components/camel-hdfs/src/main/java/org/apache/camel/component/hdfs/HdfsFileType.java
index a3b2112..97c174f 100644
--- a/components/camel-hdfs/src/main/java/org/apache/camel/component/hdfs/HdfsFileType.java
+++ b/components/camel-hdfs/src/main/java/org/apache/camel/component/hdfs/HdfsFileType.java
@@ -75,7 +75,7 @@ public enum HdfsFileType {
public long next(HdfsInputStream hdfsistr, Holder<Object> key, Holder<Object> value) {
try {
ByteArrayOutputStream bos = new ByteArrayOutputStream(hdfsistr.getChunkSize());
- byte buf[] = new byte[HdfsConstants.DEFAULT_BUFFERSIZE];
+ byte buf[] = new byte[hdfsistr.getChunkSize()];
int bytesRead = ((InputStream) hdfsistr.getIn()).read(buf);
if (bytesRead >= 0) {
bos.write(buf, 0, bytesRead);