https://discord.cloudflare.com logo
Join Discord
Powered by
# durable-objects
  • g

    Greylock

    06/24/2021, 2:30 PM
    That’s a reasonable limit
  • g

    Greylock

    06/24/2021, 2:31 PM
    So that’s good there’s no limit
  • b

    brett

    06/24/2021, 2:32 PM
    You can also use Workers KV inside of one, which is probably better for big blobs of non-transactional data
  • g

    Greylock

    06/24/2021, 2:34 PM
    Yeah
  • g

    Greylock

    06/24/2021, 2:35 PM
    The blog post mentioned the idea of building a database using durable objects and I was just theorizing how that would be done
  • g

    Greylock

    06/24/2021, 2:35 PM
    Since your indexes would need to be accessible from any worker serving a request
  • g

    Greylock

    06/24/2021, 2:35 PM
    But changes to said index should also probably be transactional
  • g

    Greylock

    06/24/2021, 2:36 PM
    You could maybe use the KV store
  • g

    Greylock

    06/24/2021, 2:37 PM
    This question along with others is probably why cloudflare teamed up with macrometa instead of building their own database products
  • b

    brett

    06/24/2021, 2:41 PM
    We'd (or at least I'd? I'm not speaking for the company here) love to offer a richer persistent storage API, we just have more work we do want/need to do on other DO sharp edges first.
  • s

    steranevdy

    06/24/2021, 2:48 PM
    what's the reason that TCP connection is not available in workers?
  • s

    steranevdy

    06/24/2021, 2:49 PM
    many database use TCP
  • g

    Greylock

    06/24/2021, 2:53 PM
    Probably because it requires a lot of development to do correctly
  • g

    Greylock

    06/24/2021, 2:54 PM
    And workers were built around HTTP first and foremost
  • g

    Greylock

    06/24/2021, 2:54 PM
    You can use websockets which are basically just TCP sockets
  • c

    Censor Bot

    06/24/2021, 8:40 PM
    message has been deleted
  • g

    Greylock

    06/24/2021, 8:59 PM
    on that note, any ideas on when durable objects will become generally available?
  • g

    Greylock

    06/24/2021, 9:00 PM
    they have been out for almost a year now and im really eager to get a PR going for sveltekit to use the modular syntax, but sveltekit and other frameworks are more or less refusing to integrate the modular syntax until DO/workers come out of beta because there are some bugs as it stands now
  • g

    Greylock

    06/24/2021, 9:00 PM
    like for example, ``kv-asset-handler`` not supporting ES6 modules
  • c

    Cloudflare Workers Bot

    06/25/2021, 12:09 AM
    message has been deleted
  • j

    jed

    06/25/2021, 12:10 AM
    oh no, discord slash commands are public? 🙇
  • g

    Greylock

    06/25/2021, 12:46 AM
    They have been for like 3 months but only recently became popular
  • g

    Greylock

    06/25/2021, 1:35 AM
    Copy code
    js
        // client.
        let storage = await this.storage.list({reverse: true, limit: 100});
        let backlog = [...storage.values()];
        backlog.reverse();
        backlog.forEach(value => {
          session.blockedMessages.push(value);
        });
  • g

    Greylock

    06/25/2021, 1:35 AM
    looking at the chat demo
  • g

    Greylock

    06/25/2021, 1:35 AM
    theres ``storage.list()`` but no documentation on the possible arguments allowed, or the limitations of it.
  • m

    Mallissin

    06/25/2021, 3:55 AM
    https://developers.cloudflare.com/workers/runtime-apis/durable-objects#methods
  • m

    Mallissin

    06/25/2021, 3:55 AM
    Same as DO list I think
  • g

    Greg-McKeon

    06/25/2021, 4:28 AM
    I can follow up on this bug - are there other bugs that you're seeing specific to DOs? Workers are generally available themselves.
  • g

    Greg-McKeon

    06/25/2021, 4:29 AM
    No specific timeline yet, but we're working on several features we need to get them out the door (UI, billing, bug fixes)
  • g

    Greylock

    06/25/2021, 4:29 AM
    Well I submitted a PR that would resolve it but I’m waiting on the asset manifest being passed into module workers
1...107108109...567Latest