Numble Challenge - Banking API
run.sh
를 실행하면 됩니다.간혹 pinpoint-hbase 이 정상 실행하기 전에 pinpoint-collector 가 실행되어 apm 이 정상적으로 실행되지 않는 경우가 존재합니다. 이런 경우 collector를 재실행 해주세요.
test.sh
를 실행하면 됩니다.erDiagram
User {
long id PK
string email
string anme
string password
}
Account{
long id PK
long userId
string number
long balance
}
AccountHistory {
long id PK
long fromAccountNumber
long toAccountNumber
string type
long amount
long money
}
Friend{
Long id PK
Long fromUserId
Long toUserId
}
FriendRequestHistory {
Long id PK
Long fromUserId
Long toUserId
Boolean approval
}
User ||--|| Friend : has
Friend ||--|| FriendRequestHistory : contain
User }|--|{ Account : own
Account ||--o{ AccountHistory : write
sequenceDiagram
autonumber
actor User
User ->> Controller : transfer money
Controller ->> ApplicationService : transfer money
ApplicationService ->>+ ConcurrencyManager : getLock
Note right of ConcurrencyManager: Using Named Lock
ApplicationService ->> Service : transfer money
Service ->> Repository : transfer money
opt Lock Connectioned Timeout
ConcurrencyManager->>User: 503 Service Unavailable
end
ConcurrencyManager ->>- ApplicationService : releaseLock
opt Success Complete
ApplicationService -->> NumbleAlarmService : sendAlram
Controller ->> User : 200 OK
end