chukwa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asrab...@apache.org
Subject svn commit: r832430 - in /hadoop/chukwa/trunk: CHANGES.txt src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java
Date Tue, 03 Nov 2009 14:33:26 GMT
Author: asrabkin
Date: Tue Nov  3 14:33:25 2009
New Revision: 832430

URL: http://svn.apache.org/viewvc?rev=832430&view=rev
Log:
CHUKWA-407. Make SocketTeeWriter work in single-stage pipeline. Contributed by Thushara Wijeratna.

Modified:
    hadoop/chukwa/trunk/CHANGES.txt
    hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java

Modified: hadoop/chukwa/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/CHANGES.txt?rev=832430&r1=832429&r2=832430&view=diff
==============================================================================
--- hadoop/chukwa/trunk/CHANGES.txt (original)
+++ hadoop/chukwa/trunk/CHANGES.txt Tue Nov  3 14:33:25 2009
@@ -6,6 +6,8 @@
 
   IMPROVEMENTS
 
+    CHUKWA-407. Make SocketTeeWriter work in single-stage pipeline. (Thushara Wijeratna via
asrabkin)
+
     CHUKWA-408. Add optional metadata to real-time feed. (asrabkin)
 
   BUG FIXES

Modified: hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java?rev=832430&r1=832429&r2=832430&view=diff
==============================================================================
--- hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java
(original)
+++ hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/writer/SocketTeeWriter.java
Tue Nov  3 14:33:25 2009
@@ -246,7 +246,9 @@
 
   @Override
   public CommitStatus add(List<Chunk> chunks) throws WriterException {
-    CommitStatus rv = next.add(chunks); //pass data through
+    CommitStatus rv = ChukwaWriter.COMMIT_OK;
+    if (next != null)
+	rv = next.add(chunks); //pass data through
     synchronized(tees) {
       Iterator<Tee> loop = tees.iterator();
       while(loop.hasNext()) {
@@ -261,7 +263,8 @@
 
   @Override
   public void close() throws WriterException {
-    next.close();
+    if (next != null) 
+	next.close();
     running = false;
     listenThread.shutdown();
   }



Mime
View raw message