forked from alibaba/Sentinel
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed Dashboard try to access Alipay domain
https://kcart.alipay.com…
…/web/bi.do?` By upgrading G2 Lib to version 3.4.10 alibaba#522
- Loading branch information
Showing
8 changed files
with
114 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
...d/src/main/java/com/alibaba/csp/sentinel/dashboard/controller/SentinelTestController.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package com.alibaba.csp.sentinel.dashboard.controller; | ||
|
||
import com.alibaba.csp.sentinel.dashboard.service.user.UserService; | ||
import org.slf4j.Logger; | ||
import org.slf4j.LoggerFactory; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.stereotype.Controller; | ||
import org.springframework.web.bind.annotation.RequestMapping; | ||
import org.springframework.web.bind.annotation.ResponseBody; | ||
|
||
import java.util.Map; | ||
|
||
@SuppressWarnings("CheckStyle") | ||
@Controller | ||
public class SentinelTestController { | ||
|
||
@Autowired | ||
UserService userService; | ||
private static final Logger logger = LoggerFactory.getLogger(SentinelTestController.class); | ||
|
||
@RequestMapping(value = "/cmpp-api/external/sentinelTest") | ||
@ResponseBody | ||
public String acceptOrderV3() throws | ||
InterruptedException { | ||
//0.0-1.0 | ||
int v = (int) (150 + (Math.random()) * (300 - 150)); | ||
Thread.sleep(v); | ||
return "finished"; | ||
} | ||
|
||
@RequestMapping(value = "/Test2") | ||
@ResponseBody | ||
public Map acceptOrderV32() throws | ||
InterruptedException { | ||
Map<String, String> allAuth = userService.findAllAuth(); | ||
return allAuth; | ||
} | ||
} | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,23 @@ | ||
mybatis: | ||
mapper-locations: classpath:mappers/*.xml #这里是mapper的配置文件 | ||
spring: | ||
datasource: | ||
url: jdbc:mysql://10.250.0.67:3306/ec?useSSL=false&useUnicode=true&characterEncoding=utf-8&allowMultiQueries=true&serverTimezone=Asia/Shanghai | ||
username: ec | ||
password: ec123$%^ | ||
#Pool Configuration | ||
hikari: | ||
poolName: CMPP_Develop_Pool | ||
connectionTimeout: 60000 | ||
minimumIdle: 1 | ||
maximumPoolSize: 25 | ||
idleTimeout: 6000 | ||
data-source-properties: | ||
cachePrepStmts: true | ||
prepStmtCacheSize: 25 | ||
prepStmtCacheSqlLimit: 2048 | ||
useServerPrepStmts: true | ||
useLocalSessionState: true | ||
rewriteBatchedStatements: true | ||
cacheResultSetMetadata: true | ||
cacheServerConfiguration: true | ||
elideSetAutoCommits: true | ||
maintainTimeStats: false |