https://discord.cloudflare.com logo
Join Discord
Powered by
# workers-discussions
  • k

    kian

    04/21/2023, 7:51 PM
    Do you mean a single Worker or a single instance of a single Worker?
  • m

    meyer

    04/21/2023, 7:52 PM
    one worker writes to the queue, multiple different workers would consume
  • k

    kian

    04/21/2023, 7:52 PM
    Ah, yeah, gotcha
  • k

    kian

    04/21/2023, 7:52 PM
    Yeah - one consumer per queue but that consumer will automatically scale to handle the amount of messages
  • m

    meyer

    04/21/2023, 7:53 PM
    yeah i love queues, such a nice dead simple API
  • m

    Mozzy

    04/21/2023, 8:19 PM
  • d

    dave

    04/21/2023, 10:02 PM
    @subhendupsingh you around? Wondering how I can add a new OAuth provider to https://github.com/subhendukundu/worker-auth-providers
  • d

    dave

    04/21/2023, 11:17 PM
    Failing at implementing my own OAuth project.
  • d

    dave

    04/22/2023, 12:17 AM
    never mind, it wasn't me failing
  • m

    Murder Chicken

    04/22/2023, 2:25 AM
    Is there a way to add a listener to fetch requests that are being issued from within a scheduled worker? I'm only making ~20 requests but I'm getting an error that when the worker executes, I'm hitting the 50 sub-request limit. I can't see any reason for this and it's difficult to debug without seeing exactly what's going out the door.
  • e

    embed

    04/22/2023, 5:43 AM
    hey all, would workers be suitable for a route that creates 3 variants of an image and saves them to an s3 / r2 bucket? not sure if sharp would work with cloudflare due to c bindings
  • s

    subhendupsingh

    04/22/2023, 6:22 AM
    I am not the Subhendu you want 😉 and thanks now I know about this awesome library
  • j

    Joyte

    04/22/2023, 3:10 PM
    can anyone tell me what this url is from? https://worker-openapi-example.radar.cloudflare.com/docs#/
  • e

    Erisa | Support Engineer

    04/22/2023, 3:17 PM
    https://github.com/cloudflare/itty-router-openapi
  • j

    Joyte

    04/22/2023, 3:17 PM
    i see, ty
  • n

    nora

    04/22/2023, 4:54 PM
    If I run an asynchronous function before returning a response, but I don't wait for it, will the execution continue after the response?
  • h

    HardAtWork

    04/22/2023, 5:05 PM
    It will not. To ensure it continues running, pass it into ctx.waitUntil
  • n

    nora

    04/22/2023, 7:59 PM
    Thanks.
  • a

    ajgeiss0702

    04/22/2023, 11:55 PM
    quick question Setting an expiry on a KV entry, then later setting that key again without the expiry will cancel the expiry, right?
  • u

    Unsmart | Tech debt

    04/22/2023, 11:57 PM
    Yes it will
  • a

    ajgeiss0702

    04/22/2023, 11:59 PM
    cool, thank you
  • s

    sathoro

    04/23/2023, 12:12 PM
    is there a safe/recommended way to have a global variable that can be accessed throughout the worker without passing down a variable? specifically an instance of Sentry
  • s

    sathoro

    04/23/2023, 12:13 PM
    is this okay to do, accessing it from the request variable?
    Copy code
    async fetch(request, env, context) {
      const sentry = await initSentry({ request, env, context });
      request.sentry = sentry;
    
      ...
    }
    ideally could access it without the request variable too
  • s

    sathoro

    04/23/2023, 12:13 PM
    right now we are passing around the sentry object and it is messy
  • h

    HardAtWork

    04/23/2023, 12:14 PM
    https://developers.cloudflare.com/workers/runtime-apis/nodejs/asynclocalstorage/#asynclocalstorage
  • s

    sathoro

    04/23/2023, 12:15 PM
    interesting
  • s

    sathoro

    04/23/2023, 12:15 PM
    what syntax is this
  • s

    sathoro

    04/23/2023, 12:16 PM
    oh a private field
  • s

    sathoro

    04/23/2023, 12:17 PM
    I'm a bit of a modern js noob. I started with js back when IE6 was still around then mostly wrote Python and well things have progressed since then
  • s

    sathoro

    04/23/2023, 12:27 PM
    ERROR: Could not resolve "node:async_hooks"
1...240924102411...2509Latest