Upgrade Sentinel version to 1.8.0

pull/1666/head
yuhuangbin 5 years ago
parent 3b62ef00b3
commit 8632034126

@ -19,7 +19,7 @@
<properties>
<revision>2.2.1.RELEASE</revision>
<sentinel.version>1.7.2</sentinel.version>
<sentinel.version>1.8.0</sentinel.version>
<oss.version>3.1.0</oss.version>
<seata.version>1.3.0</seata.version>
<nacos.client.version>1.3.2</nacos.client.version>

@ -91,7 +91,7 @@ public class SentinelSCGAutoConfiguration {
}
private void initAppType() {
System.setProperty(SentinelConfig.APP_TYPE, ConfigConstants.APP_TYPE_SCG_GATEWAY);
System.setProperty(SentinelConfig.APP_TYPE_PROP_KEY, ConfigConstants.APP_TYPE_SCG_GATEWAY);
}
private void initFallback() {

@ -65,7 +65,7 @@ public class SentinelZuulAutoConfiguration {
private void init() {
requestOriginParserOptional
.ifPresent(ZuulGatewayCallbackManager::setOriginParser);
System.setProperty(SentinelConfig.APP_TYPE,
System.setProperty(SentinelConfig.APP_TYPE_PROP_KEY,
String.valueOf(ConfigConstants.APP_TYPE_ZUUL_GATEWAY));
}

@ -31,7 +31,6 @@ import com.alibaba.csp.sentinel.slots.block.flow.FlowRule;
import com.alibaba.csp.sentinel.slots.block.flow.param.ParamFlowRule;
import com.alibaba.csp.sentinel.slots.system.SystemRule;
import com.alibaba.csp.sentinel.transport.config.TransportConfig;
import com.alibaba.csp.sentinel.util.AppNameUtil;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.dataformat.xml.XmlMapper;
@ -79,9 +78,9 @@ public class SentinelAutoConfiguration {
System.setProperty(LogBase.LOG_NAME_USE_PID,
String.valueOf(properties.getLog().isSwitchPid()));
}
if (StringUtils.isEmpty(System.getProperty(AppNameUtil.APP_NAME))
if (StringUtils.isEmpty(System.getProperty(SentinelConfig.getAppName()))
&& StringUtils.hasText(projectName)) {
System.setProperty(AppNameUtil.APP_NAME, projectName);
System.setProperty(SentinelConfig.getAppName(), projectName);
}
if (StringUtils.isEmpty(System.getProperty(TransportConfig.SERVER_PORT))
&& StringUtils.hasText(properties.getTransport().getPort())) {

Loading…
Cancel
Save