-
Notifications
You must be signed in to change notification settings - Fork 0
feat(notification): 알림 일괄 삭제 API #158
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
Conversation
ssosee
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
짱 고생하셨습니다!
| return ResponseEntity.ok(BasicResponse.success()); | ||
| } | ||
|
|
||
| // TODO: 개발용 API -> 추후 제거 필요 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Profile만 설정해주면 좋을 것 같아요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
앗 @Profile이 빈 단위로 적용할 수 있는 설정으로 알고 있어서 따로 붙이진 않았는데, 아니면 아예 컨트롤러를 분리할까요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오잉 method 단위도 되지 않나요?
@Target({ElementType.TYPE, ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Conditional(ProfileCondition.class)
public @interface Profile {
/**
* The set of profiles for which the annotated component should be registered.
*/
String[] value();
}- ElementType.TYPE → 클래스, 인터페이스, enum, 애노테이션 등 타입 선언에 사용 가능
- ElementType.METHOD → 메서드에 사용 가능
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
요게 제가 알기론 @Bean 이 붙은 메서드에만 적용이 가능한 것으로 알아요!! (링크)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
직접 테스트 해보았을때 dev 로 해놓고 local 로 실행해두 호출이 되네유 ㅜ^ㅜ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오 맞네요! Bean 메소드만 해당되는 군요!
그러면 기존에 있는 TestController 를 활용하면 좋을 것 같아요!
|
|
||
| @Operation(summary = "알림 제거", description = "회원에게 생성된 모든 알림을 제거") | ||
| @DeleteMapping("/notifications") | ||
| @Profile("dev") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Profile("dev") 이거 제거하면 될거 같아요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
옴메 꼼꼼한 확인 감사합니다!
📝 작업 내용
🔗 참고할만한 자료(선택)
💬 리뷰 요구사항(선택)