Skip to content

Commit

Permalink
Merge pull request #947 from TencentBlueKing/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
nannan00 authored Apr 13, 2022
2 parents d70fe87 + 8bbc903 commit dc472f1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions saas/backend/metrics/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class ComponentEnum(LowerStrEnum):
USERMGR = auto()
ESB = auto()
CMSI = auto()
LOGIN = auto()


def get_component_by_url(url: str) -> str:
Expand All @@ -38,6 +39,8 @@ def get_component_by_url(url: str) -> str:
return ComponentEnum.ESB.value
elif "/api/c/compapi/cmsi/" in path:
return ComponentEnum.CMSI.value
elif "/api/c/compapi/v2/bk_login/" in path or "/is_login/" in path or "/user/get_info" in path:
return ComponentEnum.LOGIN.value
return "unknown"


Expand Down

0 comments on commit dc472f1

Please sign in to comment.