# Order failed Pickup And Undelivered
```plantuml
participant "tracking (3pl-aggregator)" as tr
participant "StoreReasonLogic" as srl
participant "redis" as redis
participant "database" as db
tr -> srl: run store reason logic\nwhenever there's tracking
srl -> redis: get order failure reason from redis
redis -> srl
alt there's no cache
srl -> db: get order failure reason from database
db -> srl
end
srl -> srl: checks wether there's a order failure reason\nthat needs to be stored or not
srl -> db: insert new order failure data \nand delete older failure reason if the amount reached the limit
```
# Generate Excel
```plantuml
participant "logistic-client/everpro-order" as sv
participant "3pl-aggregator" as 3pl
participant "evepro-utility" as eu
sv -> 3pl: Fetch data order\nfailure reason by awb numbers
3pl -> sv
sv -> sv: Build returned data from 3pl-aggregator\nfor generate excel
sv -> eu: Generate excel
eu -> sv
```
# Get Order Failure Reasons
```plantuml
participant "service/requester" as sv
participant "3pl-aggregator" as 3pl
participant "database" as db
sv -> 3pl: request data
3pl -> db: Fetch data from databases
db -> 3pl:
3pl -> 3pl: Build returned data based on failure reason
3pl -> sv: Return response
```
```mermaid
flowchart LR
tracking[Tracking]
db[(Datanase)]
```