Skip to content

Commit

Permalink
Merge branch 'seata:develop' into oracle_multi_pk
Browse files Browse the repository at this point in the history
  • Loading branch information
tuwenlin committed May 5, 2022
2 parents c711b4d + 8c350b0 commit 234a24c
Show file tree
Hide file tree
Showing 34 changed files with 669 additions and 385 deletions.
10 changes: 9 additions & 1 deletion changes/1.5.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,13 @@ Seata 是一款开源的分布式事务解决方案,提供高性能和简单
- [[#4459](https://github.com/seata/seata/pull/4459)] 修复develop版本下oracle和pgsql数据库生成前后镜像失败的问题
- [[#4471](https://github.com/seata/seata/pull/4471)] 修复develop分支下,运行时切换事务分组对应集群引起的错误
- [[#4474](https://github.com/seata/seata/pull/4474)] 修复Mysql多位Bit类型字段回滚错误
- [[#4492](https://github.com/seata/seata/pull/4492)] 修复develop分支下eureka注册中心无法动态更新服务列表的问题
- [[#4228](https://github.com/seata/seata/pull/4228)] 修复tc获取不同ip的rm连接导致的xa模式资源悬挂问题
- [[#4535](https://github.com/seata/seata/pull/4535)] 修复FileSessionManagerTest单测错误
- [[#4561](https://github.com/seata/seata/pull/4535)] 修复 allSessions/findGlobalSessions 某些情况下返回null
- [[#4505](https://github.com/seata/seata/pull/4505)] 修复time类型的fastjson序列化问题
- [[#4579](https://github.com/seata/seata/pull/4579)] 修复MySQLInsertOrUpdateExecutor的prepareUndoLogAll


### optimize:
- [[#4163](https://github.com/seata/seata/pull/4163)] 完善开发者奉献文档
Expand Down Expand Up @@ -212,7 +217,9 @@ Seata 是一款开源的分布式事务解决方案,提供高性能和简单
- [[#4478](https://github.com/seata/seata/pull/4478)] 优化 Nacos 配置和注册元数据属性
- [[#4522](https://github.com/seata/seata/pull/4522)] 优化 GC 参数
- [[#4517](https://github.com/seata/seata/pull/4517)] 增强失败/超时状态的监控

- [[#4451](https://github.com/seata/seata/pull/4451)] filesessionmanager改为单例并优化任务线程池处理
- [[#4551](https://github.com/seata/seata/pull/4551)] 优化 metrics rt 统计问题
- [[#4574](https://github.com/seata/seata/pull/4574)] 支持 accessKey/secretKey 配置自动注入

### test:

Expand Down Expand Up @@ -267,6 +274,7 @@ Seata 是一款开源的分布式事务解决方案,提供高性能和简单
- [Bughue](https://github.com/Bughue)
- [liuqiufeng](https://github.com/liuqiufeng)
- [onlinechild](https://github.com/onlinechild)
- [xjlgod](https://github.com/xjlgod)

同时,我们收到了社区反馈的很多有价值的issue和建议,非常感谢大家。

Expand Down
15 changes: 13 additions & 2 deletions changes/en-us/1.5.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,11 @@
- [[#4459](https://github.com/seata/seata/pull/4459)] fix the failure to obtain before image and after image on oracle and pgsql of the develop branch
- [[#4471](https://github.com/seata/seata/pull/4471)] in branch 'develop', fix the error when service.vgroupMapping change
- [[#4474](https://github.com/seata/seata/pull/4474)] fix Mysql multi-bit Bit type field rollback error
- [[#4492](https://github.com/seata/seata/pull/4492)] fix the failure to update cluster list dynamically when use eureka of the develop branch
- [[#4535](https://github.com/seata/seata/pull/4535)] fix FileSessionManagerTest fail

- [[#4561](https://github.com/seata/seata/pull/4535)] fix allSessions/findGlobalSessions may return null and cause npe
- [[#4505](https://github.com/seata/seata/pull/4505)] fix fastjson serialization of time data types
- [[#4579](https://github.com/seata/seata/pull/4579)] fix prepareUndoLogAll of MySQLInsertOrUpdateExecutor


### optimize:
Expand Down Expand Up @@ -219,9 +222,15 @@
- [[#4478](https://github.com/seata/seata/pull/4478)] optimize Nacos config and naming properties
- [[#4522](https://github.com/seata/seata/pull/4522)] optimize GC parameters in JVM
- [[#4517](https://github.com/seata/seata/pull/4517)] enhance fail/timeout status metric and log level
- [[#4451](https://github.com/seata/seata/pull/4451)] filesessionmanager changed to singleton and optimized task thread pool processing
- [[#4551](https://github.com/seata/seata/pull/4551)] optimize metrics rt statistics
- [[#4574](https://github.com/seata/seata/pull/4574)] support accessKey/secretKey auto configuration




### test:

### test:



Expand Down Expand Up @@ -273,6 +282,8 @@
- [Bughue](https://github.com/Bughue)
- [liuqiufeng](https://github.com/liuqiufeng)
- [onlinechild](https://github.com/onlinechild)
- [xjlgod](https://github.com/xjlgod)




Expand Down
20 changes: 18 additions & 2 deletions common/src/main/java/io/seata/common/ConfigurationKeys.java
Original file line number Diff line number Diff line change
Expand Up @@ -363,9 +363,24 @@ public interface ConfigurationKeys {
String RECOVERY_PREFIX = SERVER_PREFIX + "recovery.";

/**
* The constant HANDLE_ALL_SESSION_PERIOD.
* The constant COMMITING_RETRY_PERIOD.
*/
String HANDLE_ALL_SESSION_PERIOD = RECOVERY_PREFIX + "handleAllSessionPeriod";
String COMMITING_RETRY_PERIOD = RECOVERY_PREFIX + "committingRetryPeriod";

/**
* The constant ASYN_COMMITING_RETRY_PERIOD.
*/
String ASYN_COMMITING_RETRY_PERIOD = RECOVERY_PREFIX + "asynCommittingRetryPeriod";

/**
* The constant ROLLBACKING_RETRY_PERIOD.
*/
String ROLLBACKING_RETRY_PERIOD = RECOVERY_PREFIX + "rollbackingRetryPeriod";

/**
* The constant TIMEOUT_RETRY_PERIOD.
*/
String TIMEOUT_RETRY_PERIOD = RECOVERY_PREFIX + "timeoutRetryPeriod";

/**
* The constant CLIENT_UNDO_PREFIX.
Expand All @@ -376,6 +391,7 @@ public interface ConfigurationKeys {
* The constant TRANSACTION_UNDO_DATA_VALIDATION.
*/
String TRANSACTION_UNDO_DATA_VALIDATION = CLIENT_UNDO_PREFIX + "dataValidation";

/**
* The constant TRANSACTION_UNDO_LOG_SERIALIZATION.
*/
Expand Down
5 changes: 0 additions & 5 deletions common/src/main/java/io/seata/common/Constants.java
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,6 @@ public interface Constants {
*/
String RETRY_ROLLBACKING = "RetryRollbacking";

/**
* The constant HANDLE_ALL_SESSION
*/
String HANDLE_ALL_SESSION = "HandleAllSession";

/**
* The constant RETRY_COMMITTING
*/
Expand Down
119 changes: 102 additions & 17 deletions core/src/main/java/io/seata/core/event/GlobalTransactionEvent.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,25 @@
*/
package io.seata.core.event;

import io.seata.core.model.GlobalStatus;

/**
* Event data for global transaction.
*
* @author zhengyangyong
*/
public class GlobalTransactionEvent implements Event {
/**
* The constant ROLE_TC.
*/
public static final String ROLE_TC = "tc";

/**
* The constant ROLE_TM.
*/
public static final String ROLE_TM = "tm";

/**
* The constant ROLE_RM.
*/
public static final String ROLE_RM = "rm";

/**
Expand All @@ -48,7 +55,7 @@ public class GlobalTransactionEvent implements Event {
* business applicationId
*/
private String applicationId;

/**
* Transaction Service Group
*/
Expand All @@ -67,56 +74,134 @@ public class GlobalTransactionEvent implements Event {
/**
* Transaction Status
*/
private final GlobalStatus status;
private final String status;

private final boolean retryGlobal;

private boolean retryBranch;

/**
* Instantiates a new Global transaction event.
*
* @param id the id
* @param role the role
* @param name the name
* @param applicationId the application id
* @param group the group
* @param beginTime the begin time
* @param endTime the end time
* @param status the status
* @param retryGlobal the retry(1. delay delete global session 2. asyn retry branch session)
* @param retryBranch retry branch session
*/
public GlobalTransactionEvent(long id, String role, String name, String applicationId, String group, Long beginTime, Long endTime, String status, boolean retryGlobal, boolean retryBranch) {
this.id = id;
this.role = role;
this.name = name;
this.applicationId = applicationId;
this.group = group;
this.beginTime = beginTime;
this.endTime = endTime;
this.status = status;
this.retryGlobal = retryGlobal;
this.retryBranch = retryBranch;
}

/**
* Gets id.
*
* @return the id
*/
public long getId() {
return id;
}

/**
* Gets role.
*
* @return the role
*/
public String getRole() {
return role;
}

/**
* Gets name.
*
* @return the name
*/
public String getName() {
return name;
}

/**
* Gets application id.
*
* @return the application id
*/
public String getApplicationId() {
return applicationId;
}


/**
* Gets group.
*
* @return the group
*/
public String getGroup() {
return group;
}

/**
* Gets begin time.
*
* @return the begin time
*/
public Long getBeginTime() {
return beginTime;
}

/**
* Gets end time.
*
* @return the end time
*/
public Long getEndTime() {
return endTime;
}

public GlobalStatus getStatus() {
/**
* Gets status.
*
* @return the status
*/
public String getStatus() {
return status;
}

public GlobalTransactionEvent(long id, String role, String name, String applicationId,
String group, Long beginTime, Long endTime, GlobalStatus status) {
this.id = id;
this.role = role;
this.name = name;
this.applicationId = applicationId;
this.group = group;
this.beginTime = beginTime;
this.endTime = endTime;
this.status = status;
/**
* Is retry boolean.
*
* @return the boolean
*/
public boolean isRetryGlobal() {
return retryGlobal;
}

/**
* Is retry branch boolean.
*
* @return the boolean
*/
public boolean isRetryBranch() {
return retryBranch;
}

@Override
public String toString() {
return "GlobalTransactionEvent{" + "id=" + id + ", role='" + role + '\'' + ", name='" + name + '\''
+ ", applicationId='" + applicationId + '\'' + ", group='" + group + '\'' + ", beginTime=" + beginTime
+ ", endTime=" + endTime + ", status=" + status + '}';
+ ", endTime=" + endTime + ", status='" + status + '\'' + ", retryGlobal=" + retryGlobal + ", retryBranch="
+ retryBranch + '}';
}
}

0 comments on commit 234a24c

Please sign in to comment.