Skip to content

Commit

Permalink
Update seata-all to handle cglib breaking unit test execution with Gr…
Browse files Browse the repository at this point in the history
…aalVM Tracing Agent
  • Loading branch information
linghengqian committed Feb 15, 2023
1 parent 16a2d6d commit 29c6ae8
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
<jboss-logging.version>3.2.1.Final</jboss-logging.version>
<btm.version>2.1.3</btm.version>

<seata.version>1.4.2</seata.version>
<seata.version>1.6.1</seata.version>

<junit4.version>4.13.2</junit4.version>
<hamcrest.version>1.3</hamcrest.version>
Expand Down
8 changes: 7 additions & 1 deletion kernel/transaction/type/base/seata-at/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<name>${project.artifactId}</name>

<properties>
<seata.version>1.4.2</seata.version>
<seata.version>1.6.1</seata.version>
</properties>

<dependencies>
Expand All @@ -51,5 +51,11 @@
<version>${seata.version}</version>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,21 @@ public void channelRead(final ChannelHandlerContext ctx, final Object msg) {
response.setBody(HeartbeatMessage.PONG);
} else if (requestBody instanceof MergedWarpMessage) {
setMergeResultMessage(request, response);
} else if (requestBody instanceof GlobalBeginRequest) {
GlobalBeginResponse globalBeginResponse = new GlobalBeginResponse();
globalBeginResponse.setXid(XID.generateXID(id.incrementAndGet()));
globalBeginResponse.setResultCode(ResultCode.Success);
response.setBody(globalBeginResponse);
} else if (requestBody instanceof GlobalCommitRequest) {
GlobalCommitResponse globalCommitResponse = new GlobalCommitResponse();
globalCommitResponse.setResultCode(ResultCode.Success);
globalCommitResponse.setGlobalStatus(GlobalStatus.Committing);
response.setBody(globalCommitResponse);
} else if (requestBody instanceof GlobalRollbackRequest) {
GlobalRollbackResponse globalRollbackResponse = new GlobalRollbackResponse();
globalRollbackResponse.setResultCode(ResultCode.Success);
globalRollbackResponse.setGlobalStatus(GlobalStatus.Rollbacked);
response.setBody(globalRollbackResponse);
}
if (requestBody != HeartbeatMessage.PING) {
requestQueue.offer(requestBody);
Expand Down

0 comments on commit 29c6ae8

Please sign in to comment.