chukwa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From asrab...@apache.org
Subject svn commit: r926344 - in /hadoop/chukwa/trunk: ./ src/docs/src/documentation/content/xdocs/ src/java/org/apache/hadoop/chukwa/datacollection/adaptor/ src/java/org/apache/hadoop/chukwa/util/ src/test/org/apache/hadoop/chukwa/datacollection/adaptor/
Date Mon, 22 Mar 2010 21:22:35 GMT
Author: asrabkin
Date: Mon Mar 22 21:22:34 2010
New Revision: 926344

URL: http://svn.apache.org/viewvc?rev=926344&view=rev
Log:
CHUKWA-466. Fix failing tests. 

Modified:
    hadoop/chukwa/trunk/CHANGES.txt
    hadoop/chukwa/trunk/src/docs/src/documentation/content/xdocs/agent.xml
    hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/adaptor/UDPAdaptor.java
    hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/util/TempFileUtil.java
    hadoop/chukwa/trunk/src/test/org/apache/hadoop/chukwa/datacollection/adaptor/TestBufferingWrappers.java

Modified: hadoop/chukwa/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/CHANGES.txt?rev=926344&r1=926343&r2=926344&view=diff
==============================================================================
--- hadoop/chukwa/trunk/CHANGES.txt (original)
+++ hadoop/chukwa/trunk/CHANGES.txt Mon Mar 22 21:22:34 2010
@@ -64,6 +64,8 @@ Trunk (unreleased changes)
 
   BUG FIXES
 
+    CHUKWA-466. Fix failing tests. (asrabkin)
+
     CHUKWA-457. Fix TestUserResource. (Eric Yang via asrabkin)
 
     CHUKWA-463. Fix pattern match for tags. (Guillermo Perez via asrabkin)

Modified: hadoop/chukwa/trunk/src/docs/src/documentation/content/xdocs/agent.xml
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/src/docs/src/documentation/content/xdocs/agent.xml?rev=926344&r1=926343&r2=926344&view=diff
==============================================================================
--- hadoop/chukwa/trunk/src/docs/src/documentation/content/xdocs/agent.xml (original)
+++ hadoop/chukwa/trunk/src/docs/src/documentation/content/xdocs/agent.xml Mon Mar 22 21:22:34
2010
@@ -160,7 +160,7 @@ The same as the base FileTailingAdaptor,
   it is possible to exceed your system's limit on open files.
   A file pattern can be specified as an optional second parameter.
 
-<source>add DirTailingAdaptor logs /var/log/ [pattern] filetailer.CharFileTailingAdaptorUTF8
0</source>
+<source>add DirTailingAdaptor logs /var/log/ *.log filetailer.CharFileTailingAdaptorUTF8
0</source>
 
 </li>
 <li><strong>ExecAdaptor</strong> Takes a frequency (in milliseconds) as
optional 

Modified: hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/adaptor/UDPAdaptor.java
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/adaptor/UDPAdaptor.java?rev=926344&r1=926343&r2=926344&view=diff
==============================================================================
--- hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/adaptor/UDPAdaptor.java
(original)
+++ hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/datacollection/adaptor/UDPAdaptor.java
Mon Mar 22 21:22:34 2010
@@ -86,7 +86,7 @@ public class UDPAdaptor extends Abstract
     try {
       running = false;
       ds.close();
-      if(shutdownPolicy == AdaptorShutdownPolicy.GRACEFULLY)
+//      if(shutdownPolicy == AdaptorShutdownPolicy.GRACEFULLY)
         lt.join();
     } catch(InterruptedException e) {}
     return bytesReceived;

Modified: hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/util/TempFileUtil.java
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/util/TempFileUtil.java?rev=926344&r1=926343&r2=926344&view=diff
==============================================================================
--- hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/util/TempFileUtil.java (original)
+++ hadoop/chukwa/trunk/src/java/org/apache/hadoop/chukwa/util/TempFileUtil.java Mon Mar 22
21:22:34 2010
@@ -50,21 +50,22 @@ public class TempFileUtil {
   static class RandSeqFileWriter {
     java.util.Random r = new java.util.Random();
     long lastSeqID = 0;
-     public ChunkImpl getARandomChunk() {
-       int ms = r.nextInt(1000);
-       String line = "2008-05-29 10:42:22," + ms
-           + " INFO org.apache.hadoop.dfs.DataNode: Some text goes here"
-           + r.nextInt() + "\n";
-   
-       ChunkImpl c = new ChunkImpl("HadoopLogProcessor", "test",
-           line.length()  + lastSeqID, line.getBytes(), null);
-       lastSeqID += line.length();
-       c.addTag("cluster=\"foocluster\"");
-       return c;
-     }
-
+    
+    public ChunkImpl getARandomChunk() {
+      int ms = r.nextInt(1000);
+      String line = "2008-05-29 10:42:22," + ms
+          + " INFO org.apache.hadoop.dfs.DataNode: Some text goes here"
+          + r.nextInt() + "\n";
+       
+      ChunkImpl c = new ChunkImpl("HadoopLogProcessor", "test",
+      line.length()  + lastSeqID, line.getBytes(), null);
+      lastSeqID += line.length();
+      c.addTag("cluster=\"foocluster\"");
+      return c;
+    }
   }
-   public static void writeASinkFile(Configuration conf, FileSystem fileSys, Path dest,
+  
+  public static void writeASinkFile(Configuration conf, FileSystem fileSys, Path dest,
        int chunks) throws IOException {
      FSDataOutputStream out = fileSys.create(dest);
 

Modified: hadoop/chukwa/trunk/src/test/org/apache/hadoop/chukwa/datacollection/adaptor/TestBufferingWrappers.java
URL: http://svn.apache.org/viewvc/hadoop/chukwa/trunk/src/test/org/apache/hadoop/chukwa/datacollection/adaptor/TestBufferingWrappers.java?rev=926344&r1=926343&r2=926344&view=diff
==============================================================================
--- hadoop/chukwa/trunk/src/test/org/apache/hadoop/chukwa/datacollection/adaptor/TestBufferingWrappers.java
(original)
+++ hadoop/chukwa/trunk/src/test/org/apache/hadoop/chukwa/datacollection/adaptor/TestBufferingWrappers.java
Mon Mar 22 21:22:34 2010
@@ -88,6 +88,7 @@ public class TestBufferingWrappers exten
       assertEquals(c.getSeqID(), STR.length());
       
       agent.stopAdaptor(name, AdaptorShutdownPolicy.RESTARTING);
+      Thread.sleep(500); //for socket to deregister
       name =agent.processAddCommand("add "+ADAPTORID + " = "+adaptor+" UDPAdaptor raw "+PORTNO
+ " 0");
       assertEquals(name, ADAPTORID);
     }



Mime
View raw message