Skip to content
Closed
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
4 changes: 2 additions & 2 deletions all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -416,8 +416,8 @@
<scope>provided</scope>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
Expand Down
2 changes: 2 additions & 0 deletions changes/en-us/2.x.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ Add changes here for all PR submitted to the 2.x branch.

- [[#7632](https://github.com/apache/incubator-seata/pull/7632)] upgrade sha.js to version 2.4.12
- [[#7633](https://github.com/apache/incubator-seata/pull/7633)] Upgrade cipher-base to version 1.0.6
- [[#7666](https://github.com/apache/incubator-seata/pull/7667)] Update commons-lang to 3.18.0


### test:
Expand Down Expand Up @@ -99,6 +100,7 @@ Thanks to these contributors for their code commits. Please report an unintended
- [WangzJi](https://github.com/WangzJi)
- [Asuka-star](https://github.com/Asuka-star)
- [YoWuwuuuw](https://github.com/YoWuwuuuw)
- [yougecn](https://github.com/yougecn)


Also, we receive many valuable issues, questions and advices from our community. Thanks for you all.
2 changes: 2 additions & 0 deletions changes/zh-cn/2.x.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@

- [[#7632](https://github.com/apache/incubator-seata/pull/7632)] 升级sha.js为2.4.12
- [[#7633](https://github.com/apache/incubator-seata/pull/7633)] 升级cipher-base为1.0.6
- [[#7666](https://github.com/apache/incubator-seata/pull/7667)] 升级 commons-lang 为 3.18.0


### test:
Expand Down Expand Up @@ -100,6 +101,7 @@
- [WangzJi](https://github.com/WangzJi)
- [Asuka-star](https://github.com/Asuka-star)
- [YoWuwuuuw](https://github.com/YoWuwuuuw)
- [yougecn](https://github.com/yougecn)


同时,我们收到了社区反馈的很多有价值的issue和建议,非常感谢大家。
4 changes: 2 additions & 2 deletions common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.common.exception;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.EnhancedServiceLoader;

import java.text.MessageFormat;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.common.loader;

import org.apache.commons.lang.exception.ExceptionUtils;
import org.apache.commons.lang3.exception.ExceptionUtils;
import org.apache.seata.common.Constants;
import org.apache.seata.common.executor.Initialize;
import org.apache.seata.common.util.CollectionUtils;
Expand Down Expand Up @@ -436,7 +436,7 @@ private S loadExtension(ClassLoader loader, Class<?>[] argTypes, Object[] args,
throw e;
} catch (Throwable e) {
throw new EnhancedServiceNotFoundException("not found service provider for : " + type.getName()
+ " caused by " + ExceptionUtils.getFullStackTrace(e));
+ " caused by " + ExceptionUtils.getStackTrace(e));
}
}

Expand All @@ -456,7 +456,7 @@ private S loadExtension(
throw (EnhancedServiceNotFoundException) e;
} else {
throw new EnhancedServiceNotFoundException("not found service provider for : " + type.getName()
+ " caused by " + ExceptionUtils.getFullStackTrace(e));
+ " caused by " + ExceptionUtils.getStackTrace(e));
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,11 @@
*/
package org.apache.seata.common.loader;

import org.apache.commons.lang.exception.NestableRuntimeException;

/**
* The type Enhanced service not found exception.
*
*/
public class EnhancedServiceNotFoundException extends NestableRuntimeException {
public class EnhancedServiceNotFoundException extends RuntimeException {
private static final long serialVersionUID = 7748438218914409019L;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.config;

import org.apache.commons.lang.ObjectUtils;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.seata.common.thread.NamedThreadFactory;
import org.apache.seata.common.util.CollectionUtils;
import org.apache.seata.common.util.StringUtils;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.core.protocol;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.ConfigurationKeys;
import org.apache.seata.common.util.NetUtil;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.core.protocol;

import io.netty.channel.Channel;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.util.NetUtil;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.core.rpc;

import io.netty.channel.ChannelHandlerContext;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.thread.NamedThreadFactory;
import org.apache.seata.common.util.NetUtil;
import org.apache.seata.core.protocol.AbstractMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import io.netty.channel.socket.nio.NioSocketChannel;
import io.netty.util.NettyRuntime;
import io.netty.util.internal.PlatformDependent;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.config.Configuration;
import org.apache.seata.config.ConfigurationFactory;
import org.apache.seata.core.constants.ConfigurationKeys;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.core.rpc.netty;

import io.netty.channel.Channel;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.DefaultValues;
import org.apache.seata.common.exception.FrameworkException;
import org.apache.seata.common.loader.EnhancedServiceLoader;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
import io.netty.handler.codec.http2.Http2HeadersFrame;
import io.netty.util.ReferenceCountUtil;
import io.netty.util.ReferenceCounted;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.core.compressor.Compressor;
import org.apache.seata.core.compressor.CompressorFactory;
import org.apache.seata.core.protocol.HeartbeatMessage;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.core.rpc.processor.server;

import io.netty.channel.ChannelHandlerContext;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.EnhancedServiceLoader;
import org.apache.seata.common.util.NetUtil;
import org.apache.seata.core.protocol.RegisterRMRequest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.core.rpc.processor.server;

import io.netty.channel.ChannelHandlerContext;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.EnhancedServiceLoader;
import org.apache.seata.common.util.NetUtil;
import org.apache.seata.core.protocol.RegisterTMRequest;
Expand Down
7 changes: 1 addition & 6 deletions dependencies/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<protostuff.version>1.5.9</protostuff.version>
<config.version>1.2.1</config.version>
<commons-logging.version>1.2</commons-logging.version>
<commons-lang.version>2.6</commons-lang.version>
<commons-lang3.version>3.18.0</commons-lang3.version>
<commons-io.version>2.8.0</commons-io.version>
<aopalliance.version>1.0</aopalliance.version>
<zkclient.version>0.11</zkclient.version>
Expand Down Expand Up @@ -323,11 +323,6 @@
<artifactId>commons-logging</artifactId>
<version>${commons-logging.version}</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not change it to commons‑lang3?

Copy link
Contributor Author

@yougecn yougecn Sep 28, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spring-boot-dependencies里面已经对commons-lang3做了版本管理,但它里面是<commons-lang3.version>3.12.0</commons-lang3.version>,只需要在 dependencies/pom.xml中指定<commons-lang3.version>3.18.0</commons-lang3.version>即可

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The client side does not strongly depend on Spring. This dependency should be added.

<artifactId>commons-lang</artifactId>
<version>${commons-lang.version}</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import com.alipay.sofa.registry.client.provider.DefaultRegistryClient;
import com.alipay.sofa.registry.client.provider.DefaultRegistryClientConfigBuilder;
import com.alipay.sofa.registry.core.model.ScopeEnum;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.util.NetUtil;
import org.apache.seata.config.Configuration;
import org.apache.seata.config.ConfigurationFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.integration.tx.api.fence.config;

import org.apache.commons.lang.time.DateUtils;
import org.apache.commons.lang3.time.DateUtils;
import org.apache.seata.common.DefaultValues;
import org.apache.seata.common.thread.NamedThreadFactory;
import org.apache.seata.core.rpc.Disposable;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ public boolean deleteCommonFenceDO(Connection conn, String xid, Long branchId) {
public int deleteTCCFenceDO(Connection conn, List<String> xids) {
PreparedStatement ps = null;
try {
String paramsPlaceHolder = org.apache.commons.lang.StringUtils.repeat("?", ",", xids.size());
String paramsPlaceHolder = org.apache.commons.lang3.StringUtils.repeat("?", ",", xids.size());
String sql = CommonFenceStoreSqls.getDeleteSQLByXids(logTableName, paramsPlaceHolder);
ps = conn.prepareStatement(sql);
for (int i = 0; i < xids.size(); i++) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.integration.http;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.http.HttpResponse;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.CloseableHttpClient;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.rm.datasource;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.ConfigurationKeys;
import org.apache.seata.common.Constants;
import org.apache.seata.common.loader.EnhancedServiceNotFoundException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ public List<Object> getPkValuesByDefault() throws SQLException {
ColumnMeta pkMeta = pkMetaMap.values().iterator().next();
String columnDef = pkMeta.getColumnDef();
// sample: nextval('test_id_seq'::regclass)
String seq = org.apache.commons.lang.StringUtils.substringBetween(columnDef, "'", "'");
String function = org.apache.commons.lang.StringUtils.substringBetween(columnDef, "", "(");
String seq = org.apache.commons.lang3.StringUtils.substringBetween(columnDef, "'", "'");
String function = org.apache.commons.lang3.StringUtils.substringBetween(columnDef, "", "(");
if (StringUtils.isBlank(seq)) {
throw new ShouldNeverHappenException("get primary key value failed, cause columnDef is " + columnDef);
}
Expand All @@ -174,8 +174,8 @@ public List<Object> getPkValuesByDefault(String pkKey) throws SQLException {
ColumnMeta pkMeta = pkMetaMap.values().iterator().next();
String columnDef = pkMeta.getColumnDef();
// sample: nextval('test_id_seq'::regclass)
String seq = org.apache.commons.lang.StringUtils.substringBetween(columnDef, "'", "'");
String function = org.apache.commons.lang.StringUtils.substringBetween(columnDef, "", "(");
String seq = org.apache.commons.lang3.StringUtils.substringBetween(columnDef, "'", "'");
String function = org.apache.commons.lang3.StringUtils.substringBetween(columnDef, "", "(");
if (StringUtils.isBlank(seq)) {
throw new ShouldNeverHappenException("get primary key value failed, cause columnDef is " + columnDef);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.rm.datasource.undo.mysql;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.LoadLevel;
import org.apache.seata.common.util.CollectionUtils;
import org.apache.seata.common.util.IOUtil;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.spring.boot.autoconfigure.provider;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.exception.ShouldNeverHappenException;
import org.apache.seata.common.holder.ObjectHolder;
import org.apache.seata.common.util.CollectionUtils;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
package org.apache.seata.server.coordinator;

import io.netty.channel.Channel;
import org.apache.commons.lang.time.DateFormatUtils;
import org.apache.commons.lang3.time.DateFormatUtils;
import org.apache.seata.common.DefaultValues;
import org.apache.seata.common.store.SessionMode;
import org.apache.seata.common.thread.NamedThreadFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ public List<GlobalTransactionDO> queryGlobalTransactionDO(int[] statuses, int li
conn = logStoreDataSource.getConnection();
conn.setAutoCommit(true);

String paramsPlaceHolder = org.apache.commons.lang.StringUtils.repeat("?", ",", statuses.length);
String paramsPlaceHolder = org.apache.commons.lang3.StringUtils.repeat("?", ",", statuses.length);

String sql = LogStoreSqlsFactory.getLogStoreSqls(dbType)
.getQueryGlobalTransactionSQLByStatus(globalTable, paramsPlaceHolder);
Expand Down Expand Up @@ -312,7 +312,7 @@ public List<BranchTransactionDO> queryBranchTransactionDO(String xid) {
public List<BranchTransactionDO> queryBranchTransactionDO(List<String> xids) {
int length = xids.size();
List<BranchTransactionDO> rets = new ArrayList<>(length * 3);
String paramsPlaceHolder = org.apache.commons.lang.StringUtils.repeat("?", ",", length);
String paramsPlaceHolder = org.apache.commons.lang3.StringUtils.repeat("?", ",", length);
String sql =
LogStoreSqlsFactory.getLogStoreSqls(dbType).getQueryBranchTransaction(branchTable, paramsPlaceHolder);
Connection conn = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.server.session;

import org.apache.commons.lang.time.DateUtils;
import org.apache.commons.lang3.time.DateUtils;
import org.apache.seata.common.XID;
import org.apache.seata.common.loader.EnhancedServiceLoader;
import org.apache.seata.common.result.PageResult;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.google.common.collect.ImmutableSet;
import org.aopalliance.aop.Advice;
import org.aopalliance.intercept.MethodInterceptor;
import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.seata.common.util.CollectionUtils;
import org.apache.seata.common.util.StringUtils;
import org.apache.seata.config.CachedConfigurationChangeListener;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
*/
package org.apache.seata.spring.annotation.scannercheckers;

import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.LoadLevel;
import org.apache.seata.spring.annotation.ScannerChecker;
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
*/
package org.apache.seata.spring.annotation.scannercheckers;

import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.seata.common.loader.LoadLevel;
import org.apache.seata.spring.annotation.GlobalLock;
import org.apache.seata.spring.annotation.GlobalTransactionScanner;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*/
package org.apache.seata.sqlparser.struct;

import org.apache.commons.lang.ArrayUtils;
import org.apache.commons.lang3.ArrayUtils;

import java.util.ArrayList;
import java.util.List;
Expand Down
Loading