Conversation
배포 이력 화면에 FAILED 만 뜨고 사유가 없었다. 응답에 아무것도 없어서 FE 가 보여줄 수단이 없었다. errorMessage 만 주면 화면이 그 문자열을 파싱해 분기하게 된다. 서버가 문구를 조금만 바꿔도 조용히 깨지는 구조다. 그래서 분류를 값으로 함께 준다. errorCode: WORKFLOW_FAILED | RESULT_UNKNOWN | RETRY_EXHAUSTED | null errorMessage: 사람이 읽을 상세 | null RESULT_UNKNOWN 이 특히 중요하다. 이건 "실패했다"가 아니라 "결과를 확인하지 못했다" 이다. 웹훅을 놓친 이력을 회수하려던 워커가 GitHub 에서 실행을 찾지 못하고 포기한 경우이고, 사이트는 실제로 떠 있을 수 있다. 운영에 그렇게 닫힌 이력이 한 건 있는데 지금 화면에는 그냥 실패로 보인다. 화면이 두 경우를 다르게 말하려면 분류가 값으로 있어야 한다. 옛 이력은 errorCode 가 null 로 남는다. 분류를 붙이기 전에 실패한 것들이라 되살릴 근거가 없다 — FE 는 errorCode 없이 errorMessage 만 있는 경우를 처리하기로 했다. - DeployFailureCode 추가, DeploymentHistory 가 errorMessage 와 함께 보관 - complete() 가 분류도 지운다. 재시도로 되살아난 이력이 옛 분류를 달고 있으면 화면이 성공한 배포를 실패로 그린다 - V32 마이그레이션으로 failure_code 컬럼 추가(NULL 허용) - 실패를 만드는 지점 셋에서 분류를 정한다: 웹훅(WORKFLOW_FAILED), 회수 워커 (판정을 얻으면 WORKFLOW_FAILED, 못 얻으면 RESULT_UNKNOWN), 재시도 소진 (RETRY_EXHAUSTED) - 목록·상세 두 엔드포인트에 동일하게 노출 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
feat(deploy): 배포 실패 사유를 분류와 상세로 나눠 응답에 싣는다
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.
develop → main. #168 하나이고 마이그레이션 V32 가 포함된다.
무엇이 달라지나
배포 이력 화면에
FAILED만 뜨고 사유가 없었다. 응답에 아무것도 없어 FE 가 보여줄 수단이 없었다. 이제 두 필드를 준다.분류를 값으로 주는 이유는 화면이 문자열을 파싱해 분기하지 않게 하기 위해서다. 서버가 문구를 조금만 바꿔도 조용히 깨지는 구조를 만들지 않는다.
RESULT_UNKNOWN이 핵심이다. "실패했다"가 아니라 "결과를 확인하지 못했다"이다. 웹훅을 놓친 이력을 회수하려던 워커(#161)가 GitHub 에서 실행을 못 찾고 포기한 경우이고, 사이트는 실제로 떠 있을 수 있다. 운영에 그렇게 닫힌 이력이 한 건 있다(projectId=11, historyId=1) — 지금은 화면에서 그냥 실패로 보인다.마이그레이션
컬럼 추가이고 NULL 허용이라 기존 행에 영향이 없다. 옛 이력은
errorCode가null로 남고, FE 는 그 경우errorMessage만 표시하기로 합의했다.검증
RETRY_EXHAUSTED/ 성공하면 옛 분류가 지워지는지(재시도로 되살아난 이력이 실패로 그려지지 않도록) / 회수 워커가 판정 유무로WORKFLOW_FAILED와RESULT_UNKNOWN을 가르는지./gradlew test전체 통과 — 통합 테스트가 V32 를 실제로 적용한다add427f), dev 기동 확인(마이그레이션 적용 후/auth/github/url200)관련: #161, #164
🤖 Generated with Claude Code