mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2026-04-26 10:19:36 +08:00
update seata 1.6.0 => 1.6.1
This commit is contained in:
@@ -38,7 +38,7 @@ import javax.sql.DataSource;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static io.seata.core.constants.RedisKeyConstants.DEFAULT_LOG_QUERY_LIMIT;
|
||||
import static io.seata.common.DefaultValues.DEFAULT_QUERY_LIMIT;
|
||||
|
||||
/**
|
||||
* The type Database transaction store manager.
|
||||
@@ -83,7 +83,7 @@ public class DataBaseTransactionStoreManager extends AbstractTransactionStoreMan
|
||||
* Instantiates a new Database transaction store manager.
|
||||
*/
|
||||
private DataBaseTransactionStoreManager() {
|
||||
logQueryLimit = CONFIG.getInt(ConfigurationKeys.STORE_DB_LOG_QUERY_LIMIT, DEFAULT_LOG_QUERY_LIMIT);
|
||||
logQueryLimit = CONFIG.getInt(ConfigurationKeys.STORE_DB_LOG_QUERY_LIMIT, DEFAULT_QUERY_LIMIT);
|
||||
String datasourceType = CONFIG.getConfig(ConfigurationKeys.STORE_DB_DATASOURCE_TYPE);
|
||||
//init dataSource
|
||||
DataSource logStoreDataSource = EnhancedServiceLoader.load(DataSourceProvider.class, datasourceType).provide();
|
||||
|
||||
@@ -29,6 +29,8 @@ import java.util.Arrays;
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import static io.seata.common.DefaultValues.*;
|
||||
|
||||
/**
|
||||
* @author funkye
|
||||
*/
|
||||
@@ -43,13 +45,6 @@ public class JedisPooledFactory {
|
||||
private static final String HOST = "127.0.0.1";
|
||||
|
||||
private static final int PORT = 6379;
|
||||
|
||||
private static final int MINCONN = 1;
|
||||
|
||||
private static final int MAXCONN = 10;
|
||||
|
||||
private static final int MAXTOTAL = 100;
|
||||
|
||||
private static final int DATABASE = 0;
|
||||
|
||||
private static final int SENTINEL_HOST_NUMBER = 3;
|
||||
@@ -83,9 +78,11 @@ public class JedisPooledFactory {
|
||||
}
|
||||
}
|
||||
JedisPoolConfig poolConfig = new JedisPoolConfig();
|
||||
poolConfig.setMinIdle(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MIN_CONN, MINCONN));
|
||||
poolConfig.setMaxIdle(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MAX_CONN, MAXCONN));
|
||||
poolConfig.setMaxTotal(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MAX_TOTAL, MAXTOTAL));
|
||||
poolConfig.setMinIdle(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MIN_CONN,
|
||||
DEFAULT_REDIS_MIN_IDLE));
|
||||
poolConfig.setMaxIdle(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MAX_CONN,
|
||||
DEFAULT_REDIS_MAX_IDLE));
|
||||
poolConfig.setMaxTotal(CONFIGURATION.getInt(ConfigurationKeys.STORE_REDIS_MAX_TOTAL, DEFAULT_REDIS_MAX_TOTAL));
|
||||
String mode = CONFIGURATION.getConfig(ConfigurationKeys.STORE_REDIS_MODE,ConfigurationKeys.REDIS_SINGLE_MODE);
|
||||
if (mode.equals(ConfigurationKeys.REDIS_SENTINEL_MODE)) {
|
||||
String masterName = CONFIGURATION.getConfig(ConfigurationKeys.STORE_REDIS_SENTINEL_MASTERNAME);
|
||||
|
||||
@@ -47,6 +47,7 @@ import java.util.function.Function;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static io.seata.common.ConfigurationKeys.STORE_REDIS_QUERY_LIMIT;
|
||||
import static io.seata.common.DefaultValues.DEFAULT_QUERY_LIMIT;
|
||||
import static io.seata.core.constants.RedisKeyConstants.*;
|
||||
|
||||
/**
|
||||
@@ -110,7 +111,7 @@ public class RedisTransactionStoreManager extends AbstractTransactionStoreManage
|
||||
super();
|
||||
initGlobalMap();
|
||||
initBranchMap();
|
||||
logQueryLimit = CONFIG.getInt(STORE_REDIS_QUERY_LIMIT, DEFAULT_LOG_QUERY_LIMIT);
|
||||
logQueryLimit = CONFIG.getInt(STORE_REDIS_QUERY_LIMIT, DEFAULT_QUERY_LIMIT);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user