Skip to content

Commit 827a847

Browse files
committed
HADOOP-16266. Add more fine-grained processing time metrics to the RPC layer -follow-on patch.
This follow-on patch to HADOOP-16266 fixes up the problem where logs were being full of stack traces because the timeout passed down to select was in nanos, whereas the API expected millis. Contributed by Erik Krogen. Change-Id: I5c6e9ddf68127b1d7e0ca0e179d036eb9941e445
1 parent 50909a7 commit 827a847

File tree

1 file changed

+2
-1
lines changed
  • hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc

1 file changed

+2
-1
lines changed

hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/ipc/Server.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1482,7 +1482,8 @@ private void doRunLoop() {
14821482
while (running) {
14831483
try {
14841484
waitPending(); // If a channel is being registered, wait.
1485-
writeSelector.select(PURGE_INTERVAL_NANOS);
1485+
writeSelector.select(
1486+
TimeUnit.NANOSECONDS.toMillis(PURGE_INTERVAL_NANOS));
14861487
Iterator<SelectionKey> iter = writeSelector.selectedKeys().iterator();
14871488
while (iter.hasNext()) {
14881489
SelectionKey key = iter.next();

0 commit comments

Comments
 (0)