Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yoho-apm
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
htoooth
2018-09-06 16:47:42 +0800
Commit
24f41efe134f6514a4c2c291a6f33b4192d4f319
1 parent
5dee5aff
fix
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
11 deletions
middleware/risk-service/index.js
middleware/risk-service/qps-path.js
middleware/serverapm.js
middleware/risk-service/index.js
View file @
24f41ef
...
...
@@ -20,16 +20,16 @@ const APP_NAME = {
module
.
exports
=
()
=>
{
const
handlers
=
compose
([
qpsPath
,
//
qpsPath,
disableBelow
,
xhrFilter
,
whitelistIpFilter
,
userFilter
,
whitelistPathFilter
,
userAgentFilter
,
ipFilter
,
qps
// whitelistIpFilter,
// userFilter,
// whitelistPathFilter,
// userAgentFilter,
// ipFilter,
// qps
]);
return
async
(
m
)
=>
{
...
...
middleware/risk-service/qps-path.js
View file @
24f41ef
...
...
@@ -32,9 +32,9 @@ module.exports = async({user}, next) => {
const
app
=
user
.
app
;
if
(
_
.
get
(
zk
,
`
$
{
app
}.
close
.
risk
`
,
false
))
{
return
next
();
}
// if (_.get(zk, `${app}.close.risk`, false)) {
// return next();
// }
const
ip
=
user
.
ip
;
const
path
=
user
.
path
;
...
...
middleware/serverapm.js
View file @
24f41ef
...
...
@@ -43,7 +43,7 @@ const server = {
}
}
logger
.
info
(
'[server] handle OK [%s]'
,
data
);
// logger.debug
('[server] handle OK [%s]', data);
},
{
concurrency
:
2
});
}
catch
(
e
)
{
logger
.
error
(
'[server] handle ERROR [%s]'
,
e
);
...
...
Please
register
or
login
to post a comment