Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
datax-cloud
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄营
datax-cloud
Commits
f7b5c412
Commit
f7b5c412
authored
Apr 01, 2020
by
yuwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2.0.0项目初始化
parent
e5d49512
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
ApiInterceptor.java
...a/cn/datax/service/data/market/config/ApiInterceptor.java
+2
-0
No files found.
datax-modules/data-market-service-parent/data-market-service/src/main/java/cn/datax/service/data/market/config/ApiInterceptor.java
View file @
f7b5c412
...
...
@@ -59,6 +59,7 @@ public class ApiInterceptor implements HandlerInterceptor {
return
false
;
}
String
deny
=
dataApiEntity
.
getDeny
();
deny
=
StrUtil
.
isBlank
(
deny
)
?
""
:
deny
;
List
<
String
>
denyList
=
Arrays
.
asList
(
deny
.
split
(
","
));
if
(
CollUtil
.
isNotEmpty
(
denyList
))
{
for
(
String
ip
:
denyList
)
{
...
...
@@ -71,6 +72,7 @@ public class ApiInterceptor implements HandlerInterceptor {
}
String
apiName
=
dataApiEntity
.
getApiName
();
Integer
rateLimit
=
dataApiEntity
.
getRateLimit
();
rateLimit
=
rateLimit
==
null
?
1
:
rateLimit
;
// 限流
if
(
rateLimit
==
1
)
{
Integer
times
=
dataApiEntity
.
getTimes
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment