[Feat] Embedding Job Attempt 시작 기록 - #64
Merged
Merged
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (16)
📝 WalkthroughWalkthrough유효한 Claim Token을 사용해 Embedding Job Attempt를 시작하는 관리자 API, 소유권·Lease 검증, 멱등 재생, Attempt 번호 증가, DB 잠금·유일성 제약 및 관련 테스트를 추가했습니다. ChangesEmbedding Job Attempt 시작
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant Worker
participant AdminAPI
participant AttemptService
participant JobDB
participant AttemptDB
Worker->>AdminAPI: Attempt 시작 요청
AdminAPI->>AttemptService: jobId, workerId, claimToken 전달
AttemptService->>JobDB: PROCESSING Job 쓰기 잠금
AttemptService->>AttemptDB: 동일 Job·Claim Attempt 조회
AttemptDB-->>AttemptService: 기존 Attempt 또는 없음
AttemptService->>AttemptDB: 신규 STARTED Attempt 저장
AttemptService-->>AdminAPI: 생성 또는 재생 결과
AdminAPI-->>Worker: 201 또는 200 응답
Possibly related PRs
Suggested labels: ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Gimini-3
marked this pull request as ready for review
July 26, 2026 13:10
This was referenced Jul 29, 2026
Merged
This was referenced Aug 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔍️ 작업 내용
✨ 상세 설명
POST /admin/indexing-jobs/{jobId}/attempts관리자 API를 추가했습니다.201 Created, 같은 현재 Claim 재전송은 기존 Attempt와200 OK를 반환합니다.(embedding_job_id, claim_token)유일성 제약을 V34 Migration으로 추가했습니다.EMBEDDING-JOB-001~005오류 계약을 추가했습니다.검증:
./gradlew test --tests 'com.opensource.docgrid.domain.worker.entity.EmbeddingJobAttemptTest' --tests 'com.opensource.docgrid.domain.embedding.converter.EmbeddingJobAttemptConverterTest' --tests 'com.opensource.docgrid.domain.embedding.service.command.EmbeddingJobAttemptServiceTest' --tests 'com.opensource.docgrid.domain.embedding.controller.IndexingJobAdminControllerTest' --tests 'com.opensource.docgrid.domain.embedding.service.command.EmbeddingJobClaimServiceTest' --tests 'com.opensource.docgrid.domain.embedding.entity.EmbeddingJobTest'./gradlew test --tests '*EmbeddingJobAttemptIntegrationTest'./gradlew clean build./gradlew claimConcurrencyTest🛠️ 추후 리팩토링 및 고도화 계획
📸 스크린샷 (선택)
💬 리뷰 요구사항
201과 재전송200의 응답 Body가 동일하고 Token이 제외되는 API 계약을 확인해 주세요.Summary by CodeRabbit
새로운 기능
오류 처리
데이터베이스
문서 및 테스트