/
Infrastructure Template

Infrastructure Template

This is a template of the Amazon EDI’s infrastructure diagram and corresponding breakdown.

You are required to create a similar article for your module/component

Project name: Amazon EDI

External Services

  • Unicommerce

  • AS2 Gateway

  • ATS(Amazon Transportation Service)

Internal Services(App Engine)

  • Unicommerce-Inventory Service

  • Inventory Update Service

  • WMS-API

  • Middlware

  • Notifications

  • Unicommerce-ofr service

GCP Tools used:

  • Pub/Sub

  • Google Cloud SQL(Primary DB)

  • Memcache

  • Compute Engine(Nginx)

  • Cloud Storage

Infrastructure Diagram

Here is a Breakdown of the flow:

  1. Unicommerce sends Sampling and Inventory update of items to Unicommerce Inventory Service against the respective EDI site/Fulfillment Channel. This is an authentication based service.

  2. Unicommerce Inventory Service pushes the data to a Pub/Sub queue.

  3. The Pub/Sub queue submits the data to its subscription of Inventory Update Service

  4. Inventory Update Service updates the Sampling/Inventory data of the items in the Primary DB.Then it pushes the Sampling/Inventory update to Pub/Sub queue.

  5. Pub/Sub queue submits the data to Notifications Service which further transforms it to SAM/IAN messages and sends to AS2 Gateway.

  6. Amazon sends the messages like OF/OC/CRN/Invoice to AS2 Gateway.

  7. AS2 Gateway sends these messages to a Pub/Sub queue: incoming-notifications

  8. This Pub/Sub queue submits the data to its subscription of Middleware Service.

  9. Middleware service reads the incoming message file(XML) from the Cloud Storage bucket and transforms it to respective resource object(XML → JSON) and submits the data to WMS API Service, which is an authentication based service.

  10. WMS API Service performs the following actions:

    1. OF- Creates order/shipment into WMS ans pushes the same to Unicommerce

    2. Invoice- Updates the invoice against respective Shipment

    3. OC- Cancels the shipment upto “PICKED” status, else rejects the cancellation and submits the OCR event in both cases.

    4. CRN- Sends back IAN as per CRN inventory adjustment for the given shipment item.

  11. Unicommerce submits +OFR(FULFILLABLE) or -OFR(UNFULFILLABLE) against a shipment to Unicommerce OFR Service, which is an authentication based service.

  12. Unicommerce OFR Service submits the data to a Pub/Sub queue

  13. Pub/Sub queue submits the data to its subscription of WMS API service

  14. WMS API updates the shipment status as ACCEPTED(+OFR) or REJECTED(-OFR) in the Primary DB and submits the respective shipment event to a Pub/Sub queue.

  15. Pub/Sub queue submits this shipment event to its subscription of Notifications Service which further transforms it to OFR message and sends to AS2 Gateway.

  16. Unicommerce sends following requests to WMS API sequentially :

    1. Request to to fetch invoice for a shipment. It updates the shipment status as “PICKED” and submits the shipment event for it to a Pub/Sub queue.

    2. Request to fetch label of a shipment

  17. WMS API Service transforms the request data(for label) and submits the same to AMZ EDI LABEL Service, which fetches the label from ATS(Amazon Transportation Service), which is further returned to Unicommerce in response. WMS API Service updates the shipment status as “PACKED” and submits the shipment event for it to a Pub/Sub queue.

  18. All the outgoing notifications(SAM, IAN, OFR, ASN. OCR, ILN etc) are submitted to a common Pub/Sub queue: outgoing-notifications.

  19. Pub/Sub queue: outgoing-notifications further hits to its subscription of AS2 gateway.

  20. AS2 Gateway forwards the messages to Amazon.

 

Related content