Skip to content

[이용일] Sprint5#100

Open
lyi980403-arch wants to merge 22 commits intocodeit-bootcamp-spring:이용일from
lyi980403-arch:이용일-sprint5

Hidden character warning

The head ref may contain hidden characters: "\uc774\uc6a9\uc77c-sprint5"
Open

[이용일] Sprint5#100
lyi980403-arch wants to merge 22 commits intocodeit-bootcamp-spring:이용일from
lyi980403-arch:이용일-sprint5

Conversation

@lyi980403-arch
Copy link
Copy Markdown
Collaborator

@lyi980403-arch lyi980403-arch commented Feb 28, 2026

요구사항

기본

[O] 스프린트 미션#4에서 구현한 API를 RESTful API로 다시 설계해보세요.

[O] Postman을 활용해 컨트롤러를 테스트 하세요.

[O] springdoc-openapi를 활용하여 Swagger 기반의 API 문서를 생성하세요.
[O] Swagger-UI를 활용해 API를 테스트해보세요.

심화 요구사항
[X] 다음의 정적 리소스를 서빙하여 프론트엔드와 통합해보세요. API 스펙을 준수했다면 잘 동작할거예요.
[X] [Railway.app]을 활용하여 애플리케이션을 배포해보세요.
[X] [Railway.app]에 가입하고, 배포할 GitHub 레포지토리를 연결하세요.
[X] Settings > Network 섹션에서 Generate Domain 버튼을 통해 도메인을 생성하세요.
[X] 생성된 도메인에 접속해 배포된 애플리케이션을 테스트해보세요.

주요 변경사항

스크린샷

image

멘토에게

  • 심화까지 못해서 죄송합니다..

@hagyutae hagyutae changed the title 이용일 sprint5 [이용일] Sprint5 Mar 3, 2026
@hagyutae hagyutae changed the base branch from main to 이용일 March 4, 2026 03:56
@hagyutae
Copy link
Copy Markdown
Collaborator

hagyutae commented Mar 4, 2026

용일님, PR 베이스 브랜치가 항상 본인 이름 브랜치가 되도록 확인해주시고,
충돌 해결해주세요~!

Copy link
Copy Markdown
Collaborator

@hagyutae hagyutae left a comment

Choose a reason for hiding this comment

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

리뷰 코멘트 확인 후 수정해주세요~!


@RequiredArgsConstructor
@RestController
@RequestMapping("/messages")
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

MessageController@RequestMapping("/messages")로 매핑되어 있어, API 스펙의 /api/messages 경로와 불일치합니다. 다른 컨트롤러들은 /api/users, /api/channels/api prefix를 사용하고 있으므로 일관성을 위해 수정이 필요합니다.

private final BinaryContentService binaryContentService;

@RequestMapping(path = "find")
public ResponseEntity<BinaryContent> find(@RequestParam("binaryContentId") UUID binaryContentId) {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

BinaryContentController.java, ReadStatusController.java 두 컨트롤러에서 /find, /create, /update, /findAllByUserId 등 동사 기반 URI를 사용하고 있어 RESTful 설계 원칙에 맞지 않습니다. API 스펙에 맞게 리소스 중심 URI로 변경해야 합니다.


@Override
public Channel findById(UUID channelId) {
return null;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

왜 여태 service 미구현 사항이 있을까요?


private final AuthService authService;

@RequestMapping(path = "login")
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

AuthController.java, BinaryContentController.java, ReadStatusController.java 3개 컨트롤러에 @Tag, @Operation, @ApiResponses 등 Swagger 어노테이션이 전혀 적용되어 있지 않아 Swagger UI에서 API 설명이 표시되지 않습니다. UserController, ChannelController, MessageController에는 잘 적용되어 있으므로, 나머지 컨트롤러에도 동일하게 추가해야 합니다.


private final AuthService authService;

@RequestMapping(path = "login")
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

[전체 컨트롤러] @RequestMapping에 HTTP 메서드 미지정 및 @Controller + @ResponseBody 혼용

여러 엔드포인트에서 @RequestMapping을 HTTP 메서드 지정 없이 사용하여 모든 HTTP 메서드에 매핑되는 문제가 있습니다. 또한 일부 컨트롤러는 @Controller + @ResponseBody를, 다른 컨트롤러는 @RestController를 사용하여 일관성이 부족합니다. @GetMapping, @PostMapping, @PatchMapping, @DeleteMapping 축약 어노테이션과 @RestController 사용을 통일하는 것을 권장합니다.

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.

2 participants