back to article Cloudflare ties Workers to distributed data storage

Content delivery biz Cloudflare on Friday added distributed key-value storage to its Workers service, making a greater range of network-hosted applications possible. Cloudflare Workers are similar to browser-based Service Workers, except that they run JavaScript code on the company's network rather than in the browser, thereby …

It's not the sort of thing you'd want handling millions of rapid-fire financial transactions

What would a good actual use case for this be? Not in general terms; I'm asking for a specific application where this works better than a database or a set of databases that are stored across regions and coordinate. What benefit does this bring, other than being something that absolutely won't run on anything else without changing a lot of code, thus providing a sustainable source of income for whatever service provider the user starts with.

2
0
Reply
Silver badge

Re: It's not the sort of thing you'd want handling millions of rapid-fire financial transactions

I suppose you could take that question and ask folks that run things like redis, or memcache, or similar types of key value store systems.

The most popular use case that I see anyway is for caching and holding session data. Given the distributed nature of this feature it seems like it could do a lot for performance of caching more complex things closer to the client in a simpler fashion.

I'm not a developer and have no use for this myself, and am not, and never have been a cloudflare customer. I have worked with many apps that use memcache and redis over the years though (usually in addition to a database of some kind).

One developer I knew(but didn't like, and he didn't like me either) years ago thought he was smart and thought he needed just a couple of weeks to code a database caching layer in memcache to replace the mysql query cache. When I heard that I just laughed. He wasn't at the company much longer so never got to see what he might of come up with. (yes I know the mysql query cache is frowned upon, at the time it was required for our core application)

Heimdall is a MySQL database load balancer, analytics tool, and cache accelerator, something I have been using off and on for the past year or two. As an example they generally suggest using redis for (their) cache, though they can use Hazlecast and maybe one other tech too. Just mentioned them as an example of caching with MySQL anyway.

But it seems strange to me for someone to compare a key value store to a traditional database.

4
0
Reply
K
Silver badge

Re: It's not the sort of thing you'd want handling millions of rapid-fire financial transactions

Nice one for mentioning Heimdall.. I'll add that into my "if needed..." list for the future!

It's been 2-3 years since I've had serious interaction with MySQL or MariaDB.. back then I'd been an IT Manager for an SME for about 10 years, I frequently spent weeks researching and testing, trying to find a low-cost and low-maintenance solution for implementing MySQL/MariaDB load balancing (of course, low-cost and low-overhead rarely go together).

0
0
Reply
Silver badge

Re: It's not the sort of thing you'd want handling millions of rapid-fire financial transactions

It would be a caching layer for web application architectures having no persistent memory. Every web page or REST call has to open a database connection, authenticate, make 10+ queries to figure out what's going on, send back the result, then close the database connection. SQL queries might take 2 to 50 ms each but opening a new connection is typically in the 75 to 6000 ms range, depending on DB configuration and load. A KV store is used to hold all of the semi-constant data so that fewer requests need to execute SQL.

If you have insurmountable legacy baggage, a K-V store can also act as a cache for SQL queries that can not be made efficient or external API calls that are slow.

0
0
Reply

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon

Biting the hand that feeds IT © 1998–2018