You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While debugging connections in profiler I noticed that node spends a huge amount of time loading googleapis package.
That package (as of 73.0.0) contains ~218 service that take about 84Mb. And I believe they are all being parsed and loaded on startup.
Also package docs suggest to load packages individually:
If you need to reduce startup times, you can alternatively install a submodule as its own dependency. We make an effort to publish submodules that are not in this list.
(measured with npx clinic flame -- node src/main.js server)
The text was updated successfully, but these errors were encountered:
lotas
added
the
performance
Issues affecting the performance of Taskcluster or a particular micro-service
label
Jan 5, 2024
There are two major node.js libraries - googleapis and @google-cloud
In code, auth services uses one call and so is relatively easy to migrate, while worker-manager uses compute, iam and oauth which do not have 1:1 features in the later library, so I'll use @googleapis/compute instead
While debugging connections in profiler I noticed that node spends a huge amount of time loading
googleapis
package.That package (as of 73.0.0) contains ~218 service that take about 84Mb. And I believe they are all being parsed and loaded on startup.
Also package docs suggest to load packages individually:
(measured with
npx clinic flame -- node src/main.js server
)The text was updated successfully, but these errors were encountered: