logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rgo...@apache.org
Subject svn commit: r1463333 - /logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java
Date Mon, 01 Apr 2013 23:29:54 GMT
Author: rgoers
Date: Mon Apr  1 23:29:54 2013
New Revision: 1463333

URL: http://svn.apache.org/r1463333
Log:
Only include up to batchSize events in a batch

Modified:
    logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java

Modified: logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java?rev=1463333&r1=1463332&r2=1463333&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java
(original)
+++ logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumePersistentManager.java
Mon Apr  1 23:29:54 2013
@@ -343,7 +343,7 @@ public class FlumePersistentManager exte
                                 status = cursor.getFirst(key, data, LockMode.RMW);
                                 if (batchSize > 1) {
                                     BatchEvent batch = new BatchEvent();
-                                    while (status == OperationStatus.SUCCESS) {
+                                    for (int i = 0; status == OperationStatus.SUCCESS &&
i < batchSize; ++i) {
                                         SimpleEvent event = createEvent(data);
                                         if (event != null) {
                                             batch.addEvent(event);



Mime
View raw message