News for hackers. Stuff that matters.
Re:Diving into Technical SEO Using Cloudflare Workers by eberkund on Thursday March 07, 2019 @01:15PM (#19330520)
Has anyone here used Cloudflare workers yet? I know they just launched recently. - Where you using new or existing code (coming from Lambda for example)? - How did the performance compare? - Did you run into any difficulties?
Re:Diving into Technical SEO Using Cloudflare Workers by kmf on Thursday March 07, 2019 @02:24PM (#19331252)
Yes, it's a super rad product. Using it for a few things, so far:

1) Working on a project right now that provides edge-level analytics for your sites w/ a focus on privacy: more accurate than Google Analytics (JS blockers remove ~1/3 of your traffic stats) and less icky for your users. Funny this comes up, I'm putting together a list for people who are interested in beta testing, if that sounds appealing: https://xyz.us16.list-manage.com/subscribe?u=0b8a0e873d096aa...

2) Extreme caching on a Wordpress site – using Cloudflare's edge cache WP plugin[1] and the worker from the workers-example repo[2] – currently at a 97% cache hit rate across the site.

update: just double-checked the cache hit stat on Cloudflare, after writing this comment - actually have a 99.95% cache rate as of today (!)

[1] https://wordpress.org/plugins/cloudflare-page-cache/

[2] https://github.com/cloudflare/worker-examples/tree/master/ex...

Re:Diving into Technical SEO Using Cloudflare Workers by reinder on Thursday March 07, 2019 @02:42PM (#19331472)
> JS blockers remove ~1/3 of your traffic stats

I'd love to hear more about this – could you elaborate? Any resources you can share to back it up? Thx!

Re:Diving into Technical SEO Using Cloudflare Workers by tatersolid on Thursday March 07, 2019 @06:16PM (#19333633)
Basically anyone who uses Firefox, or anyone who has uBlock, AdBlock, uMatrix, Purify, etc. the installed is invisible to JS-based analytics. They simply never load the GOogle Analytics, NewRelic, or whatever code as part of their “tracking protection”.

In financial services, we see about 15% higher unique users per day when analyzing HTTP logs versus Google Analytics. In fact, I’ve heard but not verified that GA now applies a “correction factor” to their stats to account for this.

Re:Diving into Technical SEO Using Cloudflare Workers by johnxie on Thursday March 07, 2019 @04:14PM (#19332521)
Thanks, just signed up for the beta test mailing list. I'm interested to give it a try on Taskade. https://taskade.com
Re:Diving into Technical SEO Using Cloudflare Workers by judge2020 on Thursday March 07, 2019 @06:54PM (#19333868)
> edge-level analytics

Another approach to this using Workers:

https://logflare.app/

Re:Diving into Technical SEO Using Cloudflare Workers by manigandham on Thursday March 07, 2019 @01:37PM (#19330747)
Yes, we've run billions of requests through them. They have the best performance and the lowest-latency, along with running globally instead of a single datacenter. It's just javascript so you can use npm packages and compile the final script to deploy.
Re:Diving into Technical SEO Using Cloudflare Workers by rat9988 on Thursday March 07, 2019 @02:24PM (#19331254)
Does it guarantee some sort of high availability? Like if two of your datacenters are struck by a meteor would a third one serve my audience? (same question for you workers KV)
Re:Diving into Technical SEO Using Cloudflare Workers by manigandham on Thursday March 07, 2019 @02:37PM (#19331408)
Cloudflare is a CDN so they're designed for high-availability with over 100+ datacenters.

CDNs are designed to forward requests to a origin server and cache the results, but you can serve your site completely from Workers if you embed all the code and data into the deployed script or store content in KV.

Re:Diving into Technical SEO Using Cloudflare Workers by physcab on Thursday March 07, 2019 @04:41PM (#19332773)
Does have to fit in their 1MB limit though (i think)
Re:Diving into Technical SEO Using Cloudflare Workers by rmoaiandin on Friday March 08, 2019 @05:02AM (#19336356)
It's the CPU time that you should really worry about mainly. But the limits are here: https://developers.cloudflare.com/workers/writing-workers/re...
Re:Diving into Technical SEO Using Cloudflare Workers by mtrimpe on Thursday March 07, 2019 @03:25PM (#19331975)
Unless you go for Enterprise you can only have a single worker per site making QA and staging hell.

Their JavaScript environment/APIs are not standard and there’s no proper spec that I could find.

The debugging environment/IDE is decent for an in-browser one but we had some horrible issues with a stale version being loaded from local storage and accidentally applied to the entire site effectively bringing us down for several minutes.

On every change I also saw several error pages myself during warmup period which made me wonder how many customers were getting them.

This was all ~6 months ago though so things might have improved since then.

Performance wise we’re very happy with it though as it beats the Apache reverse proxy it replaces hands down.

Re:Diving into Technical SEO Using Cloudflare Workers by manigandham on Thursday March 07, 2019 @08:22PM (#19334326)
They're using the Service Worker API: https://developer.mozilla.org/en-US/docs/Web/API/Service_Wor...

It's not running in a browser so they reimplemented some things but the overall API surface is the same. They also have some extra APIs for CF only features.

Debugging is a problem though, but there's another project called Cloudworker that emulates a local instance: https://blog.cloudflare.com/cloudworker-a-local-cloudflare-w...

Re:Diving into Technical SEO Using Cloudflare Workers by mrkurt on Friday March 08, 2019 @11:36AM (#19339129)
(shameless, but possibly helpful plug)

You can run CF worker code locally, write tests, etc using our edge app runtime: https://github.com/superfly/fly

Re:Diving into Technical SEO Using Cloudflare Workers by alexbecker on Thursday March 07, 2019 @02:10PM (#19331110)
We use them to restrict access to some static assets (beta documentation) by checking an authorization endpoint. Haven't had any problems--but we're also doing this at a very small scale.
Re:Diving into Technical SEO Using Cloudflare Workers by panarky on Thursday March 07, 2019 @01:48PM (#19330874)
I signed up for a subdomain with the https://workers.dev launch, but since then I've heard nothing from Cloudflare about when they'll actually turn it on.
Re:Diving into Technical SEO Using Cloudflare Workers by zackbloom on Thursday March 07, 2019 @01:50PM (#19330896)
If your goal is to augment an existing domain on Cloudflare (as in the post), you can actually use Workers today. Login to your Cloudflare dashboard and click the "Workers" tab.
Re:Diving into Technical SEO Using Cloudflare Workers by Elof on Thursday March 07, 2019 @06:32PM (#19333739)