Code Monkey home page Code Monkey logo

firewalk's People

Contributors

kafkas avatar luke-rogers avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

firewalk's Issues

Async Iterable interface

I think that something exposing an async iterator would be cleaner to use.

  let count = 0;
  let queue = [];
  for await (const snapshot of createTraverser(...)) {
    count++;
    queue.push(sendEmail(snapshot.data());
    if (queue.length >= 50) {
      await promise.all(queue);
      queue = [];
    }
  }
  await promise.all(queue);
  console.log(`Processed ${count} users.`);

The items can simply implement the async iterator methods, and fetch in batches internally.

What is the best balance between batchSize and maxConcurrentBatchCount ?

Let's say that we have a number K of docs to traverse. We should have at most N docs held in memory at the same time. To get the best performance, should we :

  • Choose the maximum batchSize possible (=500), and set the maxConcurrentBatchCount to N / batchSize
  • Choose the maximum maxConcurrentBatchCount logically possible (which I don't know), and set the batchSize to N / maxConcurrentBatchCount
  • Have preferred values for either the batchSize or the maxConcurrentBatchCount depending on N. In this case, what would these values be ?

Thanks for helping!

Parallelize tests

Use distinct collections for each migrator method and run those migrations concurrently.

Use "orderBy" to traverse a collection's documents

Hello,
Is it possible to use "orderBy" to traverse a collection in a certain order ?

Suppose I have a collection "Data" with these kinds of docs :

{
  id : ....,
  name : ....,
}

I would like to traverse this collection in a way that the docs are ordered by id (or by name) between the different batches. What I mean by that is that the docs of batch1 should all have a "lower" id/name than the docs in batch 2, and so forth. The docs don't have to be ordered inside the same batch.

Is that possible? In what order is the collection traversed by default?

Thanks.

Support firebase-admin 11.x

Currently, this library only supports firebase-admin 9.x and 10.x. We should add support for 11.x.

There have been some typing changes in 11.x so this is a bit more involved than just updating the dependencies to 11.x as there are some compilation issues, mainly around the introduction of making firestore.UpdateData generic.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.