Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix: fix ProtocolV1SerializerTest failed #6278

Merged
merged 2 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion changes/en-us/2.x.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Add changes here for all PR submitted to the 2.x branch.
- [[#6261](https://github.com/apache/incubator-seata/pull/6261)] AT mode support the URL of a PGSQL cluster
- [[#6256](https://github.com/apache/incubator-seata/pull/6256)] fix raft-discovery cannot read registry configuration for seata-all sdk
- [[#6232](https://github.com/apache/incubator-seata/pull/6232)] convert to utf8mb4 if mysql column is json type
- [[#6278](https://github.com/apache/incubator-seata/pull/6278)] fix ProtocolV1SerializerTest failed


### optimize:
Expand Down Expand Up @@ -65,7 +66,7 @@ Add changes here for all PR submitted to the 2.x branch.
- [[#6271](https://github.com/apache/incubator-seata/pull/6271)] unifty the git information
- [[#6265](https://github.com/apache/incubator-seata/pull/6265)] optimization fails to build frontend on arm64
- [[#6267](https://github.com/apache/incubator-seata/pull/6267)] add Server deserialization validation
- - [[#6275](https://github.com/apache/incubator-seata/pull/6275)] optimize the label's format in .asf.yaml
- [[#6275](https://github.com/apache/incubator-seata/pull/6275)] optimize the label's format in .asf.yaml

### security:
- [[#6069](https://github.com/apache/incubator-seata/pull/6069)] Upgrade Guava dependencies to fix security vulnerabilities
Expand Down
1 change: 1 addition & 0 deletions changes/zh-cn/2.x.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
- [[#6261](https://github.com/apache/incubator-seata/pull/6261)] at模式支持pgsql集群模式url
- [[#6256](https://github.com/apache/incubator-seata/pull/6256)] 修复在seata-all sdk下,raft-discovery模块不能读取registry.conf的配置的问题
- [[#6232](https://github.com/apache/incubator-seata/pull/6232)] 修复在mysql的json类型下出现Cannot create a JSON value from a string with CHARACTER SET 'binary'问题
- [[#6278](https://github.com/apache/incubator-seata/pull/6278)] 修复 ProtocolV1SerializerTest 失败问题

### optimize:
- [[#6031](https://github.com/apache/incubator-seata/pull/6031)] 添加undo_log表的存在性校验
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,6 @@ public class ProtocolV1Decoder extends LengthFieldBasedFrameDecoder {
public ProtocolV1Decoder() {
// default is 8M
this(ProtocolConstants.MAX_FRAME_LENGTH);
String serializerName = CONFIG.getConfig(ConfigurationKeys.SERIALIZE_FOR_RPC, SerializerType.SEATA.name());
this.serializerType = SerializerType.getByName(serializerName);
}

public ProtocolV1Decoder(int maxFrameLength) {
Expand All @@ -84,6 +82,8 @@ int lengthFieldLength, FullLength is int(4B). so values is 4
int initialBytesToStrip we will check magic code and version self, so do not strip any bytes. so values is 0
*/
super(maxFrameLength, 3, 4, -7, 0);
String serializerName = CONFIG.getConfig(ConfigurationKeys.SERIALIZE_FOR_RPC, SerializerType.SEATA.name());
this.serializerType = SerializerType.getByName(serializerName);
}

@Override
Expand Down
Loading