결제 전환 목표 아키텍처 정의 #2
1 changed files with 29 additions and 0 deletions
29
docs/architecture/transaction-sequence.md
Normal file
29
docs/architecture/transaction-sequence.md
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
sequenceDiagram
|
||||
participant C as Controller
|
||||
participant S as Service
|
||||
participant R as Repository
|
||||
participant DB as Database
|
||||
participant E as External Payment Gateway
|
||||
|
||||
C->>S: 결제 요청
|
||||
S->>R: 결제 정보 요청
|
||||
R->>DB: 결제 정보 저장
|
||||
DB-->>R: 저장 성공
|
||||
S->>E: 결제 진행
|
||||
E-->>S: 결제 성공
|
||||
S->>C: 결제 성공 응답
|
||||
|
||||
note over C: 외부 실패와 같은 경우
|
||||
S->>E: 결제 진행
|
||||
E-->>S: 결제 실패
|
||||
S->>R: 데이터 롤백
|
||||
R->>DB: 롤백 처리
|
||||
DB-->>R: 롤백 성공
|
||||
S->>C: 결제 실패 응답
|
||||
|
||||
note over C: DB 실패의 경우
|
||||
S->>R: 결제 정보 요청
|
||||
R->>DB: 결제 정보 저장
|
||||
DB-->>R: 저장 실패
|
||||
R-->>S: 에러 응답
|
||||
S->>C: 결제 실패 응답
|
||||
Loading…
Add table
Add a link
Reference in a new issue