diff --git a/router/java/src/net/i2p/router/TunnelInfo.java b/router/java/src/net/i2p/router/TunnelInfo.java index 7e06e3463..be200069f 100644 --- a/router/java/src/net/i2p/router/TunnelInfo.java +++ b/router/java/src/net/i2p/router/TunnelInfo.java @@ -68,10 +68,11 @@ public interface TunnelInfo { */ public void testSuccessful(int responseTime); - public long getProcessedMessagesCount(); + public int getProcessedMessagesCount(); /** we know for sure that this many bytes travelled through the tunnel in its lifetime */ public long getVerifiedBytesTransferred(); + /** we know for sure that the given number of bytes were sent down the tunnel fully */ public void incrementVerifiedBytesTransferred(int numBytes); diff --git a/router/java/src/net/i2p/router/tunnel/TunnelCreatorConfig.java b/router/java/src/net/i2p/router/tunnel/TunnelCreatorConfig.java index 68d733f82..5306179a3 100644 --- a/router/java/src/net/i2p/router/tunnel/TunnelCreatorConfig.java +++ b/router/java/src/net/i2p/router/tunnel/TunnelCreatorConfig.java @@ -29,7 +29,7 @@ public class TunnelCreatorConfig implements TunnelInfo { private List _order; private long _replyMessageId; private final boolean _isInbound; - private long _messagesProcessed; + private int _messagesProcessed; private volatile long _verifiedBytesTransferred; private boolean _failed; private int _failures; @@ -127,7 +127,7 @@ public class TunnelCreatorConfig implements TunnelInfo { /** take note of a message being pumped through this tunnel */ public void incrementProcessedMessages() { _messagesProcessed++; } - public long getProcessedMessagesCount() { return _messagesProcessed; } + public int getProcessedMessagesCount() { return _messagesProcessed; } public void incrementVerifiedBytesTransferred(int bytes) { _verifiedBytesTransferred += bytes; @@ -144,6 +144,7 @@ public class TunnelCreatorConfig implements TunnelInfo { _context.profileManager().tunnelDataPushed1m(_peers[i], (int)normalized); } } + public long getVerifiedBytesTransferred() { return _verifiedBytesTransferred; } private static final int THROUGHPUT_COUNT = 3;