Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/add interceptors and filter #17

Merged
merged 9 commits into from
Jun 29, 2024
Merged

Conversation

chanwoonglee
Copy link
Collaborator

PR Type

  • Bugfix
  • Feature
  • Docs
  • Refactoring (no functional changes, no api changes)

For what purpose

  • API 로깅
  • response 형태 통일
  • exception에 대한 Base타입과 global처리 추가

Key changes

  1. logging interceptor 추가
  2. exception filter 추가
  3. response interceptor 추가

To reviewers

Screenshots

}

private async handle(request: Request, error: Error) {
//TODO: DISCORD_WEBHOOK_URL 추가 예정
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

내가 추후에 붙이겠소

[additional: string]: any;
};

export enum ExceptionType {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

enum 말고 object로 해볼까요 우리?

import { createException } from './exception.factory';
import { ExceptionType } from './exception.type';

const ExceptionOf = {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

중복 코드가 많다면 reduce로 처리해볼까요? 우리 ?

@saehun saehun force-pushed the feat/add-interceptors-and-filter branch from 12571f1 to 9a3a80e Compare June 29, 2024 06:40
@saehun saehun merged commit 0d693e4 into stage Jun 29, 2024
3 checks passed
@saehun saehun deleted the feat/add-interceptors-and-filter branch June 29, 2024 06:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants