title: What limits the number of outbound requests an express server inside a Cloud Run container instance can make?
body: <p>I have an <code>express</code> server running inside a Cloud Run container.</p>
  <p>I know a single Cloud Run instance may handle <a href="https://cloud.google.com/run/docs/about-concurrency#concurrency_values" rel="nofollow noreferrer">up to 250 requests concurrently</a>.</p>
  <p><a href="https://i.stack.imgur.com/oaV3q.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/oaV3q.png" alt="enter image description here" /></a></p>
  <p>I also know that an <code>express</code> server may handle many requests at a time.</p>
  <p>But how about outbound external requests that request handlers functions of that server make? What limits that?</p>
  <p>Imagine I have an API route, that needs to make a lot of external API calls. For example:</p>
  <pre><code>/api/update-all-db-with-external-info
  </code></pre>
  <p>And the handler for that route is something like this:</p>
  <p><strong>updateAll.ts</strong></p>
  <pre><code>import fetch from &quot;cross-fetch&quot;;
  
  async function updateAll() {
    const all1000promises = [];
    for (const obj of WHOLE_DB_1000_ITEMS) {
      all1000promises .push(fetch(&quot;SOME_EXTERNAL_API&quot;));    
    }
    Promise.all(all1000promises).then((values) =&gt; {
      console.log(values);
    });
    // UPDATE DB...
    // DO OTHER STUFF...
  }
  </code></pre>
  <p>What will limit this kind of code? Is it the memory allocated for the instance? Or is there something like an outbound request concurrency limit for either the <code>express</code> server or the cloud run instance?</p>