flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From u..@apache.org
Subject flink git commit: [FLINK-1646] [runtime] Improve 'insufficient number of network buffers' error msg
Date Wed, 04 Mar 2015 17:40:57 GMT
Repository: flink
Updated Branches:
  refs/heads/master 9c6413740 -> 9c0d6347e


[FLINK-1646] [runtime] Improve 'insufficient number of network buffers' error msg

Add a hint about how to configure the number of network buffers.


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/9c0d6347
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/9c0d6347
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/9c0d6347

Branch: refs/heads/master
Commit: 9c0d6347edfdf3b7460168c1394a4473eb690105
Parents: 9c64137
Author: Ufuk Celebi <uce@apache.org>
Authored: Wed Mar 4 18:38:21 2015 +0100
Committer: Ufuk Celebi <uce@apache.org>
Committed: Wed Mar 4 18:40:36 2015 +0100

----------------------------------------------------------------------
 .../flink/runtime/io/network/buffer/NetworkBufferPool.java  | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/9c0d6347/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/NetworkBufferPool.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/NetworkBufferPool.java
b/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/NetworkBufferPool.java
index 1944489..8de7c36 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/NetworkBufferPool.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/io/network/buffer/NetworkBufferPool.java
@@ -18,6 +18,7 @@
 
 package org.apache.flink.runtime.io.network.buffer;
 
+import org.apache.flink.configuration.ConfigConstants;
 import org.apache.flink.core.memory.MemorySegment;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -152,7 +153,13 @@ public class NetworkBufferPool implements BufferPoolFactory {
 			// Ensure that the number of required buffers can be satisfied.
 			// With dynamic memory management this should become obsolete.
 			if (numTotalRequiredBuffers + numRequiredBuffers > totalNumberOfMemorySegments) {
-				throw new IOException(String.format("Insufficient number of network buffers: required
%d, but only %d of %d available.", numRequiredBuffers, totalNumberOfMemorySegments - numTotalRequiredBuffers,
totalNumberOfMemorySegments));
+				throw new IOException(String.format("Insufficient number of network buffers: " +
+								"required %d, but only %d available. The total number of network " +
+								"buffers is currently set to %d. You can increase this " +
+								"number by setting the configuration key '" +
+								ConfigConstants.TASK_MANAGER_NETWORK_NUM_BUFFERS_KEY +  "'.",
+						numRequiredBuffers, totalNumberOfMemorySegments - numTotalRequiredBuffers,
+						totalNumberOfMemorySegments));
 			}
 
 			this.numTotalRequiredBuffers += numRequiredBuffers;


Mime
View raw message