Giter Site home page Giter Site logo

distributed-proxy-cache's Introduction

Design

There are two layers, a frontend layer that receives outside http and https requests and uses consistent hashing to route to a set of backend servers and a backend layer which saves

./dpc_frontend.go --shmId my-app-name --hosts-file /tmp/dpc_hosts
[cachehit https://localhost:8000/foo]
[cachemiss https://localhost:8000/bar]
^c
1827 cache misses (38%)
340 cache hits (44%)
Hit Thread Stats   Avg      Stdev     Max 
  Latency   635.91us    0.89ms  12.92ms  
  Requests/sec   56.0k	 8.07k	 64k
Miss Thread Stats   Avg      Stdev     Max 
  Latency   1235.91us    0.89ms  12.92ms  
  Requests/sec   18.0k	 4.07k	 28k




./dpc_backend.go --port 87527 --threshold 8

dpc_hosts
localhost:87527
87528
127.0.0.1:87529

MVP

Logging and statistics are extraneous. Dont have to configure thresholds, use static values first time around

what we want to measure: the latency and thoroughput of the frontend, and the memory usage of the backend. The most basic thing we want to measure is how fast does it go when making requests via the proxy, vs when the proxy is missing. Test this by writing a lua script for wrk to randomly select from a large set of urls. Also test by using the debug-remote-port in a browser.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.