Skip to content

Commit

Permalink
Merge pull request #3 from markGbug/main
Browse files Browse the repository at this point in the history
add comment in ProjectTraceFilter
  • Loading branch information
ethanhanjiahao authored Aug 3, 2022
2 parents d24af45 + a9b4097 commit 40b0cdb
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,13 @@ public void doFilter(ServletRequest request, ServletResponse response, FilterCha
HttpServletResponse res = (HttpServletResponse) response;
String projectIdHeader = req.getHeader(ProjectTraceHolder.PROJECT_TRACE_ID);
String tenantIdHeader = req.getHeader(ProjectTraceHolder.TENANT_TRACE_ID);

//add default project
if (StringUtils.isBlank(projectIdHeader)) {
projectIdHeader = "1";
}
if (StringUtils.isBlank(tenantIdHeader)) {
tenantIdHeader = "1";
}
String uri = req.getRequestURI();
//非api开头的接口不进行判断
if (Const.NO_USERPERMISSION.contains(uri) || StringUtils.isNotBlank(ActionIgnoreProject.getActionIgnoreProject(request.getParameter("Action")))) {
Expand Down

0 comments on commit 40b0cdb

Please sign in to comment.