Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

size of module growing, making use with AWS lambda functions difficult #488

Open
amdevelopment-world opened this issue Mar 7, 2024 · 2 comments

Comments

@amdevelopment-world
Copy link

hi, when i updated my lambda function to the very latest version of google-ads-api i could no longer update my lambda function that doesn't use any other dependency because the max size for a lambda function was exceeded

so, i had no choice but to use version v14.2.0

it's not just google-ads-api, but also google-ads-node

currently my node_modules take 327mb, using version 14.2.0, if i use the latest version i go over 400mb,

80 megabytes more for a library that calls web services

it would be nice to be able to include just the required functions, or at least group them, campaigns, reporting etc
or, minimise the code in some way ?

i'm also posting this in the git for google-ads-node, as it's the bigger of the two modules

@avermeil
Copy link
Member

Yeah, it's absolutely massive and overkill for what it is. The issue stems from the fact that google-ads-node is built using Google's Bazel, which (using protobufjs) generates tons of JS to mirror the contents of the .proto files. I've explored slimming this all down in the past, but gotten discouraged by the complexity of this build step.

As an alternative, if you're only using a small subset of the Google Ads API, you could use their REST endpoints... they're very easy to use and just as performant. No type safety though!

@amdevelopment-world
Copy link
Author

thanks, (i don't care about type safety), who does ? this node module is now unusable in a AWS lambda function, i'm sure there is a better way to do this, but don't ask me how :) thanks for your reply.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants