From c7949f5f4e48b4758df5f3d99752b28f8f38ac96 Mon Sep 17 00:00:00 2001 From: ZhiQiang Gu <43897640+yunfeiyanggzq@users.noreply.github.com> Date: Thu, 16 Jul 2020 15:48:18 +0800 Subject: [PATCH] Fix incorrect protocol description in FlowRequestData writer/decoder (#1607) Signed-off-by: yunfeiyanggzq --- .../cluster/client/codec/data/FlowRequestDataWriter.java | 2 +- .../cluster/server/codec/data/FlowRequestDataDecoder.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sentinel-cluster/sentinel-cluster-client-default/src/main/java/com/alibaba/csp/sentinel/cluster/client/codec/data/FlowRequestDataWriter.java b/sentinel-cluster/sentinel-cluster-client-default/src/main/java/com/alibaba/csp/sentinel/cluster/client/codec/data/FlowRequestDataWriter.java index a134d279..7c8acc81 100644 --- a/sentinel-cluster/sentinel-cluster-client-default/src/main/java/com/alibaba/csp/sentinel/cluster/client/codec/data/FlowRequestDataWriter.java +++ b/sentinel-cluster/sentinel-cluster-client-default/src/main/java/com/alibaba/csp/sentinel/cluster/client/codec/data/FlowRequestDataWriter.java @@ -22,7 +22,7 @@ import io.netty.buffer.ByteBuf; /** * +-------------------+--------------+----------------+---------------+------------------+ - * | RequestID(8 byte) | Type(1 byte) | FlowID(4 byte) | Count(4 byte) | PriorityFlag (1) | + * | RequestID(8 byte) | Type(1 byte) | FlowID(8 byte) | Count(4 byte) | PriorityFlag (1) | * +-------------------+--------------+----------------+---------------+------------------+ * * @author Eric Zhao diff --git a/sentinel-cluster/sentinel-cluster-server-default/src/main/java/com/alibaba/csp/sentinel/cluster/server/codec/data/FlowRequestDataDecoder.java b/sentinel-cluster/sentinel-cluster-server-default/src/main/java/com/alibaba/csp/sentinel/cluster/server/codec/data/FlowRequestDataDecoder.java index 803d08b2..5391be58 100644 --- a/sentinel-cluster/sentinel-cluster-server-default/src/main/java/com/alibaba/csp/sentinel/cluster/server/codec/data/FlowRequestDataDecoder.java +++ b/sentinel-cluster/sentinel-cluster-server-default/src/main/java/com/alibaba/csp/sentinel/cluster/server/codec/data/FlowRequestDataDecoder.java @@ -25,7 +25,7 @@ import io.netty.buffer.ByteBuf; * Decoder for {@link FlowRequestData} from {@code ByteBuf} stream. The layout: *

*
- * | flow ID (4) | count (4) | priority flag (1) |
+ * | flow ID (8) | count (4) | priority flag (1) |
  * 
* * @author Eric Zhao