title: Google PubSub throw "Not found" when getting a newly created topic
body: <p>I've got a function that create topics and subscriptions when my server boots.</p>
  
  <p>The problem is that I can't create subscription linked to a newly created topic, the Google PubSub server throws a NOT FOUND error.</p>
  
  <p>I've even added a 20 second timeout after the topic creation but nothing changed T_T</p>
  
  <pre><code>export async function init() {
    // promises.topics is an array of promises
    const topics = await Promise.all(promises.topics);
    console.log('YEAH !!! TOPIC IS GOOD !', topics);
    // That works ! And it is created in my remote google PubSub
    await timeout(20000);
  
    console.log('Lets Check if it exists !!!');
  
    // promises.getTopics is an array of :
    // getTopics.push(pubSubClient.topic(topic.name).get());
    // That throws a NOT FOUND
    const get = await Promise.all(promises.getTopics);
    // Failes because Topics are not found
    const subscriptions = await Promise.all(promises.subscriptions);
  }
  </code></pre>
  
  <p>When I check in the Google logs, the created topic is created AFTER the subscriptions oO</p>
  
  <p>My Promise array inject first topics Then the subscriptions promises.</p>
  
  <p>When adding a retry function that try again 10 times every 2 second, it don't work either.</p>
  
  <p>It's no even showing in google logs, I think they have a cache ton their API that just return newly processed data without re-trying it.</p>
  
  <p>Do you have an idea ?</p>
  
  <p>Thanks :)</p>
  
  <p>TOPICS :
  <a href="https://i.stack.imgur.com/7inhx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/7inhx.png" alt="enter image description here"></a></p>
  
  <p>SUBSCRIPTION ERROR :</p>
  
  <p><a href="https://i.stack.imgur.com/L6rKh.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/L6rKh.png" alt="enter image description here"></a></p>
  
  <p><strong>EDIT :</strong> </p>
  
  <p>I Managed to fix the problem by adding a timeout('2000') after pushing the topic promise creation in my promise array.</p>