Re:Serverless Performance: Cloudflare Workers, Lambda and La...
by kentonv on Tuesday July 03, 2018 @11:35AM
(#17451020)
At Cloudflare we're all in awe at how fast https://discordapp.com loads... nice work.
Re:Serverless Performance: Cloudflare Workers, Lambda and La...
by jhgg on Tuesday July 03, 2018 @02:12PM
(#17452451)
Thanks! And thanks for building Cloudflare workers. You have no idea how much nicer it is to write and express a lot of this logic in modern javascript, rather than nginx configs and VCLs.
Re:Serverless Performance: Cloudflare Workers, Lambda and La...
by adreamingsoul on Tuesday July 03, 2018 @01:35PM
(#17452127)
I haven't dug too deep into this, but when loading view-source:https://jake.lol/clock I'm seeing on average 14 second load times. Does this happen for anyone else?
Re:Serverless Performance: Cloudflare Workers, Lambda and La...
by JohnDotAwesome on Thursday July 05, 2018 @10:00AM
(#17463287)
That seems right. Should probably be longer. Each second, a new chunk is emitted with the appropriate html to hide the old clock element and show the new.
This is really useful to test new features before they land in master and are deployed out - we actually have tooling that lets you specify a branch you want to try out, and you can quickly have your client pull built assets from that branch - and even share a link that someone can click on to test out their client on a certain build. Just the other week, we shipped some non-obvious bug, and I was able to bisect the troubled commit using our build override stuff.
The worker stuff is completely integrated into our CI pipeline, and on a usual day, we're pushing a bunch of worker updates to our different release channels. The backing-store for all assets and pre-rendered content sits in a multi-regional GCS bucket that the worker signs + proxies + caches requests to.
We build the worker's JS using webpack, and our CI toolchain snapshots each worker deploy, and allows us to roll back the worker to any point in time with ease.
I wrote probably the stupidest worker script too, that streams a clock to your browser using chunked requests: https://jake.lol/clock (no javascript required).