| CARVIEW |
Select Language
HTTP/2 302
server: nginx
date: Tue, 23 Dec 2025 17:30:11 GMT
content-type: text/plain; charset=utf-8
content-length: 0
x-archive-redirect-reason: found capture at 20100414005033
location: https://web.archive.org/web/20100414005033/https://github.com/rnewson/jlounge
server-timing: captures_list;dur=0.977412, exclusion.robots;dur=0.081922, exclusion.robots.policy;dur=0.067737, esindex;dur=0.015412, cdx.remote;dur=67.251058, LoadShardBlock;dur=178.224560, PetaboxLoader3.datanode;dur=63.945621, PetaboxLoader3.resolve;dur=31.732469
x-app-server: wwwb-app212-dc8
x-ts: 302
x-tr: 295
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
set-cookie: wb-p-SERVER=wwwb-app212; path=/
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
HTTP/2 200
server: nginx
date: Tue, 23 Dec 2025 17:30:11 GMT
content-type: text/html; charset=utf-8
x-archive-orig-server: nginx/0.7.61
x-archive-orig-date: Wed, 14 Apr 2010 00:50:32 GMT
x-archive-orig-connection: close
x-archive-orig-status: 200 OK
x-archive-orig-etag: "a1d6e8a3c13de507e306036449a40026"
x-archive-orig-x-runtime: 278ms
x-archive-orig-content-length: 19773
x-archive-orig-cache-control: private, max-age=0, must-revalidate
x-archive-guessed-content-type: text/html
x-archive-guessed-charset: utf-8
memento-datetime: Wed, 14 Apr 2010 00:50:33 GMT
link: ; rel="original", ; rel="timemap"; type="application/link-format", ; rel="timegate"
content-security-policy: default-src 'self' 'unsafe-eval' 'unsafe-inline' data: blob: archive.org web.archive.org web-static.archive.org wayback-api.archive.org athena.archive.org analytics.archive.org pragma.archivelab.org wwwb-events.archive.org
x-archive-src: 51_15_20100413225743_crawl100-c/51_15_20100414004950_crawl101.arc.gz
server-timing: captures_list;dur=0.717350, exclusion.robots;dur=0.026704, exclusion.robots.policy;dur=0.011661, esindex;dur=0.014898, cdx.remote;dur=11.665432, LoadShardBlock;dur=134.382272, PetaboxLoader3.datanode;dur=123.151645, PetaboxLoader3.resolve;dur=85.406080, load_resource;dur=129.534293
x-app-server: wwwb-app212-dc8
x-ts: 200
x-tr: 331
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
x-location: All
x-as: 14061
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
content-encoding: gzip
rnewson's jlounge at master - GitHub
rnewson / jlounge
- Source
- Commits
- Network (0)
- Issues (0)
- Downloads (0)
- Wiki (1)
- Graphs
-
Branch:
master
click here to add a description
click here to add a homepage
jlounge /
README
WARNING Very, very alpha. Getting started; 1) mvn jetty:run NOTES shard management The number of shards is preconfigured and unalterable (default is 1024). all items are mapped to a shard by f(id % shard_count). all shards are mapped to nodes via a consistent hash ring. The first N non-duplicate nodes from where the shard maps to are used to store the node. However, writes are always permitted as long as at least one server is available. During failures or partitions, this might mean that an item is written to a server that does not ordinarily host the shard the item belongs to. In this case, a new replica of the shard is made there unilaterally and the item is stored. The node is responsible for sending this item back to one of the intended shard nodes as soon as it can. read-write policies. A read-write policy is the combination of two access policies; Head policy - access is directed to the head of the replica list. Tail policy - access is directed to the tail of the replica list. Random policy - access is directed to a random replica. Round Robin policy - access id directed to replicas in a cyclical order. Useful combinations read-tail,write-head - all reads represent fully replicated data. read-head,write-head - low latency reads (data not yet replicated). read-rr,write-head - high performance read, low chance of collision. read-rr,write-rr - high performance read+write, high chance of collision. Behavior by operation function: get document url form: GET https://localhost:8080/jlounge/<dbname>/<id> behavior; 1) calculate shard = hash(id) % shard_count. 2) take next N non-duplicate hosts from shard map. 3) GET https://<1st node>:5984/<dbname>-<shard>/<id> 4) If status line == 200, proxy full response to client. 5) if status line != 200 or no response, try the next host. Any other error is returned to the client (a failure while writing to a server because it died, etc). The client must retry. function: create document url form: PUT https://localhost:8080/jlounge/<dbname>/<id> (with request body) behavior; 1-2) as before 3) PUT https://<1st node>:5984/<dbname>-<shard->/<id> 4) if status==201, we're good. 5) if status==409, return error to caller. 6) if status==404 or no response, try the next host. NB: Must force db creation at some point.

