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

M3-117 개인전 픽셀 가져오는 API 구현 완료 #4

Merged
merged 5 commits into from
Jun 25, 2024

Conversation

qjvk2880
Copy link
Contributor

작업 내용*

  • jpql을 사용해 주변 픽셀들의 개인전 정보를 가져온다.

고민한 내용*

  • 성능이 너무 떨어져 x, y 필드에 대해 인덱스를 적용하여 해결하였다.

리뷰 요구사항

  • 컨트롤러랑 레포지토리에 네이밍 괜찮은지 봐주세요!!

@RestController
@RequiredArgsConstructor
@RequestMapping("/api/pixels")
Copy link
Member

Choose a reason for hiding this comment

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

개인 픽셀이랑 경쟁 픽셀이랑 구분하기 위해 엔드포인트에 구분자가 필요할 것 같네요..

Copy link
Contributor Author

Choose a reason for hiding this comment

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

적용 완료했습니다!

private final PixelRepository pixelRepository;

public List<IndividualPixelResponse> getNearIndividualPixels(int currentX, int currentY, int xRange, int yRange) {
Copy link
Member

Choose a reason for hiding this comment

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

개인 픽셀과 경쟁 픽셀을 조회 하는 구분이 필요할 것 같아요

Copy link
Contributor Author

Choose a reason for hiding this comment

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

생각하지 못했던 구분이였네요.. 추후 동적 쿼리나 컨트롤러 단에 구분자 추가 등으로 적용하겠습니다.

@koomin1227 koomin1227 self-assigned this Jun 22, 2024
Copy link
Contributor

@tkdals802 tkdals802 left a comment

Choose a reason for hiding this comment

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

스프링으로 쿼리를 잘 짜신것 같습니다

@qjvk2880 qjvk2880 changed the title M3-117 Feat : 개인전 픽셀 가져오는 API 구현 완료 M3-117 개인전 픽셀 가져오는 API 구현 완료 Jun 25, 2024
@qjvk2880 qjvk2880 merged commit e6b52f5 into develop Jun 25, 2024
1 check passed
@koomin1227 koomin1227 deleted the feature/M3-117-getIndividualModePixels branch June 26, 2024 01:23
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