You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by li...@apache.org on 2019/06/04 10:10:00 UTC

[dubbo] branch performance-tuning-2.7.x updated: unify heartbeat stamp key

This is an automated email from the ASF dual-hosted git repository.

liujun pushed a commit to branch performance-tuning-2.7.x
in repository https://gitbox.apache.org/repos/asf/dubbo.git


The following commit(s) were added to refs/heads/performance-tuning-2.7.x by this push:
     new 5cab5d3  unify heartbeat stamp key
5cab5d3 is described below

commit 5cab5d36d4573bd47180e8ee27212031e1d8ec08
Author: ken.lj <ke...@gmail.com>
AuthorDate: Tue Jun 4 18:09:48 2019 +0800

    unify heartbeat stamp key
---
 .../dubbo/remoting/exchange/support/header/HeartBeatTaskTest.java  | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/exchange/support/header/HeartBeatTaskTest.java b/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/exchange/support/header/HeartBeatTaskTest.java
index 3249d46..9e0ee0f 100644
--- a/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/exchange/support/header/HeartBeatTaskTest.java
+++ b/dubbo-remoting/dubbo-remoting-api/src/test/java/org/apache/dubbo/remoting/exchange/support/header/HeartBeatTaskTest.java
@@ -21,6 +21,7 @@ import org.apache.dubbo.common.URL;
 import org.apache.dubbo.common.timer.HashedWheelTimer;
 import org.apache.dubbo.remoting.Channel;
 import org.apache.dubbo.remoting.exchange.Request;
+
 import org.junit.jupiter.api.Assertions;
 import org.junit.jupiter.api.BeforeEach;
 import org.junit.jupiter.api.Test;
@@ -63,10 +64,8 @@ public class HeartBeatTaskTest {
         long now = System.currentTimeMillis();
 
         url = url.addParameter(DUBBO_VERSION_KEY, "2.1.1");
-        channel.setAttribute(
-                HeaderExchangeHandler.KEY_READ_TIMESTAMP, now);
-        channel.setAttribute(
-                HeaderExchangeHandler.KEY_WRITE_TIMESTAMP, now);
+        channel.setAttribute(HeartbeatHandler.KEY_READ_TIMESTAMP, now);
+        channel.setAttribute(HeartbeatHandler.KEY_WRITE_TIMESTAMP, now);
 
         heartbeatTimer.newTimeout(heartbeatTimerTask, 250, TimeUnit.MILLISECONDS);