Proxy ทำหน้าที่เป็นตัวกลางสำหรับคำขอ forward proxy ตั้งอยู่หน้า client (เป็นตัวแทนของพวกเขาต่อเซิร์ฟเวอร์) ขณะที่ reverse proxy ตั้งอยู่หน้าเซิร์ฟเวอร์ (เป็นตัวแทนของพวกเขาต่อ client) — จัดการ load balancing, caching, security และอื่น ๆ reverse proxy เป็นองค์ประกอบสำคัญในการออกแบบระบบ
forward proxy กับ reverse proxy
FORWARD PROXY → sits in front of CLIENTS, forwarding their requests to servers:
Client → FORWARD PROXY → Internet/Server
→ represents the CLIENT (hides client identity); for filtering, caching, anonymity,
access control (e.g. corporate proxies)
REVERSE PROXY → sits in front of SERVERS, receiving requests on their behalf:
Client → REVERSE PROXY → Backend servers
→ represents the SERVERS (clients don't see the backend); the common system-design component
