Skip to content

google-gax hangs in non-Cloud environments #221

@joehan

Description

@joehan

Environment details

  • OS: Any
  • Node.js version: Any
  • npm version: Any
  • gax-nodejs version: 4.3.0

Steps to reproduce

@dereekb provided the following repo on firebase-tools. However, I believe this will broadly affect emulated Firestore-triggered cloud functions

You can run the project at https://github.com/dereekb/dbx-components on version v10.0.17 (version v10.0.18 will have the workaround added to the Dockerfile). Run both the server ./serve-server.sh and web client ./serve-web.sh and go to http://localhost:9010/demo/app/profile/view. Change the profile info to kick off a firebase functions request.

Related issue: firebase/firebase-tools#6765

It looks like googleapis/gax-nodejs#1552 may have added a call to the compute metadata server to get universe_domain, which will hang outside of Cloud environments. Would it be possible skip this call when not running on Cloud, or add a reasonable timeout to this call & handle the error?

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions