logoalt Hacker News

b_llc • last Wednesday at 4:48 PM • 2 replies • view on HN

A stateless pattern I use to batch telemetry at the edge while driving Cloudflare write costs to zero.


Replies

fwlr • today at 3:50 AM

Cool pattern. Critics will say “falsehoods programmers believe about time” but it’s a cloud service, any time oddity that would break this would also break a lot more important stuff, so it’s fine.

Ugly code though.

  // env
  QUEUES = [EVEN_QUEUE, ODD_QUEUE]

  // producers
  env.QUEUES[hour % 2].send …

  // consumer
  env.QUEUES[1 + hour % 2]
➕ show 1 reply
raffraffraff • today at 6:48 AM

Can you explain the pricing here?

➕ show 1 reply