Skip to content

mohammadne/middleman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MIDDLE MAN

MIDDLE MAN will simulate a real world proxy server that clients will request to the proxy server (reverse proxy) and as its role is load-balancing between servers and caching some requests based on logic in proxy server

How to run

  • run servers in first terminal

    go run cmd/root.go servers
  • run proxy in second terminal

    go run cmd/root.go proxy
  • run clients in third terminal

    go run cmd/root.go clients
  • post a test cURL body

    curl --header "Content-Type: application/json" \
    --request POST --data '{"key":"key","value":"value"}' \
    http://localhost:8090/objects
  • get specific hashId's body with cURL

    curl --header "Content-Type: application/json" \
    --request GET http://localhost:8090/objects/hashId

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages